lkml.org 
[lkml]   [2022]   [Aug]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 2/2] gpio/rockchip: Toggle edge trigger mode after acking
Date
Otherwise the trigger mode might be out-of-sync when a level change
occurred in between.

Fixes: 53b1bfc76df2 ("pinctrl: rockchip: Avoid losing interrupts when supporting both edges")
Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com>
---

drivers/gpio/gpio-rockchip.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/gpio/gpio-rockchip.c b/drivers/gpio/gpio-rockchip.c
index a98351cd6821..736b4d90f1ca 100644
--- a/drivers/gpio/gpio-rockchip.c
+++ b/drivers/gpio/gpio-rockchip.c
@@ -338,7 +338,7 @@ static void rockchip_irq_demux(struct irq_desc *desc)
irq = __ffs(pend);
pend &= ~BIT(irq);

- dev_dbg(bank->dev, "handling irq %d\n", irq);
+ generic_handle_domain_irq(bank->domain, irq);

/*
* Triggering IRQ on both rising and falling edge
@@ -370,8 +370,6 @@ static void rockchip_irq_demux(struct irq_desc *desc)
bank->gpio_regs->ext_port);
} while ((data & BIT(irq)) != (data_old & BIT(irq)));
}
-
- generic_handle_domain_irq(bank->domain, irq);
}

chained_irq_exit(chip, desc);
--
2.20.1
\
 
 \ /
  Last update: 2022-08-20 12:08    [W:0.072 / U:0.280 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site