Skip to content

Commit

Permalink
gpio: em: Use dynamic allocation of GPIOs
Browse files Browse the repository at this point in the history
Use dynamic allocation of GPIOs instead of looking at the gpio%u alias
in DT.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
  • Loading branch information
Geert Uytterhoeven authored and Linus Walleij committed Nov 28, 2014
1 parent 86256d1 commit fcb8bd4
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions drivers/gpio/gpio-em.c
Original file line number Diff line number Diff line change
Expand Up @@ -330,12 +330,7 @@ static int em_gio_probe(struct platform_device *pdev)
goto err0;
}

ret = of_alias_get_id(pdev->dev.of_node, "gpio");
if (ret < 0) {
dev_err(&pdev->dev, "Couldn't get OF id\n");
goto err0;
}
pdata->gpio_base = ret * 32; /* 32 GPIOs per instance */
pdata->gpio_base = -1;
}

gpio_chip = &p->gpio_chip;
Expand Down

0 comments on commit fcb8bd4

Please sign in to comment.