Re: [PATCH v1 1/4] leds: trigger: gpio: Replace custom code for gpiod_get_optional()

From: Linus Walleij
Date: Sat Nov 04 2023 - 18:26:24 EST


On Fri, Nov 3, 2023 at 8:53 PM Andy Shevchenko
<andriy.shevchenko@xxxxxxxxxxxxxxx> wrote:

> gpiod_get_optional() and currently used fwnode_gpiod_get_index()
> are both wrappers against the same engine internally. Since we
> have a pointer to struct device there is no reason to use fwnode
> type of GPIO call. So, replace the current fwnode call by respective
> gpiod ones.
>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>

I don't know what I was thinking here. Probably I was thinking that
the nodes doesn't always have a device, but hey, it does...
Reviewed-by: Linus Walleij <linus.walleij@xxxxxxxxxx>

Yours,
Linus Walleij