Skip to contentSkip to conversation

ARM: dts: imx53-cx9020: Fix the Ethernet PHY reset GPIO polarity

PATCH New Fabio Estevam 4 participants 5 messages Nov 25, 2017 – Nov 29, 2017

Subsystems (2)
lore
Share & tools
lore

Fabio Estevam

author reviewer
#0 lore raw

PATCH 1/1 ARM: dts: imx53-cx9020: Fix the Ethernet PHY reset GPIO polarity

From: Fabio Estevam <[email protected]>

As explained in Documentation/devicetree/bindings/net/fsl-fec.txt the phy-reset-gpios is active high only if the 'phy-reset-active-high' is present.

As 'phy-reset-active-high' is not used here, fix the device tree description by passing GPIO_ACTIVE_LOW flag.

---
 arch/arm/boot/dts/imx53-cx9020.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/imx53-cx9020.dts +1 -1
index 4f54fd4..5e67e43 100644
@@ -152,7 +152,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_fec>;
 	phy-mode = "rmii";
-	phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_HIGH>;
+	phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
Signature · 1 line
2.7.4
#1 lore raw

PATCH 1/1 ARM: dts: imx53-cx9020: Fix the Ethernet PHY reset GPIO polarity

Quoted 31 lines

From: Fabio Estevam [mailto:festevam at gmail.com]
Sent: Samstag, 25. November 2017 23:51
From: Fabio Estevam <[email protected]>

As explained in Documentation/devicetree/bindings/net/fsl-fec.txt the phy-reset-gpios is active high only if the 'phy-reset-active-high' is present.

As 'phy-reset-active-high' is not used here, fix the device tree description by passing GPIO_ACTIVE_LOW flag.

---
arch/arm/boot/dts/imx53-cx9020.dts | 2 +-

1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/imx53- renamed from arch/arm/boot/dts/imx53-cx9020.dts +0 -0

cx9020.dts
index 4f54fd4..5e67e43 100644

arch/arm/boot/dts/imx53-cx9020.dts +1 -2
@@ -152,7 +152,7 @@
      pinctrl-names = "default";
      pinctrl-0 = <&pinctrl_fec>;
      phy-mode = "rmii";
-      phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_HIGH>;
+      phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
      status = "okay";
 };
 
--
Quoted 1 line

2.7.4

Beckhoff Automation GmbH & Co. KG | Managing Director: Dipl. Phys. Hans Beckhoff Registered office: Verl, Germany | Register court: Guetersloh HRA 7075

#2 lore raw

PATCH 1/1 ARM: dts: imx53-cx9020: Fix the Ethernet PHY reset GPIO polarity

In reply to Fabio Estevam
Quoted 10 lines · Fabio Estevam

From: Fabio Estevam <[email protected]>

As explained in Documentation/devicetree/bindings/net/fsl-fec.txt the phy-reset-gpios is active high only if the 'phy-reset-active-high' is present.

As 'phy-reset-active-high' is not used here, fix the device tree description by passing GPIO_ACTIVE_LOW flag.

Hi Fabio

Do you have a bigger plan than just 'documentation'. Given that device tree is an ABI, the GPIO_ACTIVE_ flag has to be ignored. Having it correct is just documentation.

If you want to fix them all, is it worth adding in a warning to detect a miss match between the GPIO_ACTIVE_* and phy-reset-active-high?

Andrew

author reviewer
#3 lore raw

PATCH 1/1 ARM: dts: imx53-cx9020: Fix the Ethernet PHY reset GPIO polarity

Hi Andrew,

Quoted 8 lines · Andrew Lunn

Hi Fabio

Do you have a bigger plan than just 'documentation'. Given that device tree is an ABI, the GPIO_ACTIVE_ flag has to be ignored. Having it correct is just documentation.

If you want to fix them all, is it worth adding in a warning to detect a miss match between the GPIO_ACTIVE_* and phy-reset-active-high?

This was the only dts with a mismatch.

Quoted 1 line

Thanks

Applied
#4 lore raw

PATCH 1/1 ARM: dts: imx53-cx9020: Fix the Ethernet PHY reset GPIO polarity

In reply to Fabio Estevam
Quoted 10 lines · Fabio Estevam

From: Fabio Estevam <[email protected]>

As explained in Documentation/devicetree/bindings/net/fsl-fec.txt the phy-reset-gpios is active high only if the 'phy-reset-active-high' is present.

As 'phy-reset-active-high' is not used here, fix the device tree description by passing GPIO_ACTIVE_LOW flag.

Applied, thanks.