aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpio/gpiolib-of.c
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@linaro.org>2019-06-12 09:47:15 +0200
committerLinus Walleij <linus.walleij@linaro.org>2019-06-12 09:47:15 +0200
commit74a36e4a038b417bb579e86bb769fddf674ca1a1 (patch)
treeb89a5c9a09c32075a51170785ab674b9c69e4818 /drivers/gpio/gpiolib-of.c
parentgpio: altera: Allocate irq_chip dynamically (diff)
parentgpio: of: parse stmmac PHY reset line specific active-low property (diff)
downloadlinux-dev-74a36e4a038b417bb579e86bb769fddf674ca1a1.tar.xz
linux-dev-74a36e4a038b417bb579e86bb769fddf674ca1a1.zip
Merge branch 'ib-snps-reset-gpio' into devel
Diffstat (limited to 'drivers/gpio/gpiolib-of.c')
-rw-r--r--drivers/gpio/gpiolib-of.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/gpio/gpiolib-of.c b/drivers/gpio/gpiolib-of.c
index 00deb885409c..a8f02f551d6b 100644
--- a/drivers/gpio/gpiolib-of.c
+++ b/drivers/gpio/gpiolib-of.c
@@ -158,6 +158,12 @@ static void of_gpio_flags_quirks(struct device_node *np,
}
}
}
+
+ /* Legacy handling of stmmac's active-low PHY reset line */
+ if (IS_ENABLED(CONFIG_STMMAC_ETH) &&
+ !strcmp(propname, "snps,reset-gpio") &&
+ of_property_read_bool(np, "snps,reset-active-low"))
+ *flags |= OF_GPIO_ACTIVE_LOW;
}
/**