[PATCH 6/9] regulator: tps65217-regulator: Use the returned value of tps65217_reg_read()

Mark Brown broonie at kernel.org
Fri Jun 26 09:33:04 EDT 2020


On Fri, Jun 26, 2020 at 07:57:35AM +0100, Lee Jones wrote:

> Until now the aforementioned return value has been ignored.

This is only aforementioned in the subject.

>  		/* Store default strobe info */
>  		ret = tps65217_reg_read(tps, regulators[i].bypass_reg, &val);
> +		if (ret)
> +			return ret;
> +

We should really be logging an error there rather than just returning,
that way it's a bit more apparent to someone debugging things what went
wrong if there is actually a problem.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20200626/99ee9264/attachment.sig>


More information about the linux-arm-kernel mailing list