diff options
author | Linus Walleij <linus.walleij@linaro.org> | 2017-08-31 07:58:17 +0200 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2017-08-31 09:05:30 +0200 |
commit | 9e238e380c2a8aff21d37f713b5c24b079a726a5 (patch) | |
tree | bc8e0be7574415a20f4232e175ea34bcdc45f810 /drivers/gpio | |
parent | 1253baaafff03c695e49d6c63956f4ccf12dc0c8 (diff) | |
download | linux-9e238e380c2a8aff21d37f713b5c24b079a726a5.tar.bz2 |
Revert "gpiolib: request the gpio before querying its direction"
This reverts commit 108d23e322a247d9f89ba2e2742520ead0944cc9.
It turns out this causes a regression on the OMAP, Marvell
and Renesas.
Reported-by: Tony Lindgren <tony@atomide.com>
Reported-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Reported-by: Jacopo Mondi <jacopo@jmondi.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio')
-rw-r--r-- | drivers/gpio/gpiolib.c | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index e452768f316d..eb80dac4e26a 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c @@ -1221,14 +1221,6 @@ int gpiochip_add_data(struct gpio_chip *chip, void *data) struct gpio_desc *desc = &gdev->descs[i]; desc->gdev = gdev; - - if (chip->request) { - status = chip->request(chip, i); - if (status < 0) - /* The GPIO is unavailable, so skip it */ - continue; - } - /* * REVISIT: most hardware initializes GPIOs as inputs * (often with pullups enabled) so power usage is @@ -1254,9 +1246,6 @@ int gpiochip_add_data(struct gpio_chip *chip, void *data) */ set_bit(FLAG_IS_OUT, &desc->flags); } - - if (chip->free) - chip->free(chip, i); } #ifdef CONFIG_PINCTRL |