]> Git Repo - J-u-boot.git/blobdiff - drivers/pinctrl/pinctrl-zynqmp.c
Revert "Merge patch series "arm: dts: am62-beagleplay: Fix Beagleplay Ethernet""
[J-u-boot.git] / drivers / pinctrl / pinctrl-zynqmp.c
index e9857f5ed9df1d1eb6b341f41256f74fd487a2d6..eb17a4290b7d6716972b5fe6df1781ed62729145 100644 (file)
@@ -473,6 +473,10 @@ static int zynqmp_pinconf_set(struct udevice *dev, unsigned int pin,
                                 pin);
                break;
        case PIN_CONFIG_BIAS_HIGH_IMPEDANCE:
+               param = PM_PINCTRL_CONFIG_TRI_STATE;
+               arg = PM_PINCTRL_TRI_STATE_ENABLE;
+               ret = zynqmp_pm_pinctrl_set_config(pin, param, arg);
+               break;
        case PIN_CONFIG_LOW_POWER_MODE:
                /*
                 * This cases are mentioned in dts but configurable
@@ -481,6 +485,11 @@ static int zynqmp_pinconf_set(struct udevice *dev, unsigned int pin,
                 */
                ret = 0;
                break;
+       case PIN_CONFIG_OUTPUT_ENABLE:
+               param = PM_PINCTRL_CONFIG_TRI_STATE;
+               arg = PM_PINCTRL_TRI_STATE_DISABLE;
+               ret = zynqmp_pm_pinctrl_set_config(pin, param, arg);
+               break;
        default:
                dev_warn(dev, "unsupported configuration parameter '%u'\n",
                         param);
@@ -539,6 +548,8 @@ static int zynqmp_pinctrl_get_pin_muxing(struct udevice *dev,
                                     &pinmux.drive_strength);
        zynqmp_pm_pinctrl_get_config(selector, PM_PINCTRL_CONFIG_VOLTAGE_STATUS,
                                     &pinmux.volt_sts);
+       zynqmp_pm_pinctrl_get_config(selector, PM_PINCTRL_CONFIG_TRI_STATE,
+                                    &pinmux.tri_state);
 
        switch (pinmux.drive_strength) {
        case PM_PINCTRL_DRIVE_STRENGTH_2MA:
@@ -559,13 +570,15 @@ static int zynqmp_pinctrl_get_pin_muxing(struct udevice *dev,
                return -EINVAL;
        }
 
-       snprintf(buf, size, "slew:%s\tbias:%s\tpull:%s\tinput:%s\tdrive:%dmA\tvolt:%s",
+       snprintf(buf, size,
+                "slew:%s\tbias:%s\tpull:%s\tinput:%s\tdrive:%dmA\tvolt:%s\ttri_state:%s",
                 pinmux.slew ? "slow" : "fast",
                 pinmux.bias ? "enabled" : "disabled",
                 pinmux.pull_ctrl ? "up" : "down",
                 pinmux.input_type ? "schmitt" : "cmos",
                 pinmux.drive_strength,
-                pinmux.volt_sts ? "1.8" : "3.3");
+                pinmux.volt_sts ? "1.8" : "3.3",
+                pinmux.tri_state ? "enabled" : "disabled");
 
        return 0;
 }
This page took 0.026394 seconds and 4 git commands to generate.