Skip to contentSkip to conversation

arm64: dts: amlogic: add missing ethernet reset ID

PATCH Applied Jerome Brunet 4 participants 6 messages Oct 20, 2020

Subsystems (2)
lore
Share & tools
lore

Jerome Brunet

author reviewer
#0 lore raw

PATCH 1/1 arm64: dts: amlogic: add missing ethernet reset ID

From: Anand Moon <[email protected]>

Add reset external reset of the ethernet mac controller

---
 arch/arm64/boot/dts/amlogic/meson-axg.dtsi        | 2 ++
 arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi | 2 ++
 arch/arm64/boot/dts/amlogic/meson-gx.dtsi         | 3 +++
 3 files changed, 7 insertions(+)
arch/arm64/boot/dts/amlogic/meson-axg.dtsi +2 -0
index fae48efae83e..724ee179b316 100644
@@ -227,6 +227,8 @@ ethmac: ethernet@ff3f0000 {
 				      "timing-adjustment";
 			rx-fifo-depth = <4096>;
 			tx-fifo-depth = <2048>;
+			resets = <&reset RESET_ETHERNET>;
+			reset-names = "stmmaceth";
 			status = "disabled";
 		};
 
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi +2 -0
index c95ebe615176..8514fe6a275a 100644
@@ -224,6 +224,8 @@ ethmac: ethernet@ff3f0000 {
 				      "timing-adjustment";
 			rx-fifo-depth = <4096>;
 			tx-fifo-depth = <2048>;
+			resets = <&reset RESET_ETHERNET>;
+			reset-names = "stmmaceth";
 			status = "disabled";
 
 			mdio0: mdio {
arch/arm64/boot/dts/amlogic/meson-gx.dtsi +3 -0
index 0edd137151f8..726b91d3a905 100644
@@ -13,6 +13,7 @@
 #include <dt-bindings/interrupt-controller/irq.h>
 #include <dt-bindings/interrupt-controller/arm-gic.h>
 #include <dt-bindings/power/meson-gxbb-power.h>
+#include <dt-bindings/reset/amlogic,meson-gxbb-reset.h>
 #include <dt-bindings/thermal/thermal.h>
 
 / {
@@ -575,6 +576,8 @@ ethmac: ethernet@c9410000 {
 			interrupt-names = "macirq";
 			rx-fifo-depth = <4096>;
 			tx-fifo-depth = <2048>;
+			resets = <&reset RESET_ETHERNET>;
+			reset-names = "stmmaceth";
 			power-domains = <&pwrc PWRC_GXBB_ETHERNET_MEM_ID>;
 			status = "disabled";
 		};
Signature · 1 line
2.25.4
Reviewed-by on v1 1/1
#1 lore raw
Quoted 52 lines · Jerome Brunet

From: Anand Moon <[email protected]>

Add reset external reset of the ethernet mac controller

---
 arch/arm64/boot/dts/amlogic/meson-axg.dtsi        | 2 ++
 arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi | 2 ++
 arch/arm64/boot/dts/amlogic/meson-gx.dtsi         | 3 +++
 3 files changed, 7 insertions(+)
arch/arm64/boot/dts/amlogic/meson-axg.dtsi +2 -0
index fae48efae83e..724ee179b316 100644
@@ -227,6 +227,8 @@ ethmac: ethernet@ff3f0000 {
 				      "timing-adjustment";
 			rx-fifo-depth = <4096>;
 			tx-fifo-depth = <2048>;
+			resets = <&reset RESET_ETHERNET>;
+			reset-names = "stmmaceth";
 			status = "disabled";
 		};
 
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi +2 -0
index c95ebe615176..8514fe6a275a 100644
@@ -224,6 +224,8 @@ ethmac: ethernet@ff3f0000 {
 				      "timing-adjustment";
 			rx-fifo-depth = <4096>;
 			tx-fifo-depth = <2048>;
+			resets = <&reset RESET_ETHERNET>;
+			reset-names = "stmmaceth";
 			status = "disabled";
 
 			mdio0: mdio {
arch/arm64/boot/dts/amlogic/meson-gx.dtsi +1 -0
index 0edd137151f8..726b91d3a905 100644
@@ -13,6 +13,7 @@
 #include <dt-bindings/interrupt-controller/irq.h>
 #include <dt-bindings/interrupt-controller/arm-gic.h>
 #include <dt-bindings/power/meson-gxbb-power.h>
+#include <dt-bindings/reset/amlogic,meson-gxbb-reset.h>
 #include <dt-bindings/thermal/thermal.h>
 
 / {

arch/arm64/boot/dts/amlogic/meson-gx.dtsi ethmac: ethernet@c9410000 { · line 583

Quoted 8 lines
arch/arm64/boot/dts/amlogic/meson-gx.dtsi +2 -0
@@ -575,6 +576,8 @@ ethmac: ethernet@c9410000 {
 			interrupt-names = "macirq";
 			rx-fifo-depth = <4096>;
 			tx-fifo-depth = <2048>;
+			resets = <&reset RESET_ETHERNET>;
+			reset-names = "stmmaceth";
 			power-domains = <&pwrc PWRC_GXBB_ETHERNET_MEM_ID>;
 			status = "disabled";
 		};
maintainer
#2 lore raw
Quoted 7 lines · Neil Armstrong
Quoted 6 lines · Jerome Brunet

From: Anand Moon <[email protected]>

Add reset external reset of the ethernet mac controller

[...]

Quoted 1 line

Neil, do we need this in u-boot also? I seem to have network issues in u-boot on board with external PHY running mainline u-boot.

Kevin

#3 lore raw
Quoted 10 lines · Kevin Hilman
Quoted 7 lines · Neil Armstrong
Quoted 6 lines · Jerome Brunet

From: Anand Moon <[email protected]>

Add reset external reset of the ethernet mac controller

Quoted 6 lines

[...]

Quoted 1 line

Neil, do we need this in u-boot also? I seem to have network issues in u-boot on board with external PHY running mainline u-boot.

Yes, U-boot supports it, but simply does "reset_deassert", so I don't think it would have any impact, the real issue is the PHY reset.

Without a proper reset line, no idea how to do that cleanly.

Neil

Quoted 3 lines

Kevin

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

reviewer Reviewed-by on v1 1/1
#4 lore raw
In reply to Jerome Brunet
Quoted 7 lines · Jerome Brunet

From: Anand Moon <[email protected]>

Add reset external reset of the ethernet mac controller

note to self:
we're using the Ethernet reset on Meson8b and Meson8m2 for a long time and I don't remember any problems with it *knocks on wood*

maintainer Applied
#5 lore raw
In reply to Jerome Brunet
Quoted 1 line · Jerome Brunet

Add reset external reset of the ethernet mac controller

Applied, thanks!

[1/1] arm64: dts: amlogic: add missing ethernet reset ID

      commit: f3362f0c18174a1f334a419ab7d567a36bd1b3f3

Best regards,

Signature · 1 line
Kevin Hilman <[email protected]>