From: Daniel Golle Date: Tue, 23 Apr 2024 11:14:07 +0000 (+0100) Subject: mediatek: correct address of MT753x switch IC X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=8b66f1a;p=openwrt%2Fstaging%2Fdangole.git mediatek: correct address of MT753x switch IC For all boards currently working with the mt7530 DSA driver we can be sure that the address of the switch on the MDIO bus is 31 -- simply because that address is hard-coded in the driver and the address from the Device Tree is being ignore. An upcoming patch will add support for MT753x ICs which are programmed to addresses different from 0x1f using bootstrap pins. As a result the address from the Device Tree will then be taken into account, which will break currently working boards which got the address set to anything else than 31. While at it also unify the syntax in Device Tree to always us a decimal value for the 'reg' property. * mt7622-buffalo-wsr-3200ax4s.dts Cosmetic change 'reg = <0x1f>' -> 'reg = <31>' * mt7622-dlink-eagle-pro-ai-ax3200-a1.dtsi Wrong address: 0 -> 31 * mt7622-elecom-wrc-x3200gst3.dts Wrong address: 0 -> 31 * mt7622-linksys-e8450.dtsi Wrong address: 0 -> 31 * mt7622-ruijie-rg-ew3200.dtsi Wrong address: 0 -> 31 * mt7622-xiaomi-redmi-router-ax6s.dts Wrong address: 0 -> 31 * mt7629-iptime-a6004mx.dts Wrong address: 2 -> 31 * mt7981b-zbtlink-zbt-z8102ax.dts Cosmetic change 'reg = <0x1f>' -> 'reg = <31>' Signed-off-by: Daniel Golle --- diff --git a/target/linux/mediatek/dts/mt7622-buffalo-wsr-3200ax4s.dts b/target/linux/mediatek/dts/mt7622-buffalo-wsr-3200ax4s.dts index 678c31b711..82cc970fdd 100644 --- a/target/linux/mediatek/dts/mt7622-buffalo-wsr-3200ax4s.dts +++ b/target/linux/mediatek/dts/mt7622-buffalo-wsr-3200ax4s.dts @@ -39,7 +39,7 @@ &mdio { switch@1f { compatible = "mediatek,mt7531"; - reg = <0x1f>; + reg = <31>; reset-gpios = <&pio 54 GPIO_ACTIVE_HIGH>; ports { diff --git a/target/linux/mediatek/dts/mt7622-dlink-eagle-pro-ai-ax3200-a1.dtsi b/target/linux/mediatek/dts/mt7622-dlink-eagle-pro-ai-ax3200-a1.dtsi index 10cee7bcef..0560bbd33e 100644 --- a/target/linux/mediatek/dts/mt7622-dlink-eagle-pro-ai-ax3200-a1.dtsi +++ b/target/linux/mediatek/dts/mt7622-dlink-eagle-pro-ai-ax3200-a1.dtsi @@ -76,9 +76,9 @@ #address-cells = <1>; #size-cells = <0>; - switch: switch@0 { + switch: switch@1f { compatible = "mediatek,mt7531"; - reg = <0>; + reg = <31>; interrupt-controller; #interrupt-cells = <1>; interrupt-parent = <&pio>; diff --git a/target/linux/mediatek/dts/mt7622-elecom-wrc-x3200gst3.dts b/target/linux/mediatek/dts/mt7622-elecom-wrc-x3200gst3.dts index f3a688b2d6..2bf4a33a50 100644 --- a/target/linux/mediatek/dts/mt7622-elecom-wrc-x3200gst3.dts +++ b/target/linux/mediatek/dts/mt7622-elecom-wrc-x3200gst3.dts @@ -209,9 +209,9 @@ #address-cells = <1>; #size-cells = <0>; - switch@0 { + switch@1f { compatible = "mediatek,mt7531"; - reg = <0>; + reg = <31>; interrupt-controller; #interrupt-cells = <1>; interrupt-parent = <&pio>; diff --git a/target/linux/mediatek/dts/mt7622-linksys-e8450.dtsi b/target/linux/mediatek/dts/mt7622-linksys-e8450.dtsi index bd686073cb..48b25f7a4a 100644 --- a/target/linux/mediatek/dts/mt7622-linksys-e8450.dtsi +++ b/target/linux/mediatek/dts/mt7622-linksys-e8450.dtsi @@ -138,9 +138,9 @@ #address-cells = <1>; #size-cells = <0>; - switch@0 { + switch@1f { compatible = "mediatek,mt7531"; - reg = <0>; + reg = <31>; interrupt-controller; #interrupt-cells = <1>; interrupt-parent = <&pio>; diff --git a/target/linux/mediatek/dts/mt7622-ruijie-rg-ew3200.dtsi b/target/linux/mediatek/dts/mt7622-ruijie-rg-ew3200.dtsi index a240f9bfce..24ed92788e 100644 --- a/target/linux/mediatek/dts/mt7622-ruijie-rg-ew3200.dtsi +++ b/target/linux/mediatek/dts/mt7622-ruijie-rg-ew3200.dtsi @@ -97,9 +97,9 @@ #address-cells = <1>; #size-cells = <0>; - switch@0 { + switch@1f { compatible = "mediatek,mt7531"; - reg = <0>; + reg = <31>; reset-gpios = <&pio 54 GPIO_ACTIVE_HIGH>; interrupt-controller; #interrupt-cells = <2>; diff --git a/target/linux/mediatek/dts/mt7622-xiaomi-redmi-router-ax6s.dts b/target/linux/mediatek/dts/mt7622-xiaomi-redmi-router-ax6s.dts index c0db31fd3a..ebc8731bc7 100644 --- a/target/linux/mediatek/dts/mt7622-xiaomi-redmi-router-ax6s.dts +++ b/target/linux/mediatek/dts/mt7622-xiaomi-redmi-router-ax6s.dts @@ -164,9 +164,9 @@ #address-cells = <1>; #size-cells = <0>; - switch@0 { + switch@1f { compatible = "mediatek,mt7531"; - reg = <0>; + reg = <31>; interrupt-controller; #interrupt-cells = <1>; interrupt-parent = <&pio>; diff --git a/target/linux/mediatek/dts/mt7629-iptime-a6004mx.dts b/target/linux/mediatek/dts/mt7629-iptime-a6004mx.dts index 78286714ea..7a3fa4deff 100644 --- a/target/linux/mediatek/dts/mt7629-iptime-a6004mx.dts +++ b/target/linux/mediatek/dts/mt7629-iptime-a6004mx.dts @@ -127,9 +127,9 @@ reg = <0>; }; - switch@2 { + switch@1f { compatible = "mediatek,mt7531"; - reg = <2>; + reg = <31>; reset-gpios = <&pio 28 0>; interrupt-controller; #interrupt-cells = <1>; diff --git a/target/linux/mediatek/dts/mt7981b-zbtlink-zbt-z8102ax.dts b/target/linux/mediatek/dts/mt7981b-zbtlink-zbt-z8102ax.dts index de35d15098..f4d5271f97 100644 --- a/target/linux/mediatek/dts/mt7981b-zbtlink-zbt-z8102ax.dts +++ b/target/linux/mediatek/dts/mt7981b-zbtlink-zbt-z8102ax.dts @@ -161,7 +161,7 @@ &mdio_bus { switch: switch@1f { compatible = "mediatek,mt7531"; - reg = <0x1f>; + reg = <31>; reset-gpios = <&pio 39 GPIO_ACTIVE_HIGH>; interrupt-controller; #interrupt-cells = <1>;