Skip to content

Commit f6c35df

Browse files
stevenlee7189brgl
authored andcommitted
gpio: gpio-aspeed-sgpio: Fix wrong hwirq in irq handler.
The current hwirq is calculated based on the old GPIO pin order(input GPIO range is from 0 to ngpios - 1). It should be calculated based on the current GPIO input pin order(input GPIOs are 0, 2, 4, ..., (ngpios - 1) * 2). Signed-off-by: Steven Lee <[email protected]> Signed-off-by: Bartosz Golaszewski <[email protected]>
1 parent 2dd824c commit f6c35df

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/gpio/gpio-aspeed-sgpio.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -395,7 +395,7 @@ static void aspeed_sgpio_irq_handler(struct irq_desc *desc)
395395
reg = ioread32(bank_reg(data, bank, reg_irq_status));
396396

397397
for_each_set_bit(p, &reg, 32)
398-
generic_handle_domain_irq(gc->irq.domain, i * 32 + p);
398+
generic_handle_domain_irq(gc->irq.domain, i * 32 + p * 2);
399399
}
400400

401401
chained_irq_exit(ic, desc);

0 commit comments

Comments
 (0)