Thread (28 messages) 28 messages, 6 authors, 2022-01-31
STALE1583d
Revisions (3)
  1. v1 current
  2. v2 [diff vs current]
  3. v4 [diff vs current]

[PATCH 7/7] staging: greybus: gpio: Use generic_handle_irq_safe().

From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Date: 2022-01-27 11:33:28
Also in: linux-i2c, linux-staging, linux-usb, lkml
Subsystem: greybus sdio/gpio/spi protocols drivers, greybus subsystem, staging subsystem, the rest · Maintainers: Rui Miguel Silva, Johan Hovold, Alex Elder, Greg Kroah-Hartman, Linus Torvalds

Instead of manually disabling interrupts before invoking use
generic_handle_irq() which can be invoked with enabled and disabled
interrupts.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
---
 drivers/staging/greybus/gpio.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/staging/greybus/gpio.c b/drivers/staging/greybus/gpio.c
index 7e6347fe93f99..8a7cf1d0e9688 100644
--- a/drivers/staging/greybus/gpio.c
+++ b/drivers/staging/greybus/gpio.c
@@ -391,10 +391,7 @@ static int gb_gpio_request_handler(struct gb_operation *op)
 		return -EINVAL;
 	}
 
-	local_irq_disable();
-	ret = generic_handle_irq(irq);
-	local_irq_enable();
-
+	ret = generic_handle_irq_safe(irq);
 	if (ret)
 		dev_err(dev, "failed to invoke irq handler\n");
 
-- 
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