From: Markus Stockhausen Date: Mon, 9 Mar 2026 15:39:11 +0000 (+0100) Subject: realtek: dts: relocate/retype switch node X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=4c92254;p=thirdparty%2Fopenwrt.git realtek: dts: relocate/retype switch node The switch node is currently located outside of the switchcore@1b000000 tree. This makes it hard to find when referencing from other nodes in this tree. Make it a subnode of switchcore and "retype" it to ethernet-switch like upstream does. This is not perfectly aligned as upstream just mixes the switchcore and the ethernet-switch node into one. But this will be future work for downstream. Signed-off-by: Markus Stockhausen Link: https://github.com/openwrt/openwrt/pull/22236 Signed-off-by: Robert Marko --- diff --git a/target/linux/realtek/dts/rtl838x.dtsi b/target/linux/realtek/dts/rtl838x.dtsi index 3ee0b6c45de..911abe7ad0c 100644 --- a/target/linux/realtek/dts/rtl838x.dtsi +++ b/target/linux/realtek/dts/rtl838x.dtsi @@ -274,6 +274,14 @@ compatible = "realtek,rtl8380-thermal"; #thermal-sensor-cells = <0>; }; + + switch0: ethernet-switch { + compatible = "realtek,rtl8380-switch", "realtek,otto-switch"; + status = "okay"; + + interrupt-parent = <&intc>; + interrupts = <20 2>; + }; }; pinmux@1b000144 { @@ -354,13 +362,6 @@ ranges = <0 0x9f000000 0x10000>; }; - switch0: switch@1b000000 { - compatible = "realtek,rtl8380-switch", "realtek,otto-switch"; - - interrupt-parent = <&intc>; - interrupts = <20 2>; - }; - thermal_zones: thermal-zones { cpu-thermal { polling-delay-passive = <1000>; diff --git a/target/linux/realtek/dts/rtl839x.dtsi b/target/linux/realtek/dts/rtl839x.dtsi index 99cca02d39e..216579f2e76 100644 --- a/target/linux/realtek/dts/rtl839x.dtsi +++ b/target/linux/realtek/dts/rtl839x.dtsi @@ -306,6 +306,14 @@ compatible = "realtek,rtl8390-thermal"; #thermal-sensor-cells = <0>; }; + + switch0: ethernet-switch { + compatible = "realtek,rtl8392-switch", "realtek,otto-switch"; + status = "okay"; + + interrupt-parent = <&intc>; + interrupts = <20 2>; + }; }; pinmux@1b000004 { @@ -355,14 +363,6 @@ ranges = <0 0x9f000000 0x18000>; }; - switch0: switch@1b000000 { - status = "okay"; - compatible = "realtek,rtl8392-switch", "realtek,otto-switch"; - - interrupt-parent = <&intc>; - interrupts = <20 2>; - }; - thermal_zones: thermal-zones { cpu-thermal { polling-delay-passive = <1000>; diff --git a/target/linux/realtek/dts/rtl930x.dtsi b/target/linux/realtek/dts/rtl930x.dtsi index 11fea099634..db28fa566a6 100644 --- a/target/linux/realtek/dts/rtl930x.dtsi +++ b/target/linux/realtek/dts/rtl930x.dtsi @@ -289,6 +289,14 @@ compatible = "realtek,rtl9300-thermal"; #thermal-sensor-cells = <0>; }; + + switch0: switch@1b000000 { + compatible = "realtek,rtl9301-switch", "realtek,otto-switch"; + status = "okay"; + + interrupt-parent = <&intc>; + interrupts = <23 2>; + }; }; pinmux@1b000200 { @@ -358,14 +366,6 @@ }; }; - switch0: switch@1b000000 { - compatible = "realtek,rtl9301-switch", "realtek,otto-switch"; - status = "okay"; - - interrupt-parent = <&intc>; - interrupts = <23 2>; - }; - thermal_zones: thermal-zones { cpu-thermal { polling-delay-passive = <1000>; diff --git a/target/linux/realtek/dts/rtl931x.dtsi b/target/linux/realtek/dts/rtl931x.dtsi index ddb95eb99db..3ea1ce297fd 100644 --- a/target/linux/realtek/dts/rtl931x.dtsi +++ b/target/linux/realtek/dts/rtl931x.dtsi @@ -325,6 +325,15 @@ reg = <13>; }; }; + + switch0: switch@1b000000 { + compatible = "realtek,rtl9311-switch", "realtek,otto-switch"; + status = "okay"; + + interrupt-parent = <&gic>; + #interrupt-cells = <3>; + interrupts = ; + }; }; pinmux@1b00103c { @@ -419,13 +428,4 @@ pinctrl-single,bits = <0x0 0x100 0x100>; }; }; - - switch0: switch@1b000000 { - compatible = "realtek,rtl9311-switch", "realtek,otto-switch"; - status = "okay"; - - interrupt-parent = <&gic>; - #interrupt-cells = <3>; - interrupts = ; - }; };