arm: dts: k3-am6: Fix Ethernet/DMA
v2 cover arm: dts: k3-am6: Fix Ethernet/DMA
Hi,
Since commit [1], Ethernet is broken on TI AM62 and AM64 platforms.
The commit [1] is not the culprit. It just unearths the problem by fixing the error check in k3-udma.c. This issue was silently being ignored earlier due to wrong error check. [NULL instead of FDT_ADDR_T_NONE].
Fix the issue by adding the necessary register spaces for the u-boot K3-UDMA driver for AM62 and AM64 platforms.
These properties will eventually make it into the SoC DTSi files [2] after which these can be dropped from k3-*-u-boot.dtsi files.
[1] - 5fecea171de3dd ("treewide: use dev_read_addr_*_ptr() where appropriate")
[2] - https://lore.kernel.org/linux-arm-kernel/[email protected]/
cheers,
-roger
Changelog:
v2:
- move 'bootph-all' to the end of the nodes
- add changes to existing main_bcdma and main_pktdma nodes
- drop duplicate main_pktdma node in k3-am642-sk-u-boot.dtsi
- Add Tested-by and Reviewed-by tags
Roger Quadros (1):
arm: dts: k3-am625-verdin-wifi-dev-u-boot.dtsi: Fix DMA/Ethernet
Siddharth Vadapalli (2):
arm: dts: k3-am625-sk-u-boot.dtsi: Update main_bcdma and main_pktdma
nodes
arm: dts: k3-am642: Update main_bcdma and main_pktdma nodes
arch/arm/dts/k3-am625-sk-u-boot.dtsi | 23 ++++++++++++++++ .../dts/k3-am625-verdin-wifi-dev-u-boot.dtsi | 27 +++++++++++++++++++ arch/arm/dts/k3-am642-evm-u-boot.dtsi | 23 ++++++++++++++++ arch/arm/dts/k3-am642-sk-u-boot.dtsi | 24 ++++++++++++++--- 4 files changed, 93 insertions(+), 4 deletions(-)
base-commit: 4bb6f61220f7f4c79ccf98f4281733e6ea6c50f0
prerequisite-patch-id: 3125319138da332af1e7650e3ae0d78dab0ff312
Signature · 1 line
2.34.1
PATCH v2 1/3 arm: dts: k3-am625-sk-u-boot.dtsi: Update main_bcdma and main_pktdma nodes
From: Siddharth Vadapalli <[email protected]>
Update main_bcdma and main_pktdma nodes for native configuration in the absence of DM services.
--- arch/arm/dts/k3-am625-sk-u-boot.dtsi | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+)
arch/arm/dts/k3-am625-sk-u-boot.dtsi +23 -0
@@ -126,7 +126,30 @@ bootph-all; }; +&main_bcdma { + reg = <0x00 0x485c0100 0x00 0x100>, + <0x00 0x4c000000 0x00 0x20000>, + <0x00 0x4a820000 0x00 0x20000>, + <0x00 0x4aa40000 0x00 0x20000>, + <0x00 0x4bc00000 0x00 0x100000>, + <0x00 0x48600000 0x00 0x8000>, + <0x00 0x484a4000 0x00 0x2000>, + <0x00 0x484c2000 0x00 0x2000>; + reg-names = "gcfg", "bchanrt", "rchanrt", "tchanrt", + "ringrt" , "cfg", "tchan", "rchan"; +}; + &main_pktdma { + reg = <0x00 0x485c0000 0x00 0x100>, + <0x00 0x4a800000 0x00 0x20000>, + <0x00 0x4aa00000 0x00 0x20000>, + <0x00 0x4b800000 0x00 0x200000>, + <0x00 0x485e0000 0x00 0x10000>, + <0x00 0x484a0000 0x00 0x2000>, + <0x00 0x484c0000 0x00 0x2000>, + <0x00 0x48430000 0x00 0x1000>; + reg-names = "gcfg", "rchanrt", "tchanrt", "ringrt", + "cfg", "tchan", "rchan", "rflow"; bootph-all; };
Signature · 1 line
2.34.1
PATCH v2 2/3 arm: dts: k3-am625-verdin-wifi-dev-u-boot.dtsi: Fix DMA/Ethernet
In reply to Roger QuadrosUpdate main_bcdma and main_pktdma nodes for native configuration in the absence of DM services. u-boot k3-udma driver expects these additional register fields else probe will fail.
--- .../dts/k3-am625-verdin-wifi-dev-u-boot.dtsi | 27 +++++++++++++++++++ 1 file changed, 27 insertions(+)
arch/arm/dts/k3-am625-verdin-wifi-dev-u-boot.dtsi +27 -0
@@ -42,6 +42,33 @@ bootph-all; }; +&main_bcdma { + reg = <0x00 0x485c0100 0x00 0x100>, + <0x00 0x4c000000 0x00 0x20000>, + <0x00 0x4a820000 0x00 0x20000>, + <0x00 0x4aa40000 0x00 0x20000>, + <0x00 0x4bc00000 0x00 0x100000>, + <0x00 0x48600000 0x00 0x8000>, + <0x00 0x484a4000 0x00 0x2000>, + <0x00 0x484c2000 0x00 0x2000>; + reg-names = "gcfg", "bchanrt", "rchanrt", "tchanrt", + "ringrt" , "cfg", "tchan", "rchan"; +}; + +&main_pktdma { + reg = <0x00 0x485c0000 0x00 0x100>, + <0x00 0x4a800000 0x00 0x20000>, + <0x00 0x4aa00000 0x00 0x20000>, + <0x00 0x4b800000 0x00 0x200000>, + <0x00 0x485e0000 0x00 0x10000>, + <0x00 0x484a0000 0x00 0x2000>, + <0x00 0x484c0000 0x00 0x2000>, + <0x00 0x48430000 0x00 0x1000>; + reg-names = "gcfg", "rchanrt", "tchanrt", "ringrt", + "cfg", "tchan", "rchan", "rflow"; + bootph-all; +}; + &cpsw3g { bootph-all; };
Signature · 1 line
2.34.1
PATCH v2 3/3 arm: dts: k3-am642: Update main_bcdma and main_pktdma nodes
In reply to Roger QuadrosFrom: Siddharth Vadapalli <[email protected]>
Update main_bcdma and main_pktdma nodes for native configuration in the absence of DM services.
Drop duplicate main_pktdma node in k3-am642-sk-u-boot.dtsi.
--- arch/arm/dts/k3-am642-evm-u-boot.dtsi | 23 +++++++++++++++++++++++ arch/arm/dts/k3-am642-sk-u-boot.dtsi | 24 ++++++++++++++++++++---- 2 files changed, 43 insertions(+), 4 deletions(-)
arch/arm/dts/k3-am642-evm-u-boot.dtsi +23 -0
@@ -116,7 +116,30 @@ bootph-all; }; +&main_bcdma { + reg = <0x00 0x485c0100 0x00 0x100>, + <0x00 0x4c000000 0x00 0x20000>, + <0x00 0x4a820000 0x00 0x20000>, + <0x00 0x4aa40000 0x00 0x20000>, + <0x00 0x4bc00000 0x00 0x100000>, + <0x00 0x48600000 0x00 0x8000>, + <0x00 0x484a4000 0x00 0x2000>, + <0x00 0x484c2000 0x00 0x2000>; + reg-names = "gcfg", "bchanrt", "rchanrt", "tchanrt", "ringrt", + "cfg", "tchan", "rchan"; +}; + &main_pktdma { + reg = <0x00 0x485c0000 0x00 0x100>, + <0x00 0x4a800000 0x00 0x20000>, + <0x00 0x4aa00000 0x00 0x40000>, + <0x00 0x4b800000 0x00 0x400000>, + <0x00 0x485e0000 0x00 0x20000>, + <0x00 0x484a0000 0x00 0x4000>, + <0x00 0x484c0000 0x00 0x2000>, + <0x00 0x48430000 0x00 0x4000>; + reg-names = "gcfg", "rchanrt", "tchanrt", "ringrt", "cfg", + "tchan", "rchan", "rflow"; bootph-all; };
arch/arm/dts/k3-am642-sk-u-boot.dtsi +20 -4
@@ -96,10 +96,6 @@ bootph-all; }; -&main_pktdma { - bootph-all; -}; - &mdio1_pins_default { bootph-all; };
@@ -141,10 +137,30 @@ }; &main_bcdma { + reg = <0x00 0x485c0100 0x00 0x100>, + <0x00 0x4c000000 0x00 0x20000>, + <0x00 0x4a820000 0x00 0x20000>, + <0x00 0x4aa40000 0x00 0x20000>, + <0x00 0x4bc00000 0x00 0x100000>, + <0x00 0x48600000 0x00 0x8000>, + <0x00 0x484a4000 0x00 0x2000>, + <0x00 0x484c2000 0x00 0x2000>; + reg-names = "gcfg", "bchanrt", "rchanrt", "tchanrt", "ringrt", + "cfg", "tchan", "rchan"; bootph-all; }; &main_pktdma { + reg = <0x00 0x485c0000 0x00 0x100>, + <0x00 0x4a800000 0x00 0x20000>, + <0x00 0x4aa00000 0x00 0x40000>, + <0x00 0x4b800000 0x00 0x400000>, + <0x00 0x485e0000 0x00 0x20000>, + <0x00 0x484a0000 0x00 0x4000>, + <0x00 0x484c0000 0x00 0x2000>, + <0x00 0x48430000 0x00 0x4000>; + reg-names = "gcfg", "rchanrt", "tchanrt", "ringrt", "cfg", + "tchan", "rchan", "rflow"; bootph-all; };
Signature · 1 line
2.34.1
Quoted 10 lines · Roger Quadros
Since commit [1], Ethernet is broken on TI AM62 and AM64 platforms.
The commit [1] is not the culprit. It just unearths the problem by fixing the error check in
k3-udma.c. This issue was silently being ignored earlier due to wrong error check. [NULL instead ofFDT_ADDR_T_NONE].Fix the issue by adding the necessary register spaces for the u-boot K3-UDMA driver for AM62 and AM64 platforms.
[...]
Applied to u-boot/master, thanks!
Signature · 1 line
Tom