summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorBartosz Golaszewski <bartosz.golaszewski@linaro.org>2023-09-01 13:29:25 +0200
committerBartosz Golaszewski <bartosz.golaszewski@linaro.org>2023-09-12 10:05:58 +0200
commitfe4fa2e4f7d0722c179fffa25911ea35cafadce2 (patch)
tree791db24e85b7e5d5bb7f367de6b2716fc77451c6 /drivers
parentd56c6f798afad4e0ce97194ee22cf2745d438bb3 (diff)
downloadlinux-stable-fe4fa2e4f7d0722c179fffa25911ea35cafadce2.tar.gz
linux-stable-fe4fa2e4f7d0722c179fffa25911ea35cafadce2.tar.bz2
linux-stable-fe4fa2e4f7d0722c179fffa25911ea35cafadce2.zip
gpiolib: make gpiochip_get_desc() public
It makes sense for a GPIO driver to want to get its own descriptor without requesting it. After all, the driver knows that it'll still be valid. Let's move this helper to linux/gpio/driver.h. Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> Reviewed-by: Andy Shevchenko <andy@kernel.org> Acked-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpio/gpiolib.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/gpio/gpiolib.h b/drivers/gpio/gpiolib.h
index d1c94bd571c6..9bff5c2cf720 100644
--- a/drivers/gpio/gpiolib.h
+++ b/drivers/gpio/gpiolib.h
@@ -122,8 +122,6 @@ struct gpio_array {
unsigned long invert_mask[];
};
-struct gpio_desc *gpiochip_get_desc(struct gpio_chip *gc, unsigned int hwnum);
-
#define for_each_gpio_desc(gc, desc) \
for (unsigned int __i = 0; \
__i < gc->ngpio && (desc = gpiochip_get_desc(gc, __i)); \