Skip to content

Commit 92f5f86

Browse files
tmaimonLinus Walleij
authored andcommitted
pinctrl: nuvoton: npcm8xx: clear polarity before set both edge
Clear polarity before setting both edges to ensure that the polarity is in the same state before configuring events for both edges Signed-off-by: Tomer Maimon <tmaimon77@gmail.com> Link: https://lore.kernel.org/20240716194008.3502068-4-tmaimon77@gmail.com Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
1 parent 20070bd commit 92f5f86

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,7 @@ static int npcmgpio_set_irq_type(struct irq_data *d, unsigned int type)
241241
npcm_gpio_set(&bank->gc, bank->base + NPCM8XX_GP_N_POL, gpio);
242242
break;
243243
case IRQ_TYPE_EDGE_BOTH:
244+
npcm_gpio_clr(&bank->gc, bank->base + NPCM8XX_GP_N_POL, gpio);
244245
npcm_gpio_set(&bank->gc, bank->base + NPCM8XX_GP_N_EVBE, gpio);
245246
break;
246247
case IRQ_TYPE_LEVEL_LOW:

0 commit comments

Comments
 (0)