Re: [PATCH v2 3/9] gpio: sysfs: pass gpiod_data directly to internal GPIO sysfs functions

From: Andy Shevchenko
Date: Fri Jun 27 2025 - 11:38:08 EST


On Mon, Jun 23, 2025 at 10:59:51AM +0200, Bartosz Golaszewski wrote:
>
> To make the transition to not using dev_get_drvdata() across line
> callbacks for sysfs attributes, pass gpiod_data directly to
> gpio_sysfs_request_irq(), gpio_sysfs_free_irq() and
> gpio_sysfs_set_active_low() instead of having it wrapped in struct
> device.

I would improve the commit message by mentioning why using data over dev is
better. Something like "since we do not use anything from dev, pass the data
object pointer ...".


--
With Best Regards,
Andy Shevchenko