diff options
author | Sander Vanheule <sander@svanheule.net> | 2021-10-28 10:52:43 +0200 |
---|---|---|
committer | Bartosz Golaszewski <brgl@bgdev.pl> | 2021-10-30 16:58:58 +0200 |
commit | 585a07079909ba9061ddd88214c36653e1aef71a (patch) | |
tree | 91c8ce8d6923c8f37e2f9959ce0b5d5b04cd7160 /drivers/gpio/gpio-realtek-otto.c | |
parent | dd1695a221e0eb60e345095deca28a45c3284428 (diff) |
gpio: realtek-otto: fix GPIO line IRQ offset
The irqchip uses one domain for all GPIO lines, so the line offset
should be determined w.r.t. the first line of the first port, not the
first line of the triggered port.
Fixes: 0d82fb1127fb ("gpio: Add Realtek Otto GPIO support")
Signed-off-by: Sander Vanheule <sander@svanheule.net>
Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
Diffstat (limited to 'drivers/gpio/gpio-realtek-otto.c')
-rw-r--r-- | drivers/gpio/gpio-realtek-otto.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpio/gpio-realtek-otto.c b/drivers/gpio/gpio-realtek-otto.c index eeeb39bc171d..bd75401b549d 100644 --- a/drivers/gpio/gpio-realtek-otto.c +++ b/drivers/gpio/gpio-realtek-otto.c @@ -205,7 +205,7 @@ static void realtek_gpio_irq_handler(struct irq_desc *desc) status = realtek_gpio_read_isr(ctrl, lines_done / 8); port_pin_count = min(gc->ngpio - lines_done, 8U); for_each_set_bit(offset, &status, port_pin_count) - generic_handle_domain_irq(gc->irq.domain, offset); + generic_handle_domain_irq(gc->irq.domain, offset + lines_done); } chained_irq_exit(irq_chip, desc); |