1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
5 #define STRINGIZE(s) #s
6 #define LAN_LABEL(p, s) STRINGIZE(p ## s)
7 #define SWITCH_PORT_LABEL(n) LAN_LABEL(lan, n)
9 #define INTERNAL_PHY(n) \
10 phy##n: ethernet-phy@##n { \
12 compatible = "ethernet-phy-ieee802.3-c22"; \
16 #define EXTERNAL_PHY(n) \
17 phy##n: ethernet-phy@##n { \
19 compatible = "ethernet-phy-ieee802.3-c22"; \
22 #define EXTERNAL_SFP_PHY(n) \
23 phy##n: ethernet-phy@##n { \
24 compatible = "ethernet-phy-ieee802.3-c22"; \
30 #define EXTERNAL_SFP_PHY_FULL(n, s) \
31 phy##n: ethernet-phy@##n { \
32 compatible = "ethernet-phy-ieee802.3-c22"; \
37 #define SWITCH_PORT(n, s, m) \
40 label = SWITCH_PORT_LABEL(s) ; \
41 phy-handle = <&phy##n>; \
45 #define SWITCH_SFP_PORT(n, s, m) \
48 label = SWITCH_PORT_LABEL(s) ; \
49 phy-handle = <&phy##n>; \
61 compatible = "realtek,rtl838x-soc";
66 frequency = <500000000>;
69 compatible = "mips,mips4KEc";
75 bootargs = "console=ttyS0,115200";
79 compatible = "fixed-clock";
81 clock-frequency = <200000000>;
85 compatible = "mti,cpu-interrupt-controller";
87 #interrupt-cells = <1>;
92 compatible = "simple-bus";
95 ranges = <0x0 0x18000000 0x10000>;
97 intc: interrupt-controller@3000 {
98 compatible = "realtek,rtl8380-intc", "realtek,rtl-intc";
100 interrupt-controller;
101 #interrupt-cells = <2>;
103 interrupt-parent = <&cpuintc>;
104 interrupts = <2>, <3>, <4>, <5>, <6>;
108 compatible = "realtek,rtl8380-spi";
109 reg = <0x1200 0x100>;
111 #address-cells = <1>;
116 compatible = "ns16550a";
117 reg = <0x2000 0x100>;
121 interrupt-parent = <&intc>;
131 pinctrl-names = "default";
132 pinctrl-0 = <&enable_uart1>;
134 compatible = "ns16550a";
135 reg = <0x2100 0x100>;
139 interrupt-parent = <&intc>;
150 watchdog0: watchdog@3150 {
151 compatible = "realtek,rtl8380-wdt";
154 realtek,reset-mode = "soc";
159 interrupt-parent = <&intc>;
160 interrupt-names = "phase1", "phase2";
161 interrupts = <19 3>, <18 4>;
164 gpio0: gpio-controller@3500 {
165 compatible = "realtek,rtl8380-gpio", "realtek,otto-gpio";
172 interrupt-controller;
173 #interrupt-cells = <2>;
174 interrupt-parent = <&intc>;
179 pinmux: pinmux@1b001000 {
180 compatible = "pinctrl-single";
181 reg = <0x1b001000 0x4>;
183 pinctrl-single,bit-per-mux;
184 pinctrl-single,register-width = <32>;
185 pinctrl-single,function-mask = <0x1>;
186 #pinctrl-cells = <2>;
188 enable_uart1: pinmux_enable_uart1 {
189 pinctrl-single,bits = <0x0 0x10 0x10>;
194 pinmux_led: pinmux@1b00a000 {
195 compatible = "pinctrl-single";
196 reg = <0x1b00a000 0x4>;
198 pinctrl-single,bit-per-mux;
199 pinctrl-single,register-width = <32>;
200 pinctrl-single,function-mask = <0x1>;
201 #pinctrl-cells = <2>;
204 pinmux_disable_sys_led: disable_sys_led {
205 pinctrl-single,bits = <0x0 0x0 0x8000>;
209 ethernet0: ethernet@1b00a300 {
210 compatible = "realtek,rtl838x-eth";
211 reg = <0x1b00a300 0x100>;
212 interrupt-parent = <&intc>;
214 #interrupt-cells = <1>;
215 phy-mode = "internal";
223 switch0: switch@1b000000 {
224 compatible = "realtek,rtl83xx-switch";
226 interrupt-parent = <&intc>;