Skip to contentSkip to conversation

pinctrl: rockchip: clear int status when driver probed

PATCH In review Jianqun Xu 3 participants 3 messages Feb 23, 2021 – Mar 2, 2021

Subsystems (3)
lore
Share & tools
lore

Jianqun Xu

author
#0 lore raw

PATCH 1/1 pinctrl: rockchip: clear int status when driver probed

Some devices may do gpio interrupt trigger and make an int status before pinctrl driver probed, then the gpio handler will keep complain untill the device driver works to stop trigger.

---
 drivers/pinctrl/pinctrl-rockchip.c | 1 +
 1 file changed, 1 insertion(+)
drivers/pinctrl/pinctrl-rockchip.c +1 -0
index aa1a1c850d05..ec4cb88572cf 100644
@@ -3433,6 +3433,7 @@ static int rockchip_interrupts_register(struct platform_device *pdev,
 		 * things enabled, so for us that's all masked and all enabled.
 		 */
 		writel_relaxed(0xffffffff, bank->reg_base + GPIO_INTMASK);
+		writel_relaxed(0xffffffff, bank->reg_base + GPIO_PORTS_EOI);
 		writel_relaxed(0xffffffff, bank->reg_base + GPIO_INTEN);
 		gc->mask_cache = 0xffffffff;
 
Signature · 9 lines
2.25.1




_______________________________________________
Linux-rockchip mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-rockchip
maintainer Reviewed-by on v1 1/1
#1 lore raw

Am Dienstag, 23. Februar 2021, 11:19:37 CET schrieb Jianqun Xu:

Quoted 6 lines

Some devices may do gpio interrupt trigger and make an int status before pinctrl driver probed, then the gpio handler will keep complain untill the device driver works to stop trigger.

Quoted 10 lines
---
 drivers/pinctrl/pinctrl-rockchip.c | 1 +
 1 file changed, 1 insertion(+)
drivers/pinctrl/pinctrl-rockchip.c +0 -0
index aa1a1c850d05..ec4cb88572cf 100644

drivers/pinctrl/pinctrl-rockchip.c static int rockchip_interrupts_register(struct platform_device *pdev, · line 3439

Quoted 7 lines
drivers/pinctrl/pinctrl-rockchip.c +1 -0
@@ -3433,6 +3433,7 @@ static int rockchip_interrupts_register(struct platform_device *pdev,
 		 * things enabled, so for us that's all masked and all enabled.
 		 */
 		writel_relaxed(0xffffffff, bank->reg_base + GPIO_INTMASK);
+		writel_relaxed(0xffffffff, bank->reg_base + GPIO_PORTS_EOI);
 		writel_relaxed(0xffffffff, bank->reg_base + GPIO_INTEN);
 		gc->mask_cache = 0xffffffff;
 

_______________________________________________
Linux-rockchip mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-rockchip