Skip to contentSkip to conversation

Revert "arm: sun8i: orangepi-pc-plus: Set EMAC activity LEDs to active high"

PATCH Applied Chen-Yu Tsai 8 participants 27 messages Oct 24, 2020 – Oct 26, 2020

Subsystems (2)
lore
Share & tools
lore

Chen-Yu Tsai

author maintainer
#0 lore raw

PATCH 1/10 Revert "arm: sun8i: orangepi-pc-plus: Set EMAC activity LEDs to active high"

From: Chen-Yu Tsai <[email protected]>

This reverts commit 75ee680cbd2e4d0156b94f9fec50076361ab12f2.

Turns out the activity and link LEDs on the RJ45 port are active low, just like on the Orange Pi PC.

Revert the commit that says otherwise.

Fixes 75ee680cbd2e ("arm: sun8i: orangepi-pc-plus: Set EMAC activity LEDs to active high")
Fixes 4904337fe34f ("ARM: dts: sunxi: Restore EMAC changes (boards)")

---
If you have this board, please help test it.

For me, the correct lighting of the LEDs is both LEDs should be lit when connected at 100 Mbps.

---
 arch/arm/boot/dts/sun8i-h3-orangepi-pc-plus.dts | 5 -----
 1 file changed, 5 deletions(-)
arch/arm/boot/dts/sun8i-h3-orangepi-pc-plus.dts +0 -5
index 71fb73208939..babf4cf1b2f6 100644
@@ -53,11 +53,6 @@ aliases {
 	};
 };
 
