c0c3500af25ad98a9ec76113952f44a02879f993
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7621_netgear_wax202.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "mt7621.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "netgear,wax202", "mediatek,mt7621-soc";
10 model = "Netgear WAX202";
11
12 aliases {
13 led-boot = &led_power_green;
14 led-failsafe = &led_power_orange;
15 led-running = &led_power_green;
16 led-upgrade = &led_power_orange;
17 };
18
19 chosen {
20 bootargs = "console=ttyS0,115200";
21 };
22
23 keys {
24 compatible = "gpio-keys";
25
26 reset {
27 label = "reset";
28 gpios = <&gpio 10 GPIO_ACTIVE_LOW>;
29 linux,code = <KEY_RESTART>;
30 };
31 };
32
33 leds {
34 compatible = "gpio-leds";
35
36 led_power_green: power_green {
37 label = "green:power";
38 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
39 };
40
41 led_power_orange: power_orange {
42 label = "orange:power";
43 gpios = <&gpio 17 GPIO_ACTIVE_HIGH>;
44 };
45
46 led_net_green: net_green {
47 label = "green:net";
48 gpios = <&gpio 18 GPIO_ACTIVE_LOW>;
49 };
50
51 led_net_blue: net_blue {
52 label = "blue:net";
53 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
54 };
55
56 led_lan1_orange: lan1_orange {
57 label = "orange:lan1";
58 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
59 };
60
61 led_lan2_orange: lan2_orange {
62 label = "orange:lan2";
63 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
64 };
65
66 led_lan3_orange: lan3_orange {
67 label = "orange:lan3";
68 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
69 };
70
71 led_wifi2g_green: wifi2g_green {
72 label = "green:wifi2g";
73 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
74 linux,default-trigger = "phy0radio";
75 };
76
77 led_wifi2g_blue: wifi2g_blue {
78 label = "blue:wifi2g";
79 gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
80 };
81
82 led_wifi5g_green: wifi5g_green {
83 label = "green:wifi5g";
84 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
85 linux,default-trigger = "phy1radio";
86 };
87
88 led_wifi5g_blue: wifi5g_blue {
89 label = "blue:wifi5g";
90 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
91 };
92 };
93 };
94
95 &nand {
96 status = "okay";
97
98 partitions {
99 compatible = "fixed-partitions";
100 #address-cells = <1>;
101 #size-cells = <1>;
102
103 partition@0 {
104 label = "Bootloader";
105 reg = <0x0 0x80000>;
106 read-only;
107 };
108
109 partition@80000 {
110 label = "Config";
111 reg = <0x80000 0x80000>;
112 read-only;
113 };
114
115 factory: partition@100000 {
116 label = "Factory";
117 reg = <0x100000 0x80000>;
118 read-only;
119
120 nvmem-layout {
121 compatible = "fixed-layout";
122 #address-cells = <1>;
123 #size-cells = <1>;
124
125 eeprom_factory_0: eeprom@0 {
126 reg = <0x0 0xe00>;
127 };
128 };
129 };
130
131 partition@180000 {
132 label = "firmware";
133 reg = <0x180000 0x2600000>;
134
135 compatible = "fixed-partitions";
136 #address-cells = <1>;
137 #size-cells = <1>;
138
139 partition@0 {
140 label = "kernel";
141 reg = <0x0 0x400000>;
142 };
143
144 partition@400000 {
145 label = "ubi";
146 reg = <0x400000 0x2200000>;
147 };
148 };
149
150 partition@2780000 {
151 label = "firmware_backup";
152 reg = <0x2780000 0x2600000>;
153 read-only;
154 };
155
156 partition@4d80000 {
157 label = "CFG";
158 reg = <0x4d80000 0x800000>;
159 read-only;
160 };
161
162 partition@5580000 {
163 label = "RAE";
164 reg = <0x5580000 0x400000>;
165 read-only;
166 };
167
168 partition@5980000 {
169 label = "POT";
170 reg = <0x5980000 0x100000>;
171 read-only;
172 };
173
174 partition@5a80000 {
175 label = "Language";
176 reg = <0x5a80000 0x400000>;
177 read-only;
178 };
179
180 partition@5e80000 {
181 label = "Traffic";
182 reg = <0x5e80000 0x200000>;
183 read-only;
184 };
185
186 partition@6080000 {
187 label = "Cert";
188 reg = <0x6080000 0x100000>;
189 read-only;
190 };
191
192 partition@6180000 {
193 label = "NTGRcryptK";
194 reg = <0x6180000 0x100000>;
195 read-only;
196 };
197
198 partition@6280000 {
199 label = "NTGRcryptD";
200 reg = <0x6280000 0x500000>;
201 read-only;
202 };
203
204 partition@6780000 {
205 label = "LOG";
206 reg = <0x6780000 0x100000>;
207 read-only;
208 };
209
210 partition@6880000 {
211 label = "User_data";
212 reg = <0x6880000 0x640000>;
213 read-only;
214 };
215 };
216 };
217
218 &pcie {
219 status = "okay";
220 };
221
222 &pcie1 {
223 wifi@0,0 {
224 compatible = "mediatek,mt76";
225 reg = <0x0000 0 0 0 0>;
226 nvmem-cells = <&eeprom_factory_0>;
227 nvmem-cell-names = "eeprom";
228 };
229 };
230
231 &state_default {
232 gpio {
233 groups = "uart3", "uart2", "jtag", "wdt";
234 function = "gpio";
235 };
236 };
237
238 &gmac1 {
239 status = "okay";
240 label = "wan";
241 phy-handle = <&ethphy0>;
242 };
243
244 &mdio {
245 ethphy0: ethernet-phy@0 {
246 reg = <0>;
247 };
248 };
249
250 &switch0 {
251 ports {
252 port@1 {
253 status = "okay";
254 label = "lan1";
255 };
256
257 port@2 {
258 status = "okay";
259 label = "lan2";
260 };
261
262 /* port@3 is not used */
263
264 port@4 {
265 status = "okay";
266 label = "lan3";
267 };
268 };
269 };
270
271 &xhci {
272 status = "disabled";
273 };