Thread (13 messages) 13 messages, 3 authors, 2024-08-26
STALE680d
Revisions (4)
  1. v1 current
  2. v3 [diff vs current]
  3. v4 [diff vs current]
  4. v5 [diff vs current]

[PATCH v1 3/5] gpio: rockchip: Set input direction in irq_request_resources

From: Ye Zhang <hidden>
Date: 2024-08-15 07:42:19
Also in: linux-gpio, linux-rockchip, lkml
Subsystem: arm/rockchip soc support, gpio subsystem, the rest · Maintainers: Heiko Stuebner, Linus Walleij, Bartosz Golaszewski, Linus Torvalds

Set input direction to avoid FLAG_IS_OUT in gpiochip_lock_as_irq

Signed-off-by: Ye Zhang <redacted>
---
 drivers/gpio/gpio-rockchip.c | 2 ++
 1 file changed, 2 insertions(+)
diff --git a/drivers/gpio/gpio-rockchip.c b/drivers/gpio/gpio-rockchip.c
index b2f26a16b1f6..8949324ed816 100644
--- a/drivers/gpio/gpio-rockchip.c
+++ b/drivers/gpio/gpio-rockchip.c
@@ -475,6 +475,8 @@ static int rockchip_irq_reqres(struct irq_data *d)
 	struct irq_chip_generic *gc = irq_data_get_irq_chip_data(d);
 	struct rockchip_pin_bank *bank = gc->private;
 
+	rockchip_gpio_direction_input(&bank->gpio_chip, d->hwirq);
+
 	return gpiochip_reqres_irq(&bank->gpio_chip, d->hwirq);
 }
 
-- 
2.34.1

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help