]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
MIPS: Loongson64: dts: fix phy-related definition of LS7A GMAC
authorIcenowy Zheng <zhengxingda@iscas.ac.cn>
Fri, 2 Jan 2026 15:52:43 +0000 (23:52 +0800)
committerThomas Bogendoerfer <tsbogend@alpha.franken.de>
Fri, 30 Jan 2026 14:35:26 +0000 (15:35 +0100)
Currently the LS7A GMAC device tree node lacks a proper phy-handle
property pointing to the PHY node.

In addition, the phy-mode property specifies "rgmii" without any
internal delay information, which means the board trace needs to add 2ns
delay to the RGMII data lines; but that isn't known to happen on any
Loongson board. The ACPI-based initialization codepath, which is used on
LoongArch-based 3A5000 + 7A1000 hardwares, specifies "rgmii-id" phy
mode, which should be the one we are using.

Add the lacking phy-handle property and set proper phy-mode.

Tested on a LS3A4000_7A1000_NUC_BOARD_V2.1 board with YT8521S PHY.

Signed-off-by: Icenowy Zheng <zhengxingda@iscas.ac.cn>
Reviewed-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
arch/mips/boot/dts/loongson/ls7a-pch.dtsi

index ee71045883e7e72baa938eb59787e2d7135c2cee..6dee85909f5a617b7c104f771bb2549eee3e0dd0 100644 (file)
                                             <13 IRQ_TYPE_LEVEL_HIGH>;
                                interrupt-names = "macirq", "eth_lpi";
                                interrupt-parent = <&pic>;
-                               phy-mode = "rgmii";
+                               phy-mode = "rgmii-id";
+                               phy-handle = <&phy0>;
                                mdio {
                                        #address-cells = <1>;
                                        #size-cells = <0>;
                                             <15 IRQ_TYPE_LEVEL_HIGH>;
                                interrupt-names = "macirq", "eth_lpi";
                                interrupt-parent = <&pic>;
-                               phy-mode = "rgmii";
+                               phy-mode = "rgmii-id";
+                               phy-handle = <&phy1>;
                                mdio {
                                        #address-cells = <1>;
                                        #size-cells = <0>;