Re: [PATCH v2 2/2] iio: devm_regulator_get_optional never returns NULL

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Sep 5, 2016 at 11:14 AM, Crt Mori <cmo@xxxxxxxxxxx> wrote:

> This patch is inspired by a comment of Jonathan Cameron on patch of
> Linus Walleij commit aeb55fff3891834e07a3144159a7298a19696af8 ("iio:
> st_sensors: fetch and enable regulators unconditionally"). Because
> changes made in this patch are actually reference generators they should
> be using devm_regulator_get_optional, but if they do not explicitly set
> the reference to NULL they should not be using IS_ERR_OR_NULL, but
> simple IS_ERR check.
>
> Suggested-by: Lars-Peter Clausen <lars@xxxxxxxxxx>
> Signed-off-by: Crt Mori <cmo@xxxxxxxxxxx>

Reviewed-by: Linus Walleij <linus.walleij@xxxxxxxxxx>

Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-iio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux