1 // SPDX-License-Identifier: GPL-2.0-or-later
4 #include "rtl930x.dtsi"
6 #include <dt-bindings/input/input.h>
7 #include <dt-bindings/gpio/gpio.h>
8 #include <dt-bindings/leds/common.h>
11 compatible = "zyxel,xgs1250-12", "realtek,rtl838x-soc";
12 model = "Zyxel XGS1250-12 Switch";
15 led-boot = &led_pwr_sys;
16 led-failsafe = &led_pwr_sys;
17 led-running = &led_pwr_sys;
18 led-upgrade = &led_pwr_sys;
22 compatible = "gpio-keys";
26 gpios = <&gpio0 22 GPIO_ACTIVE_LOW>;
27 linux,code = <KEY_RESTART>;
31 /* i2c of the SFP cage: port 12 */
32 i2c0: i2c-rtl9300@1b00036c {
33 compatible = "realtek,rtl9300-i2c";
34 reg = <0x1b00036c 0x3c>;
39 clock-frequency = <100000>;
43 compatible = "gpio-leds";
45 pinctrl-names = "default";
46 pinctrl-0 = <&pinmux_disable_sys_led>;
49 color = <LED_COLOR_ID_GREEN>;
50 function = LED_FUNCTION_POWER;
51 gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
56 compatible = "sff,sfp";
58 los-gpio = <&gpio0 17 GPIO_ACTIVE_HIGH>;
59 tx-fault-gpio = <&gpio0 20 GPIO_ACTIVE_HIGH>;
60 mod-def0-gpio = <&gpio0 16 GPIO_ACTIVE_LOW>;
61 tx-disable-gpio = <&gpio0 15 GPIO_ACTIVE_HIGH>;
65 compatible = "realtek,rtl9300-leds";
68 led_set0 = <0x0a20 0x0b80>; // LED set 0: 1000Mbps, 10/100Mbps
69 led_set1 = <0x0a0b 0x0a28 0x0a82 0x0a0b>; // LED set 1: (10G, 5G, 2.5G) (2.5G, 1G)
70 // (5G, 10/100) (10G, 5G, 2.5G)
71 led_set2 = <0x0a20 0x0a01>; // LED set 2: 1000MBit, 10GBit
78 compatible = "jedec,spi-nor";
80 spi-max-frequency = <10000000>;
83 compatible = "fixed-partitions";
94 reg = <0xe0000 0x10000>;
97 label = "u-boot-env2";
98 reg = <0xf0000 0x10000>;
103 reg = <0x100000 0x100000>;
107 reg = <0x200000 0x100000>;
111 reg = <0x300000 0xce0000>;
112 compatible = "openwrt,uimage", "denx,uimage";
113 openwrt,ih-magic = <0x93001250>;
117 reg = <0xfe0000 0x20000>;
125 compatible = "realtek,rtl838x-mdio";
126 regmap = <ðernet0>;
127 #address-cells = <1>;
130 /* External RTL8218D PHY */
131 phy0: ethernet-phy@0 {
133 compatible = "ethernet-phy-ieee802.3-c22";
134 rtl9300,smi-address = <0 0>;
136 // Disabled because we do not know how to bring up again
137 // reset-gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
139 phy1: ethernet-phy@1 {
141 compatible = "ethernet-phy-ieee802.3-c22";
142 rtl9300,smi-address = <0 1>;
144 phy2: ethernet-phy@2 {
146 compatible = "ethernet-phy-ieee802.3-c22";
147 rtl9300,smi-address = <0 2>;
149 phy3: ethernet-phy@3 {
151 compatible = "ethernet-phy-ieee802.3-c22";
152 rtl9300,smi-address = <0 3>;
154 phy4: ethernet-phy@4 {
156 compatible = "ethernet-phy-ieee802.3-c22";
157 rtl9300,smi-address = <0 4>;
159 phy5: ethernet-phy@5 {
161 compatible = "ethernet-phy-ieee802.3-c22";
162 rtl9300,smi-address = <0 5>;
164 phy6: ethernet-phy@6 {
166 compatible = "ethernet-phy-ieee802.3-c22";
167 rtl9300,smi-address = <0 6>;
169 phy7: ethernet-phy@7 {
171 compatible = "ethernet-phy-ieee802.3-c22";
172 rtl9300,smi-address = <0 7>;
175 /* External Aquantia 113C PHYs */
176 phy24: ethernet-phy@24 {
178 compatible = "ethernet-phy-ieee802.3-c45";
179 rtl9300,smi-address = <1 8>;
181 // Disabled because we do not know how to bring up again
182 // reset-gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
185 phy25: ethernet-phy@25 {
187 compatible = "ethernet-phy-ieee802.3-c45";
188 rtl9300,smi-address = <2 8>;
190 // Disabled because we do not know how to bring up again
191 // reset-gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
194 phy26: ethernet-phy@26 {
196 compatible = "ethernet-phy-ieee802.3-c45";
197 rtl9300,smi-address = <3 8>;
199 // Disabled because we do not know how to bring up again
200 // reset-gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
204 phy27: ethernet-phy@27 {
205 compatible = "ethernet-phy-ieee802.3-c22";
208 rtl9300,smi-address = <4 0>;
217 #address-cells = <1>;
223 phy-handle = <&phy0>;
230 phy-handle = <&phy1>;
237 phy-handle = <&phy2>;
244 phy-handle = <&phy3>;
251 phy-handle = <&phy4>;
258 phy-handle = <&phy5>;
265 phy-handle = <&phy6>;
272 phy-handle = <&phy7>;
280 phy-mode = "usxgmii";
281 phy-handle = <&phy24>;
287 phy-mode = "usxgmii";
288 phy-handle = <&phy25>;
294 phy-mode = "usxgmii";
295 phy-handle = <&phy26>;
302 phy-mode = "1000base-x";
303 phy-handle = <&phy27>;
306 managed = "in-band-status";
310 ethernet = <ðernet0>;
312 phy-mode = "internal";