Re: [PATCH v1 2/4] gpio: shared: Replace open coded fwnode_is_gpiochip()
From: Andy Shevchenko
Date: Mon Aug 24 2026 - 04:43:56 EST
On Mon, Aug 24, 2026 at 09:42:33AM +0200, Andy Shevchenko wrote:
> Since GPIOLIB provides a helper, no need to open code it, hence
> replace that piece by fwnode_is_gpiochip().
...
> - np = args.np;
Ah, this one is important.
It seems that
struct device_node *np __free(device_node) = NULL;
needs to be replaced with
struct fwnode_handle *node __free(fwnode_handle) = NULL;
or something alike between the lines.
> - if (!of_property_present(np, "gpio-controller"))
> + fwnode = of_fwnode_handle(args.np);
> + if (!fwnode_is_gpiochip(fwnode))
> continue;
--
With Best Regards,
Andy Shevchenko