Skip to content

Commit 4e31062

Browse files
MrVanBartosz Golaszewski
authored andcommitted
gpiolib: of: Add polarity quirk for s5m8767
This is prepare patch for switching s5m8767 regulator driver to use GPIO descriptor. DTS for exynos5250 spring incorrectly specifies "active low" polarity for the DVS and DS line. But per datasheet, they are actually active high. So add polarity quirk for it. Signed-off-by: Peng Fan <[email protected]> Reviewed-by: Linus Walleij <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Bartosz Golaszewski <[email protected]>
1 parent 0af2f6b commit 4e31062

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

drivers/gpio/gpiolib-of.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -222,6 +222,15 @@ static void of_gpio_try_fixup_polarity(const struct device_node *np,
222222
*/
223223
{ "lantiq,pci-xway", "gpio-reset", false },
224224
#endif
225+
#if IS_ENABLED(CONFIG_REGULATOR_S5M8767)
226+
/*
227+
* According to S5M8767, the DVS and DS pin are
228+
* active-high signals. However, exynos5250-spring.dts use
229+
* active-low setting.
230+
*/
231+
{ "samsung,s5m8767-pmic", "s5m8767,pmic-buck-dvs-gpios", true },
232+
{ "samsung,s5m8767-pmic", "s5m8767,pmic-buck-ds-gpios", true },
233+
#endif
225234
#if IS_ENABLED(CONFIG_TOUCHSCREEN_TSC2005)
226235
/*
227236
* DTS for Nokia N900 incorrectly specified "active high"

0 commit comments

Comments
 (0)