summaryrefslogtreecommitdiff
path: root/drivers/pinctrl/meson/pinctrl-meson-gx-pmx.c
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2019-01-29 09:40:31 -0500
committerTom Rini <trini@konsulko.com>2019-01-29 09:40:31 -0500
commit5548c7a165bbd1ebb0d4599ef1d04751c37b3f79 (patch)
tree299c199260d2eb3077ababfa33ad41b8b5150a82 /drivers/pinctrl/meson/pinctrl-meson-gx-pmx.c
parent2f41ade79e5969ebea03a7dcadbeae8e03787d7e (diff)
parentc4c726c26bdc09a2c907e230fdf6c75adcc2b674 (diff)
Merge tag 'u-boot-amlogic-20190129' of git://git.denx.de/u-boot-amlogic
Adds pinconf support for the Amlogic pinctrl driver (fixed)
Diffstat (limited to 'drivers/pinctrl/meson/pinctrl-meson-gx-pmx.c')
-rw-r--r--drivers/pinctrl/meson/pinctrl-meson-gx-pmx.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/pinctrl/meson/pinctrl-meson-gx-pmx.c b/drivers/pinctrl/meson/pinctrl-meson-gx-pmx.c
index fc1538ea71..cf72576b6c 100644
--- a/drivers/pinctrl/meson/pinctrl-meson-gx-pmx.c
+++ b/drivers/pinctrl/meson/pinctrl-meson-gx-pmx.c
@@ -72,6 +72,12 @@ static int meson_gx_pinmux_group_set(struct udevice *dev,
return 0;
}
+const struct pinconf_param meson_gx_pinconf_params[] = {
+ { "bias-disable", PIN_CONFIG_BIAS_DISABLE, 0 },
+ { "bias-pull-up", PIN_CONFIG_BIAS_PULL_UP, 1 },
+ { "bias-pull-down", PIN_CONFIG_BIAS_PULL_DOWN, 1 },
+};
+
const struct pinctrl_ops meson_gx_pinctrl_ops = {
.get_groups_count = meson_pinctrl_get_groups_count,
.get_group_name = meson_pinctrl_get_group_name,
@@ -79,6 +85,10 @@ const struct pinctrl_ops meson_gx_pinctrl_ops = {
.get_function_name = meson_pinmux_get_function_name,
.pinmux_group_set = meson_gx_pinmux_group_set,
.set_state = pinctrl_generic_set_state,
+ .pinconf_params = meson_gx_pinconf_params,
+ .pinconf_num_params = ARRAY_SIZE(meson_gx_pinconf_params),
+ .pinconf_set = meson_pinconf_set,
+ .pinconf_group_set = meson_pinconf_group_set,
};
static const struct dm_gpio_ops meson_gx_gpio_ops = {