]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
arm64: zynqmp: Disable Tri-state for MIO38 Pin
authorTejas Bhumkar <tejas.arvind.bhumkar@amd.com>
Fri, 20 Oct 2023 05:06:22 +0000 (10:36 +0530)
committerMichal Simek <michal.simek@amd.com>
Tue, 7 Nov 2023 12:47:09 +0000 (13:47 +0100)
gpio38 is used in SOM's kv260 to reset the Ethernet PHY.
At present, HW reset is not working properly as Tri-stateĀ 
is enabled for MIO38, causing inappropriate PHY register reads.

Disabled Tri-state for MIO38 to make HW reset work.

Tri-state disable :
ZynqMP> md 0xFF180208 2
ff18020800bfe7a3 00000540

Tri-state enable :
ZynqMP> md 0xFF180208 2
ff18020800bfe7e3 00000540

Signed-off-by: Tejas Bhumkar <tejas.arvind.bhumkar@amd.com>
Link: https://lore.kernel.org/r/20231020050622.972750-1-tejas.arvind.bhumkar@amd.com
Signed-off-by: Michal Simek <michal.simek@amd.com>
arch/arm/dts/zynqmp-sck-kv-g-revA.dtso
arch/arm/dts/zynqmp-sck-kv-g-revB.dtso

index 22e7d68d02b3fae9854b7a52536b9e975123f157..c4f1da92186fcca1c16237390bfebb398cdcc420 100644 (file)
 &pinctrl0 {
        status = "okay";
 
+       pinctrl_gpio0_default: gpio0-default {
+                conf {
+                        groups = "gpio0_38_grp";
+                        bias-pull-up;
+                        power-source = <IO_STANDARD_LVCMOS18>;
+                };
+
+                mux {
+                        groups = "gpio0_38_grp";
+                        function = "gpio0";
+                };
+
+                conf-tx {
+                        pins = "MIO38";
+                        bias-disable;
+                        output-enable;
+                };
+        };
+
        pinctrl_uart1_default: uart1-default {
                conf {
                        groups = "uart1_9_grp";
        };
 };
 
+&gpio {
+        status = "okay";
+        pinctrl-names = "default";
+        pinctrl-0 = <&pinctrl_gpio0_default>;
+};
+
 &uart1 {
        status = "okay";
        pinctrl-names = "default";
index eadc2563064b4ec3c24cb94b1f3e32faad8abc69..6c5e0e5660615df036a1b1eb0bc56ce7a4207b8b 100644 (file)
 &pinctrl0 {
        status = "okay";
 
+       pinctrl_gpio0_default: gpio0-default {
+               conf {
+                       groups = "gpio0_38_grp";
+                       bias-pull-up;
+                       power-source = <IO_STANDARD_LVCMOS18>;
+               };
+
+               mux {
+                       groups = "gpio0_38_grp";
+                       function = "gpio0";
+               };
+
+               conf-tx {
+                       pins = "MIO38";
+                       bias-disable;
+                       output-enable;
+               };
+       };
+
        pinctrl_uart1_default: uart1-default {
                conf {
                        groups = "uart1_9_grp";
        };
 };
 
+&gpio {
+       status = "okay";
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_gpio0_default>;
+};
+
 &uart1 {
        status = "okay";
        pinctrl-names = "default";