-&emac {
-	/* LEDs changed to active high on the plus */
-	/delete-property/ allwinner,leds-active-low;
-};
-
 &mmc1 {
 	vmmc-supply = <&reg_vcc3v3>;
 	bus-width = <4>;
Signature · 1 line
2.28.0
author maintainer
#1 lore raw

PATCH 2/10 ARM: dts: sun6i: a31-hummingbird: Enable RGMII RX/TX delay on Ethernet PHY

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the A31 Hummingbird has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes c220aec2bb79 ("ARM: dts: sun6i: Add Merrii A31 Hummingbird support")
---
 arch/arm/boot/dts/sun6i-a31-hummingbird.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sun6i-a31-hummingbird.dts +1 -1
index 049e6ab3cf56..73de34ae37fd 100644
@@ -154,7 +154,7 @@ &gmac {
 	pinctrl-names = "default";
 	pinctrl-0 = <&gmac_rgmii_pins>;
 	phy-handle = <&phy1>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	status = "okay";
 };
 
Signature · 1 line
2.28.0
#2 lore raw

Re: [linux-sunxi] [PATCH 02/10] ARM: dts: sun6i: a31-hummingbird: Enable RGMII RX/TX delay on Ethernet PHY

Quoted 9 lines · 在 2020-10-25星期日的 00:25 +0800,Chen-Yu Tsai写道:

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the A31 Hummingbird has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Personally I think they should revert this commit, and consider other solution.

This commit breaks everything.

(Although the patch on individual DT patches are technically correct)

Quoted 25 lines
Fixes c220aec2bb79 ("ARM: dts: sun6i: Add Merrii A31 Hummingbird

support")

---
 arch/arm/boot/dts/sun6i-a31-hummingbird.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sun6i-a31-hummingbird.dts +1 -1
index 049e6ab3cf56..73de34ae37fd 100644
@@ -154,7 +154,7 @@ &gmac {
 	pinctrl-names = "default";
 	pinctrl-0 = <&gmac_rgmii_pins>;
 	phy-handle = <&phy1>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	status = "okay";
 };
 
Signature · 1 line
2.28.0
#3 lore raw

Re: [linux-sunxi] [PATCH 02/10] ARM: dts: sun6i: a31-hummingbird: Enable RGMII RX/TX delay on Ethernet PHY

Dne sobota, 24. oktober 2020 ob 19:51:06 CEST je Icenowy Zheng napisal(a):

Quoted 12 lines · 在 2020-10-25星期日的 00:25 +0800,Chen-Yu Tsai写道:
Quoted 10 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the A31 Hummingbird has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Quoted 5 lines

Personally I think they should revert this commit, and consider other solution.

This commit breaks everything.

Previously broken driver allowed inproper DT to work, so you have to fix everything eventually.

Plus side, there is no need to have hack for Pine64 Plus ethernet anymore.

Best regards,
Jernej

Quoted 27 lines

(Although the patch on individual DT patches are technically correct)

Quoted 25 lines
Fixes c220aec2bb79 ("ARM: dts: sun6i: Add Merrii A31 Hummingbird

support")

---

 arch/arm/boot/dts/sun6i-a31-hummingbird.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sun6i-a31-hummingbird.dts +1 -1
index 049e6ab3cf56..73de34ae37fd 100644
@@ -154,7 +154,7 @@ &gmac {
 
 	pinctrl-names = "default";
 	pinctrl-0 = <&gmac_rgmii_pins>;
 	phy-handle = <&phy1>;
 
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 

status = "okay";

};

#4 lore raw

Re: [linux-sunxi] [PATCH 02/10] ARM: dts: sun6i: a31-hummingbird: Enable RGMII RX/TX delay on Ethernet PHY

于 2020年10月25日 GMT+08:00 上午2:30:35, "Jernej Škrabec" <[email protected]> 写到:

Quoted 17 lines

Dne sobota, 24. oktober 2020 ob 19:51:06 CEST je Icenowy Zheng napisal(a):

Quoted 15 lines · 在 2020-10-25星期日的 00:25 +0800,Chen-Yu Tsai写道:
Quoted 10 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the A31 Hummingbird has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Personally I think they should revert this commit, and consider other solution.

Quoted 6 lines
Quoted 2 lines

This commit breaks everything.

Previously broken driver allowed inproper DT to work, so you have to fix
everything eventually.

There is no "improper DT" if it's already shipped, DT should suffer driver change, not changed to match driver.

I think at least Fedora tends to ship a DT with a system image that will not get updated when kernel gets updated.

Quoted 34 lines

Plus side, there is no need to have hack for Pine64 Plus ethernet anymore.

Best regards,
Jernej

Quoted 27 lines

(Although the patch on individual DT patches are technically correct)

Quoted 25 lines
Fixes c220aec2bb79 ("ARM: dts: sun6i: Add Merrii A31 Hummingbird

support")

---

 arch/arm/boot/dts/sun6i-a31-hummingbird.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sun6i-a31-hummingbird.dts +1 -1
index 049e6ab3cf56..73de34ae37fd 100644
@@ -154,7 +154,7 @@ &gmac {
 
 	pinctrl-names = "default";
 	pinctrl-0 = <&gmac_rgmii_pins>;
 	phy-handle = <&phy1>;
 
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 

status = "okay";

};

#5 lore raw

Re: [linux-sunxi] [PATCH 02/10] ARM: dts: sun6i: a31-hummingbird: Enable RGMII RX/TX delay on Ethernet PHY

Hi,

Quoted 28 lines · Icenowy Zheng

于 2020年10月25日 GMT+08:00 上午2:30:35, "Jernej Škrabec" <[email protected]> 写到:

Quoted 17 lines

Dne sobota, 24. oktober 2020 ob 19:51:06 CEST je Icenowy Zheng napisal(a):

Quoted 15 lines · 在 2020-10-25星期日的 00:25 +0800,Chen-Yu Tsai写道:
Quoted 10 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the A31 Hummingbird has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Personally I think they should revert this commit, and consider other solution.

Quoted 6 lines
Quoted 2 lines

This commit breaks everything.

Previously broken driver allowed inproper DT to work, so you have to fix
everything eventually.

Quoted 5 lines

There is no "improper DT" if it's already shipped, DT should suffer driver change, not changed to match driver.

I think at least Fedora tends to ship a DT with a system image that will not get updated when kernel gets updated.

I think we are missing a phy-mode saying use RGMII but don't change the delay set by the hardware.
Or maybe introduce a phy-mode='rgmii-noid' to explicitly disable the RX/TD delay using software bits
and use phy-mode='rgmii' to keep the delay set by the hardware.

Clement

Quoted 40 lines
Quoted 29 lines

Plus side, there is no need to have hack for Pine64 Plus ethernet anymore.

Best regards,
Jernej

Quoted 21 lines

(Although the patch on individual DT patches are technically correct)

Quoted 19 lines
Fixes c220aec2bb79 ("ARM: dts: sun6i: Add Merrii A31 Hummingbird

support")

---

 arch/arm/boot/dts/sun6i-a31-hummingbird.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sun6i-a31-hummingbird.dts +0 -0
index 049e6ab3cf56..73de34ae37fd 100644
@@ -154,7 +154,7 @@ &gmac {
 
   pinctrl-names = "default";
   pinctrl-0 = <&gmac_rgmii_pins>;
   phy-handle = <&phy1>;
 
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
arch/arm/boot/dts/sun6i-a31-hummingbird.dts +1 -1
-  phy-mode = "rgmii";
+  phy-mode = "rgmii-id";
 
   status = "okay";

};

--
You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/9D317C52-5F28-41A9-80DA-DBADA142B042%40aosc.io.

#6 lore raw

Re: [linux-sunxi] [PATCH 02/10] ARM: dts: sun6i: a31-hummingbird: Enable RGMII RX/TX delay on Ethernet PHY

In reply to Icenowy Zheng
Quoted 28 lines · Icenowy Zheng

于 2020年10月25日 GMT+08:00 上午2:30:35, "Jernej Škrabec" <[email protected]> 写到:

Quoted 17 lines

Dne sobota, 24. oktober 2020 ob 19:51:06 CEST je Icenowy Zheng napisal(a):

Quoted 15 lines · 在 2020-10-25星期日的 00:25 +0800,Chen-Yu Tsai写道:
Quoted 10 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the A31 Hummingbird has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Personally I think they should revert this commit, and consider other solution.

Quoted 6 lines
Quoted 2 lines

This commit breaks everything.

Previously broken driver allowed inproper DT to work, so you have to fix
everything eventually.

Quoted 6 lines

There is no "improper DT" if it's already shipped, DT should suffer driver change, not changed to match driver.

I think at least Fedora tends to ship a DT with a system image that will not get updated when kernel gets updated.

This same issue is under discussion in other places as well:

The following commit from v5.2

f81dadbcf7fd ("net: phy: realtek: Add rtl8211e rx/tx delays config")

added handling of the TX/RX delay controls on the PHY, but did so incorrectly, and therefore had no effect on any of these systems.

Commit

bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config")

fixed TX/RX delay handling in v5.9, and now, incorrect phy-mode settings in DT means losing Ethernet connectivity. This patch has been backported to -stable, even though it is not clear at all that the patch fixes any regressions, it only fixes some broken code that did not turn out to be active in the first place.

The result of this is that affected systems in the field using v5.4 or v5.8 stable kernels will lose their Ethernet connectivity once they upgrade to a newer release of the same v5.x tree that they shipped with. We may have ways to work around this more cleanly, but in the meantime, the stable backports of bbc4d71d6354 should simply be reverted (IMHO)

Acked-by on v1 2/10
#7 lore raw

Re: [PATCH 02/10] ARM: dts: sun6i: a31-hummingbird: Enable RGMII RX/TX delay on Ethernet PHY

In reply to Chen-Yu Tsai

Dne sobota, 24. oktober 2020 ob 18:25:07 CET je Chen-Yu Tsai napisal(a):

Quoted 5 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the A31 Hummingbird has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Quoted 7 lines

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes c220aec2bb79 ("ARM: dts: sun6i: Add Merrii A31 Hummingbird support")

Best regards,
Jernej

author maintainer
#8 lore raw

PATCH 3/10 ARM: dts: sun7i: cubietruck: Enable RGMII RX/TX delay on Ethernet PHY

In reply to Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Cubietruck has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 67073d97672d ("ARM: dts: sun7i: cubietruck: Enable the GMAC")
---
 arch/arm/boot/dts/sun7i-a20-cubietruck.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sun7i-a20-cubietruck.dts +1 -1
index 8c8dee6ea461..9109ca0919ad 100644
@@ -151,7 +151,7 @@ &gmac {
 	pinctrl-names = "default";
 	pinctrl-0 = <&gmac_rgmii_pins>;
 	phy-handle = <&phy1>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	status = "okay";
 };
 
Signature · 1 line
2.28.0
Reviewed-by Tested-by on v1 3/10
#9 lore raw

Re: [linux-sunxi] [PATCH 03/10] ARM: dts: sun7i: cubietruck: Enable RGMII RX/TX delay on Ethernet PHY

Quoted 22 lines · Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Cubietruck has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 67073d97672d ("ARM: dts: sun7i: cubietruck: Enable the GMAC")
---
  arch/arm/boot/dts/sun7i-a20-cubietruck.dts | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sun7i-a20-cubietruck.dts +0 -0
index 8c8dee6ea461..9109ca0919ad 100644

arch/arm/boot/dts/sun7i-a20-cubietruck.dts &gmac { · line 157

Quoted 8 lines
arch/arm/boot/dts/sun7i-a20-cubietruck.dts +1 -1
@@ -151,7 +151,7 @@ &gmac {
  	pinctrl-names = "default";
  	pinctrl-0 = <&gmac_rgmii_pins>;
  	phy-handle = <&phy1>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
  	status = "okay";
  };
 

I upgraded kernels yesterday and saw that networking had stopped working. I can confirm that this patch fixes the problem and restores connectivity on my Cubietruck. I also verified the information with the schematics, and it looks alright to me :)

Thanks!
Emilio

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

author maintainer
#10 lore raw

PATCH 4/10 ARM: dts: sun7i: bananapi-m1-plus: Enable RGMII RX/TX delay on Ethernet PHY

In reply to Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Bananapi M1+ has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 04c85ecad32a ("ARM: dts: sun7i: Add dts file for Bananapi M1 Plus board")
---
 arch/arm/boot/dts/sun7i-a20-bananapi-m1-plus.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sun7i-a20-bananapi-m1-plus.dts +1 -1
index 32d5d45a35c0..8945dbb114a2 100644
@@ -130,7 +130,7 @@ &gmac {
 	pinctrl-names = "default";
 	pinctrl-0 = <&gmac_rgmii_pins>;
 	phy-handle = <&phy1>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	phy-supply = <&reg_gmac_3v3>;
 	status = "okay";
 };
Signature · 1 line
2.28.0
Acked-by on v1 4/10
#11 lore raw

Re: [PATCH 04/10] ARM: dts: sun7i: bananapi-m1-plus: Enable RGMII RX/TX delay on Ethernet PHY

Dne sobota, 24. oktober 2020 ob 18:25:09 CET je Chen-Yu Tsai napisal(a):

Quoted 11 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Bananapi M1+ has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 04c85ecad32a ("ARM: dts: sun7i: Add dts file for Bananapi M1 Plus

board")

Quoted 1 line

Best regards,
Jernej

author maintainer
#12 lore raw

PATCH 5/10 ARM: dts: sun8i: h3: orangepi-plus2e: Enable RGMII RX/TX delay on Ethernet PHY

In reply to Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Orange Pi Plus 2E has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 4904337fe34f ("ARM: dts: sunxi: Restore EMAC changes (boards)")
Fixes 7a78ef92cdc5 ("ARM: sun8i: h3: Enable EMAC with external PHY on Orange Pi Plus 2E")
---
 arch/arm/boot/dts/sun8i-h3-orangepi-plus2e.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sun8i-h3-orangepi-plus2e.dts +1 -1
index 6dbf7b2e0c13..b6ca45d18e51 100644
@@ -67,7 +67,7 @@ &emac {
 	pinctrl-0 = <&emac_rgmii_pins>;
 	phy-supply = <&reg_gmac_3v3>;
 	phy-handle = <&ext_rgmii_phy>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	status = "okay";
 };
 
Signature · 1 line
2.28.0
Tested-by Acked-by on v1 5/10
#13 lore raw

Re: [PATCH 05/10] ARM: dts: sun8i: h3: orangepi-plus2e: Enable RGMII RX/TX delay on Ethernet PHY

Dne sobota, 24. oktober 2020 ob 18:25:10 CET je Chen-Yu Tsai napisal(a):

Quoted 5 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Orange Pi Plus 2E has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Quoted 7 lines

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 4904337fe34f ("ARM: dts: sunxi: Restore EMAC changes (boards)")
Fixes 7a78ef92cdc5 ("ARM: sun8i: h3: Enable EMAC with external PHY on

Orange Pi Plus 2E")

Quoted 1 line

Best regards,
Jernej

author maintainer
#14 lore raw

PATCH 6/10 ARM: dts: sun8i: a83t: Enable both RGMII RX/TX delay on Ethernet PHY

In reply to Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Bananapi M3 and Cubietruck Plus have the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 039359948a4b ("ARM: dts: sun8i: a83t: Enable Ethernet on two boards")
---
 arch/arm/boot/dts/sun8i-a83t-bananapi-m3.dts     | 2 +-
 arch/arm/boot/dts/sun8i-a83t-cubietruck-plus.dts | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
arch/arm/boot/dts/sun8i-a83t-bananapi-m3.dts +1 -1
index 9d34eabba121..431f70234d36 100644
@@ -131,7 +131,7 @@ &emac {
 	pinctrl-0 = <&emac_rgmii_pins>;
 	phy-supply = <&reg_sw>;
 	phy-handle = <&rgmii_phy>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	allwinner,rx-delay-ps = <700>;
 	allwinner,tx-delay-ps = <700>;
 	status = "okay";
arch/arm/boot/dts/sun8i-a83t-cubietruck-plus.dts +1 -1
index d9be511f054f..d8326a5c681d 100644
@@ -183,7 +183,7 @@ &emac {
 	pinctrl-0 = <&emac_rgmii_pins>;
 	phy-supply = <&reg_dldo4>;
 	phy-handle = <&rgmii_phy>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	status = "okay";
 };
 
Signature · 1 line
2.28.0
Acked-by on v1 6/10
#15 lore raw

Re: [PATCH 06/10] ARM: dts: sun8i: a83t: Enable both RGMII RX/TX delay on Ethernet PHY

Dne sobota, 24. oktober 2020 ob 18:25:11 CET je Chen-Yu Tsai napisal(a):

Quoted 6 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Bananapi M3 and Cubietruck Plus have the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Quoted 7 lines

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 039359948a4b ("ARM: dts: sun8i: a83t: Enable Ethernet on two boards")

Best regards,
Jernej

author maintainer
#16 lore raw

PATCH 7/10 ARM: dts: sun9i: Enable both RGMII RX/TX delay on Ethernet PHY

In reply to Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Cubieboard 4 and A80 Optimus have the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 98048143b7f8 ("ARM: dts: sun9i: cubieboard4: Enable GMAC")
Fixes bc9bd03a44f9 ("ARM: dts: sun9i: a80-optimus: Enable GMAC")
---
 arch/arm/boot/dts/sun9i-a80-cubieboard4.dts | 2 +-
 arch/arm/boot/dts/sun9i-a80-optimus.dts     | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
arch/arm/boot/dts/sun9i-a80-cubieboard4.dts +1 -1
index d3b337b043a1..484b93df20cb 100644
@@ -129,7 +129,7 @@ &gmac {
 	pinctrl-names = "default";
 	pinctrl-0 = <&gmac_rgmii_pins>;
 	phy-handle = <&phy1>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	phy-supply = <&reg_cldo1>;
 	status = "okay";
 };
arch/arm/boot/dts/sun9i-a80-optimus.dts +1 -1
index bbc6335e5631..5c3580d712e4 100644
@@ -124,7 +124,7 @@ &gmac {
 	pinctrl-names = "default";
 	pinctrl-0 = <&gmac_rgmii_pins>;
 	phy-handle = <&phy1>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	phy-supply = <&reg_cldo1>;
 	status = "okay";
 };
Signature · 1 line
2.28.0
Acked-by on v1 7/10
#17 lore raw

Re: [PATCH 07/10] ARM: dts: sun9i: Enable both RGMII RX/TX delay on Ethernet PHY

Dne sobota, 24. oktober 2020 ob 18:25:12 CET je Chen-Yu Tsai napisal(a):

Quoted 6 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Cubieboard 4 and A80 Optimus have the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Quoted 8 lines

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 98048143b7f8 ("ARM: dts: sun9i: cubieboard4: Enable GMAC")
Fixes bc9bd03a44f9 ("ARM: dts: sun9i: a80-optimus: Enable GMAC")

Best regards,
Jernej

author maintainer
#18 lore raw

PATCH 8/10 ARM: dts: sunxi: bananapi-m2-plus: Enable RGMII RX/TX delay on Ethernet PHY

In reply to Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Bananapi M2+ has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 8c7ba536e709 ("ARM: sun8i: bananapi-m2-plus: Enable dwmac-sun8i")
Fixes 4904337fe34f ("ARM: dts: sunxi: Restore EMAC changes (boards)")
Fixes aa8fee415f46 ("ARM: dts: sun8i: h3: Split out non-SoC-specific parts of Bananapi M2 Plus")
---
 arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi +1 -1
index 39263e74fbb5..8e5cb3b3fd68 100644
@@ -126,7 +126,7 @@ &emac {
 	pinctrl-0 = <&emac_rgmii_pins>;
 	phy-supply = <&reg_gmac_3v3>;
 	phy-handle = <&ext_rgmii_phy>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 
 	status = "okay";
 };
Signature · 1 line
2.28.0
Tested-by Acked-by on v1 8/10
#19 lore raw

Re: [PATCH 08/10] ARM: dts: sunxi: bananapi-m2-plus: Enable RGMII RX/TX delay on Ethernet PHY

Dne sobota, 24. oktober 2020 ob 18:25:13 CET je Chen-Yu Tsai napisal(a):

Quoted 5 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Bananapi M2+ has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Quoted 8 lines

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 8c7ba536e709 ("ARM: sun8i: bananapi-m2-plus: Enable dwmac-sun8i")
Fixes 4904337fe34f ("ARM: dts: sunxi: Restore EMAC changes (boards)")
Fixes aa8fee415f46 ("ARM: dts: sun8i: h3: Split out non-SoC-specific parts

of Bananapi M2 Plus")

Quoted 1 line

Best regards,
Jernej

author maintainer
#20 lore raw

PATCH 9/10 arm64: dts: allwinner: h5: libretech-all-h5-cc: Enable RGMII RX/TX delay on PHY

In reply to Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Libre Computer ALL-H5-CC has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 60d0426d7603 ("arm64: dts: allwinner: h5: Add Libre Computer ALL-H5-CC H5 board")
---
 arch/arm64/boot/dts/allwinner/sun50i-h5-libretech-all-h5-cc.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/allwinner/sun50i-h5-libretech-all-h5-cc.dts +1 -1
index df1b9263ad0e..6e30a564c87f 100644
@@ -36,7 +36,7 @@ &emac {
 	pinctrl-0 = <&emac_rgmii_pins>;
 	phy-supply = <&reg_gmac_3v3>;
 	phy-handle = <&ext_rgmii_phy>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	/delete-property/ allwinner,leds-active-low;
 	status = "okay";
 };
Signature · 1 line
2.28.0
Acked-by on v1 9/10
#21 lore raw

Re: [PATCH 09/10] arm64: dts: allwinner: h5: libretech-all-h5-cc: Enable RGMII RX/TX delay on PHY

Dne sobota, 24. oktober 2020 ob 18:25:14 CET je Chen-Yu Tsai napisal(a):

Quoted 11 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Libre Computer ALL-H5-CC has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes 60d0426d7603 ("arm64: dts: allwinner: h5: Add Libre Computer ALL-H5-

CC H5 board")

Quoted 1 line

Was this board ever in production? I can't find anything relevant about it on the internet.

Anyway:

Best regards,
Jernej

author maintainer
#22 lore raw

PATCH 10/10 arm64: dts: allwinner: a64: bananapi-m64: Enable RGMII RX/TX delay on PHY

In reply to Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Bananapi M64 has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes e7295499903d ("arm64: allwinner: bananapi-m64: Enable dwmac-sun8i")
Fixes 94f442886711 ("arm64: dts: allwinner: A64: Restore EMAC changes")
---
 arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts +1 -1
index 3ea5182ca489..e5e840b9fbb4 100644
@@ -105,7 +105,7 @@ &ehci1 {
 &emac {
 	pinctrl-names = "default";
 	pinctrl-0 = <&rgmii_pins>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	phy-handle = <&ext_rgmii_phy>;
 	phy-supply = <&reg_dc1sw>;
 	status = "okay";
Signature · 1 line
2.28.0
Tested-by on v1 10/10
#23 lore raw

Re: [linux-sunxi] [PATCH 10/10] arm64: dts: allwinner: a64: bananapi-m64: Enable RGMII RX/TX delay on PHY

Quoted 32 lines · Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Bananapi M64 has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes e7295499903d ("arm64: allwinner: bananapi-m64: Enable dwmac-sun8i")
Fixes 94f442886711 ("arm64: dts: allwinner: A64: Restore EMAC changes")
---
 arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts +1 -1
index 3ea5182ca489..e5e840b9fbb4 100644
@@ -105,7 +105,7 @@ &ehci1 {
 &emac {
 	pinctrl-names = "default";
 	pinctrl-0 = <&rgmii_pins>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	phy-handle = <&ext_rgmii_phy>;
 	phy-supply = <&reg_dc1sw>;
 	status = "okay";
Signature · 1 line
2.28.0

Thanks

#24 lore raw

Re: Re: [linux-sunxi] [PATCH 10/10] arm64: dts: allwinner: a64: bananapi-m64: Enable RGMII RX/TX delay on PHY

Dne sobota, 24. oktober 2020 ob 21:58:03 CET je Corentin Labbe napisal(a):

Quoted 11 lines · Chen-Yu Tsai
Quoted 10 lines

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Bananapi M64 has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Quoted 8 lines

Review

Quoted 8 lines
Fixes e7295499903d ("arm64: allwinner: bananapi-m64: Enable dwmac-sun8i")
Fixes 94f442886711 ("arm64: dts: allwinner: A64: Restore EMAC changes")
---
 arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
(quoted diff) renamed from arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts +0 -0

arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts

Quoted 8 lines
Quoted 8 lines

index 3ea5182ca489..e5e840b9fbb4 100644

arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts +0 -1
@@ -105,7 +105,7 @@ &ehci1 {
 &emac {
 	pinctrl-names = "default";
 	pinctrl-0 = <&rgmii_pins>;
-	phy-mode = "rgmii";
Quoted 8 lines
Quoted 6 lines
arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts +1 -0
+	phy-mode = "rgmii-id";
 	phy-handle = <&ext_rgmii_phy>;
 	phy-supply = <&reg_dc1sw>;
 	status = "okay";
Signature · 1 line
2.28.0

Best regards,
Jernej

#25 lore raw

Re: [PATCH 10/10] arm64: dts: allwinner: a64: bananapi-m64: Enable RGMII RX/TX delay on PHY

In reply to Chen-Yu Tsai
Quoted 5 lines · Chen-Yu Tsai

From: Chen-Yu Tsai <[email protected]>

The Ethernet PHY on the Bananapi M64 has the RX and TX delays enabled on the PHY, using pull-ups on the RXDLY and TXDLY pins.

Quoted 8 lines

Fix the phy-mode description to correct reflect this so that the implementation doesn't reconfigure the delays incorrectly. This happened with commit bbc4d71d6354 ("net: phy: realtek: fix rtl8211e rx/tx delay config").

Fixes e7295499903d ("arm64: allwinner: bananapi-m64: Enable dwmac-sun8i")
Fixes 94f442886711 ("arm64: dts: allwinner: A64: Restore EMAC changes")

Applied all the patches, thanks!
Maxime

Tested-by Acked-by on v1 1/10
#26 lore raw
In reply to Chen-Yu Tsai

Dne sobota, 24. oktober 2020 ob 18:25:06 CET je Chen-Yu Tsai napisal(a):

Quoted 10 lines

From: Chen-Yu Tsai <[email protected]>

This reverts commit 75ee680cbd2e4d0156b94f9fec50076361ab12f2.

Turns out the activity and link LEDs on the RJ45 port are active low, just like on the Orange Pi PC.

Revert the commit that says otherwise.

Fixes 75ee680cbd2e ("arm: sun8i: orangepi-pc-plus: Set EMAC activity LEDs

to active high")

Quoted 7 lines
Fixes 4904337fe34f ("ARM: dts: sunxi: Restore EMAC changes (boards)")

---
If you have this board, please help test it.

For me, the correct lighting of the LEDs is both LEDs should be lit when connected at 100 Mbps.

Best regards,
Jernej