From: Shiji Yang Date: Sat, 3 Jan 2026 04:59:19 +0000 (+0800) Subject: mediatek: dts: mt7981: remove internal phy LED pinctrl X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3462789923189489630729300544ead4c584c0c4;p=thirdparty%2Fopenwrt.git mediatek: dts: mt7981: remove internal phy LED pinctrl This default pinctrl doesn't work at all. We must add pinctrl phandle to the ethernet-phy node or mac node. This patch removed the internal phy LED pinctrl group definitions from the SOC dtsi because it is currently only used by one device. Some incorrect LED pinctrls also have been removed because these devices do not have hardware phy LED. Signed-off-by: Shiji Yang Link: https://github.com/openwrt/openwrt/pull/21108 Signed-off-by: Hauke Mehrtens --- diff --git a/target/linux/mediatek/dts/mt7981a-teltonika-rutc50.dts b/target/linux/mediatek/dts/mt7981a-teltonika-rutc50.dts index d922b0ad1f2..dd6f6aa5e6d 100644 --- a/target/linux/mediatek/dts/mt7981a-teltonika-rutc50.dts +++ b/target/linux/mediatek/dts/mt7981a-teltonika-rutc50.dts @@ -173,8 +173,6 @@ }; ð { - pinctrl-names = "default"; - pinctrl-0 = <&gbe_led0_pins>, <&gbe_led1_pins>; status = "okay"; gmac0: mac@0 { @@ -202,6 +200,11 @@ }; }; +&int_gbe_phy { + pinctrl-names = "default"; + pinctrl-0 = <&gbe_led0_pins>, <&gbe_led1_pins>; +}; + &int_gbe_phy_led0{ function = LED_FUNCTION_WAN; color = ; @@ -447,6 +450,20 @@ }; &pio { + gbe_led0_pins: gbe-led0-pins { + mux { + function = "led"; + groups = "gbe_led0"; + }; + }; + + gbe_led1_pins: gbe-led1-pins { + mux { + function = "led"; + groups = "gbe_led1"; + }; + }; + spi0_flash_pins: spi0-pins { mux { function = "spi"; diff --git a/target/linux/mediatek/dts/mt7981b-iptime-ax3000m.dts b/target/linux/mediatek/dts/mt7981b-iptime-ax3000m.dts index 83c833d6d46..6025135a33d 100644 --- a/target/linux/mediatek/dts/mt7981b-iptime-ax3000m.dts +++ b/target/linux/mediatek/dts/mt7981b-iptime-ax3000m.dts @@ -94,7 +94,7 @@ ð { pinctrl-names = "default"; - pinctrl-0 = <&mdio_pins &gbe_led0_pins>; + pinctrl-0 = <&mdio_pins>; status = "okay"; diff --git a/target/linux/mediatek/dts/mt7981b-totolink-x6000r.dts b/target/linux/mediatek/dts/mt7981b-totolink-x6000r.dts index ab110d57fca..56b165857dc 100644 --- a/target/linux/mediatek/dts/mt7981b-totolink-x6000r.dts +++ b/target/linux/mediatek/dts/mt7981b-totolink-x6000r.dts @@ -74,7 +74,7 @@ ð { pinctrl-names = "default"; - pinctrl-0 = <&mdio_pins &gbe_led0_pins &gbe_led1_pins>; + pinctrl-0 = <&mdio_pins>; status = "okay"; gmac0: mac@0 { diff --git a/target/linux/mediatek/dts/mt7981b-unielec-u7981-01.dtsi b/target/linux/mediatek/dts/mt7981b-unielec-u7981-01.dtsi index b9f0bcd7e65..7751e2f9773 100644 --- a/target/linux/mediatek/dts/mt7981b-unielec-u7981-01.dtsi +++ b/target/linux/mediatek/dts/mt7981b-unielec-u7981-01.dtsi @@ -33,7 +33,7 @@ ð { pinctrl-names = "default"; - pinctrl-0 = <&mdio_pins &gbe_led0_pins &gbe_led1_pins>; + pinctrl-0 = <&mdio_pins>; status = "okay"; gmac0: mac@0 { diff --git a/target/linux/mediatek/patches-6.12/117-complete-mt7981b-dtsi.patch b/target/linux/mediatek/patches-6.12/117-complete-mt7981b-dtsi.patch index f68b0d83c9b..a877cdca40e 100644 --- a/target/linux/mediatek/patches-6.12/117-complete-mt7981b-dtsi.patch +++ b/target/linux/mediatek/patches-6.12/117-complete-mt7981b-dtsi.patch @@ -254,7 +254,7 @@ working: pio: pinctrl@11d00000 { compatible = "mediatek,mt7981-pinctrl"; reg = <0 0x11d00000 0 0x1000>, -@@ -204,6 +337,49 @@ +@@ -204,6 +337,35 @@ gpio-controller; #gpio-cells = <2>; #interrupt-cells = <2>; @@ -286,25 +286,11 @@ working: + "WF_CBA_RESETB", "WF_DIG_RESETB"; + drive-strength = ; + }; -+ }; -+ -+ gbe_led0_pins: gbe-led0-pins { -+ mux { -+ function = "led"; -+ groups = "gbe_led0"; -+ }; -+ }; -+ -+ gbe_led1_pins: gbe-led1-pins { -+ mux { -+ function = "led"; -+ groups = "gbe_led1"; -+ }; + }; }; efuse@11f20000 { -@@ -211,17 +387,301 @@ +@@ -211,17 +373,297 @@ reg = <0 0x11f20000 0 0x1000>; #address-cells = <1>; #size-cells = <1>; @@ -417,16 +403,12 @@ working: + int_gbe_phy_led0: int-gbe-phy-led0@0 { + reg = <0>; + function = LED_FUNCTION_LAN; -+ pinctrl-0 = <&gbe_led0_pins>; -+ pinctrl-names = "default"; + status = "disabled"; + }; + + int_gbe_phy_led1: int-gbe-phy-led1@1 { + reg = <1>; + function = LED_FUNCTION_LAN; -+ pinctrl-0 = <&gbe_led1_pins>; -+ pinctrl-names = "default"; + status = "disabled"; + }; + }; @@ -608,7 +590,7 @@ working: reg = <0 0x18000000 0 0x1000000>, <0 0x10003000 0 0x1000>, <0 0x11d10000 0 0x1000>; -@@ -234,6 +694,67 @@ +@@ -234,6 +676,67 @@ clock-names = "mcu", "ap2conn"; resets = <&watchdog MT7986_TOPRGU_CONSYS_SW_RST>; reset-names = "consys"; @@ -676,7 +658,7 @@ working: }; }; -@@ -245,4 +766,8 @@ +@@ -245,4 +748,8 @@ , ; };