]> git.baikalelectronics.ru Git - kernel.git/commit
pinctrl: ocelot: Fix incorrect trigger of the interrupt.
authorHoratiu Vultur <horatiu.vultur@microchip.com>
Tue, 18 Oct 2022 07:09:59 +0000 (09:09 +0200)
committerLinus Walleij <linus.walleij@linaro.org>
Tue, 18 Oct 2022 08:42:10 +0000 (10:42 +0200)
commite746be75c78f02f3aced292a7721c7028772b4c0
treed1c91ff5000c896558ac85bf8c2c013aa70b242d
parent38381b0ee46bdc72697a06ac5f0723f7383fdeca
pinctrl: ocelot: Fix incorrect trigger of the interrupt.

The interrupt controller can detect only link changes. So in case an
external device generated a level based interrupt, then the interrupt
controller detected correctly the first edge. But the problem was that
the interrupt controller was detecting also the edge when the interrupt
was cleared. So it would generate another interrupt.
The fix for this is to clear the second interrupt but still check the
interrupt line status.

Fixes: 4ebab0460deb ("pinctrl: ocelot: Fix interrupt controller")
Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
Tested-by: Michael Walle <michael@walle.cc>
Link: https://lore.kernel.org/r/20221018070959.1322606-1-horatiu.vultur@microchip.com
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/pinctrl-ocelot.c