Skip to content

Commit bcc62fb

Browse files
committed
Merge tag 'gpio-for-linus' of git://git.secretlab.ca/git/linux-2.6
Pull GPIO omap bug fix from Grant Likely. * tag 'gpio-for-linus' of git://git.secretlab.ca/git/linux-2.6: gpio/omap: fix incorrect initialization of omap_gpio_mod_init
2 parents ec53646 + 6edd94d commit bcc62fb

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

drivers/gpio/gpio-omap.c

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -965,18 +965,15 @@ static void omap_gpio_mod_init(struct gpio_bank *bank)
965965
}
966966

967967
_gpio_rmw(base, bank->regs->irqenable, l, bank->regs->irqenable_inv);
968-
_gpio_rmw(base, bank->regs->irqstatus, l,
969-
bank->regs->irqenable_inv == false);
970-
_gpio_rmw(base, bank->regs->irqenable, l, bank->regs->debounce_en != 0);
971-
_gpio_rmw(base, bank->regs->irqenable, l, bank->regs->ctrl != 0);
968+
_gpio_rmw(base, bank->regs->irqstatus, l, !bank->regs->irqenable_inv);
972969
if (bank->regs->debounce_en)
973-
_gpio_rmw(base, bank->regs->debounce_en, 0, 1);
970+
__raw_writel(0, base + bank->regs->debounce_en);
974971

975972
/* Save OE default value (0xffffffff) in the context */
976973
bank->context.oe = __raw_readl(bank->base + bank->regs->direction);
977974
/* Initialize interface clk ungated, module enabled */
978975
if (bank->regs->ctrl)
979-
_gpio_rmw(base, bank->regs->ctrl, 0, 1);
976+
__raw_writel(0, base + bank->regs->ctrl);
980977
}
981978

982979
static __devinit void

0 commit comments

Comments
 (0)