diff options
author | 2024-10-18 11:10:09 +0200 | |
---|---|---|
committer | 2024-10-22 08:59:08 +0200 | |
commit | 49182c87af377ec4ae0a5e116a9059e03b083574 (patch) | |
tree | 0424c6567bf2ab1c84f04de0a1d753707fca59dd | |
parent | gpio: max730x: use devres to shrink and simplify code (diff) | |
download | wireguard-linux-49182c87af377ec4ae0a5e116a9059e03b083574.tar.xz wireguard-linux-49182c87af377ec4ae0a5e116a9059e03b083574.zip |
gpiolib: notify user-space when a driver requests its own desc
We notify user-space about lines being requested from user-space or by
drivers calling gpiod_get() but not when drivers request their own lines
so add the missing call to gpiod_line_state_notify().
Reviewed-by: Kent Gibson <warthog618@gmail.com>
Link: https://lore.kernel.org/r/20241018-gpio-notify-in-kernel-events-v5-1-c79135e58a1c@linaro.org
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
-rw-r--r-- | drivers/gpio/gpiolib.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index 97346b746ef5..c09464f70f73 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c @@ -2532,6 +2532,8 @@ struct gpio_desc *gpiochip_request_own_desc(struct gpio_chip *gc, return ERR_PTR(ret); } + gpiod_line_state_notify(desc, GPIO_V2_LINE_CHANGED_REQUESTED); + return desc; } EXPORT_SYMBOL_GPL(gpiochip_request_own_desc); |