Skip to content

Commit

Permalink
gpio/mpc8xxx: fix qoriq GPIO reading
Browse files Browse the repository at this point in the history
Qoriq requires the IBE register to be set to enable GPIO inputs to be
read.  Set it.

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Link: https://lore.kernel.org/r/E1iX3HC-00069N-0T@rmk-PC.armlinux.org.uk
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
  • Loading branch information
Russell King authored and Linus Walleij committed Nov 21, 2019
1 parent 4e50573 commit 787b64a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/gpio/gpio-mpc8xxx.c
Original file line number Diff line number Diff line change
Expand Up @@ -387,6 +387,9 @@ static int mpc8xxx_probe(struct platform_device *pdev)

gc->to_irq = mpc8xxx_gpio_to_irq;

if (of_device_is_compatible(np, "fsl,qoriq-gpio"))
gc->write_reg(mpc8xxx_gc->regs + GPIO_IBE, 0xffffffff);

ret = gpiochip_add_data(gc, mpc8xxx_gc);
if (ret) {
pr_err("%pOF: GPIO chip registration failed with status %d\n",
Expand Down

0 comments on commit 787b64a

Please sign in to comment.