Skip to contentSkip to conversation

pinctrl: mcp23s08: Fix missing unlock on error in mcp23s08_irq()

PATCH In review Zou Wei 2 participants 2 messages Jun 8, 2021 – Jun 9, 2021

Subsystems (2)
lore
Share & tools
lore

Zou Wei

author
#0 lore raw

PATCH v2 1/1 pinctrl: mcp23s08: Fix missing unlock on error in mcp23s08_irq()

Add the missing unlock before return from function mcp23s08_irq() in the error handling case.

v1-->v2:
remove the "return IRQ_HANDLED" line

Fixes 897120d41e7a ("pinctrl: mcp23s08: fix race condition in irq handler")
---
 drivers/pinctrl/pinctrl-mcp23s08.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/pinctrl/pinctrl-mcp23s08.c +1 -1
index 799d596..d025957 100644
@@ -353,7 +353,7 @@ static irqreturn_t mcp23s08_irq(int irq, void *data)
 
 	if (intf == 0) {
 		/* There is no interrupt pending */
-		return IRQ_HANDLED;
+		goto unlock;
 	}
 
 	if (mcp_read(mcp, MCP_INTCAP, &intcap))
Signature · 1 line
2.6.2
#1 lore raw
Quoted 9 lines · Zou Wei

Add the missing unlock before return from function mcp23s08_irq() in the error handling case.

v1-->v2:
remove the "return IRQ_HANDLED" line

Fixes 897120d41e7a ("pinctrl: mcp23s08: fix race condition in irq handler")

Patch applied.

Yours,
Linus Walleij