[PATCH v2 0/8] gpiolib: Some cleanups

From: Andy Shevchenko
Date: Wed Apr 16 2025 - 05:57:50 EST


Just a three groups of cleanups (some of them may be dependent to the previous
ones compile and logically wise, but I am only aware about couple of patches,
i.e. 3 & 4).

In v2:
- split one patch to two (Linus)
- added tags (Linus)

Andy Shevchenko (8):
gpiolib: Make taking gpio_lookup_lock consistent
gpiolib: Convert to use guard()() for gpio_machine_hogs_mutex
gpiolib: Print actual error when descriptor contains an error pointer
gpiolib: Revert "Don't WARN on gpiod_put() for optional GPIO"
gpiolib: Move validate_desc() and Co upper in the code
gpiolib: Call validate_desc() when VALIDATE_DESC() can't be used
gpiolib: Reuse return variable in gpiod_to_irq()
gpiolib: Remove redundant assignment of return variable

drivers/gpio/gpiolib.c | 123 ++++++++++++++++++-----------------------
1 file changed, 53 insertions(+), 70 deletions(-)

--
2.47.2