gpio: mxc: Always set GPIOs used as interrupt source to INPUT mode
Subsystems (2)
PATCH 1/1 gpio: mxc: Always set GPIOs used as interrupt source to INPUT mode
Always configure GPIO pins which are used as interrupt source as INPUTs. In case the default pin configuration is OUTPUT, or the prior stage does configure the pins as OUTPUT, then Linux will not reconfigure the pin as INPUT and no interrupts are received.
Always configure interrupt source GPIO pin as input to fix the above case.
Signed-off-by Marek Vasut <[email protected]>
Cc Bartosz Golaszewski <[email protected]>
Cc Linus Walleij <[email protected]>
Cc Loic Poulain <[email protected]>
Cc Marc Zyngier <[email protected]>
--- drivers/gpio/gpio-mxc.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/gpio/gpio-mxc.c +2 -0
@@ -204,6 +204,8 @@ static int gpio_set_irq_type(struct irq_data *d, u32 type)writel (1 << gpio_idx, port->base +GPIO_ISR ); +writel (1 << gpio_idx, port->base +GPIO_GDIR ); +return 0 ; }
Signature · 1 line
2.35.1