476c6bab408b002509fbdc0256c01458a594da9c
[openwrt/openwrt.git] / target / linux / ipq806x / files-5.4 / arch / arm / boot / dts / qcom-ipq8064-wxr-2533dhp.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2 #include "qcom-ipq8064-v2.0.dtsi"
3
4 #include <dt-bindings/input/input.h>
5
6 / {
7 model = "Buffalo WXR-2533DHP";
8 compatible = "buffalo,wxr-2533dhp", "qcom,ipq8064";
9
10 memory@42000000 {
11 reg = <0x42000000 0x1e000000>;
12 device_type = "memory";
13 };
14
15 aliases {
16 led-boot = &power;
17 led-failsafe = &diag;
18 led-running = &power;
19 led-upgrade = &power;
20 };
21
22 chosen {
23 /* use "ubi_rootfs" volume in "ubi" partition as rootfs */
24 bootargs = "ubi.block=0,1 root=/dev/ubiblock0_1 rootfstype=squashfs";
25 };
26
27 leds {
28 compatible = "gpio-leds";
29 pinctrl-0 = <&led_pins>;
30 pinctrl-names = "default";
31
32 usb {
33 label = "wxr-2533dhp:green:usb";
34 gpios = <&qcom_pinmux 7 GPIO_ACTIVE_HIGH>;
35 linux,default-trigger = "usbport";
36 trigger-sources = <&hub_port0 &hub_port1>;
37 };
38
39 guestport {
40 label = "wxr-2533dhp:green:guestport";
41 gpios = <&qcom_pinmux 8 GPIO_ACTIVE_HIGH>;
42 };
43
44 diag: diag {
45 label = "wxr-2533dhp:orange:diag";
46 gpios = <&qcom_pinmux 9 GPIO_ACTIVE_HIGH>;
47 };
48
49 internet_orange {
50 label = "wxr-2533dhp:orange:internet";
51 gpios = <&qcom_pinmux 16 GPIO_ACTIVE_HIGH>;
52 };
53
54 internet_white {
55 label = "wxr-2533dhp:white:internet";
56 gpios = <&qcom_pinmux 22 GPIO_ACTIVE_HIGH>;
57 };
58
59 wireless_orange {
60 label = "wxr-2533dhp:orange:wireless";
61 gpios = <&qcom_pinmux 23 GPIO_ACTIVE_HIGH>;
62 };
63
64 wireless_white {
65 label = "wxr-2533dhp:white:wireless";
66 gpios = <&qcom_pinmux 24 GPIO_ACTIVE_HIGH>;
67 };
68
69 router_orange {
70 label = "wxr-2533dhp:orange:router";
71 gpios = <&qcom_pinmux 25 GPIO_ACTIVE_HIGH>;
72 };
73
74 router_white {
75 label = "wxr-2533dhp:white:router";
76 gpios = <&qcom_pinmux 26 GPIO_ACTIVE_LOW>;
77 };
78
79 power: power {
80 label = "wxr-2533dhp:white:power";
81 gpios = <&qcom_pinmux 53 GPIO_ACTIVE_HIGH>;
82 };
83 };
84
85 keys {
86 compatible = "gpio-keys";
87 pinctrl-0 = <&button_pins>;
88 pinctrl-names = "default";
89
90 power {
91 label = "power";
92 gpios = <&qcom_pinmux 58 GPIO_ACTIVE_LOW>;
93 linux,code = <KEY_POWER>;
94 };
95
96 reset {
97 label = "reset";
98 gpios = <&qcom_pinmux 54 GPIO_ACTIVE_LOW>;
99 linux,code = <KEY_RESTART>;
100 };
101
102 wps {
103 label = "wps";
104 gpios = <&qcom_pinmux 65 GPIO_ACTIVE_LOW>;
105 linux,code = <KEY_WPS_BUTTON>;
106 };
107
108 eject {
109 label = "eject";
110 gpios = <&qcom_pinmux 6 GPIO_ACTIVE_LOW>;
111 linux,code = <KEY_EJECTCD>;
112 };
113
114 guest {
115 label = "guest";
116 gpios = <&qcom_pinmux 64 GPIO_ACTIVE_LOW>;
117 linux,code = <BTN_0>;
118 };
119
120 ap {
121 label = "ap";
122 gpios = <&qcom_pinmux 55 GPIO_ACTIVE_LOW>;
123 linux,code = <BTN_1>;
124 linux,input-type = <EV_SW>;
125 };
126
127 router {
128 label = "router";
129 gpios = <&qcom_pinmux 56 GPIO_ACTIVE_LOW>;
130 linux,code = <BTN_1>;
131 linux,input-type = <EV_SW>;
132 };
133
134 auto {
135 label = "auto";
136 gpios = <&qcom_pinmux 57 GPIO_ACTIVE_LOW>;
137 linux,code = <BTN_1>;
138 linux,input-type = <EV_SW>;
139 };
140 };
141 };
142
143 &nand_controller {
144 status = "okay";
145
146 pinctrl-0 = <&nand_pins>;
147 pinctrl-names = "default";
148
149 cs@0 {
150 reg = <0>;
151 compatible = "qcom,nandcs";
152
153 nand-ecc-strength = <4>;
154 nand-bus-width = <8>;
155 nand-ecc-step-size = <512>;
156
157 partitions {
158 compatible = "fixed-partitions";
159 #address-cells = <1>;
160 #size-cells = <1>;
161
162 ubi@0 {
163 label = "ubi";
164 reg = <0x0000000 0x4000000>;
165 };
166
167 rootfs_1@4000000 {
168 label = "rootfs_1";
169 reg = <0x4000000 0x4000000>;
170 };
171 };
172 };
173 };
174
175 &adm_dma {
176 status = "okay";
177 };
178
179 &mdio0 {
180 status = "okay";
181
182 pinctrl-0 = <&mdio0_pins>;
183 pinctrl-names = "default";
184
185 ethernet-phy@0 {
186 reg = <0>;
187 qca,ar8327-initvals = <
188 0x00004 0x07600000 /* PAD0_MODE */
189 0x00008 0x01000000 /* PAD5_MODE */
190 0x0000c 0x00000080 /* PAD6_MODE */
191 0x00050 0xcc35cc35 /* LED_CTRL0 */
192 0x00054 0xca35ca35 /* LED_CTRL1 */
193 0x00058 0xc935c935 /* LED_CTRL2 */
194 0x0005c 0x03ffff00 /* LED_CTRL3 */
195 0x000e4 0x0006a545 /* MAC_POWER_SEL */
196 0x000e0 0xc74164de /* SGMII_CTRL */
197 0x0007c 0x0000007e /* PORT0_STATUS */
198 0x00094 0x0000007e /* PORT6_STATUS */
199 >;
200 };
201
202 ethernet-phy@4 {
203 reg = <4>;
204 };
205 };
206
207 &gmac1 {
208 status = "okay";
209
210 phy-mode = "rgmii";
211 qcom,id = <1>;
212
213 pinctrl-0 = <&rgmii2_pins>;
214 pinctrl-names = "default";
215
216 mtd-mac-address = <&ART 6>;
217
218 fixed-link {
219 speed = <1000>;
220 full-duplex;
221 };
222 };
223
224 &gmac2 {
225 status = "okay";
226
227 phy-mode = "sgmii";
228 qcom,id = <2>;
229
230 mtd-mac-address = <&ART 0>;
231
232 fixed-link {
233 speed = <1000>;
234 full-duplex;
235 };
236 };
237
238 &gsbi4_serial {
239 pinctrl-0 = <&uart0_pins>;
240 pinctrl-names = "default";
241 };
242
243 &gsbi5 {
244 status = "okay";
245 qcom,mode = <GSBI_PROT_SPI>;
246
247 spi@1a280000 {
248 status = "okay";
249
250 pinctrl-0 = <&spi_pins>;
251 pinctrl-names = "default";
252
253 cs-gpios = <&qcom_pinmux 20 GPIO_ACTIVE_HIGH>;
254
255 flash@0 {
256 compatible = "jedec,spi-nor";
257 spi-max-frequency = <50000000>;
258 reg = <0>;
259
260 partitions {
261 compatible = "fixed-partitions";
262 #address-cells = <1>;
263 #size-cells = <1>;
264
265 SBL1@0 {
266 label = "SBL1";
267 reg = <0x0 0x10000>;
268 read-only;
269 };
270
271 MIBIB@10000 {
272 label = "MIBIB";
273 reg = <0x10000 0x20000>;
274 read-only;
275 };
276
277 SBL2@30000 {
278 label = "SBL2";
279 reg = <0x30000 0x30000>;
280 read-only;
281 };
282
283 SBL3@60000 {
284 label = "SBL3";
285 reg = <0x60000 0x30000>;
286 read-only;
287 };
288
289 DDRCONFIG@90000 {
290 label = "DDRCONFIG";
291 reg = <0x90000 0x10000>;
292 read-only;
293 };
294
295 SSD@a0000 {
296 label = "SSD";
297 reg = <0xa0000 0x10000>;
298 read-only;
299 };
300
301 TZ@b0000 {
302 label = "TZ";
303 reg = <0xb0000 0x30000>;
304 read-only;
305 };
306
307 RPM@e0000 {
308 label = "RPM";
309 reg = <0xe0000 0x20000>;
310 read-only;
311 };
312
313 APPSBL@100000 {
314 label = "APPSBL";
315 reg = <0x100000 0x70000>;
316 read-only;
317 };
318
319 APPSBLENV@170000 {
320 label = "APPSBLENV";
321 reg = <0x170000 0x10000>;
322 read-only;
323 };
324
325 ART: ART@180000 {
326 label = "ART";
327 reg = <0x180000 0x40000>;
328 read-only;
329 };
330
331 BOOTCONFIG@1c0000 {
332 label = "BOOTCONFIG";
333 reg = <0x1c0000 0x10000>;
334 read-only;
335 };
336
337 APPSBL_1@1d0000 {
338 label = "APPSBL_1";
339 reg = <0x1d0000 0x70000>;
340 read-only;
341 };
342 };
343 };
344 };
345 };
346
347 &usb3_0 {
348 status = "okay";
349
350 pinctrl-0 = <&usb_pwr_en_pins>;
351 pinctrl-names = "default";
352 };
353
354 &usb3_1 {
355 status = "okay";
356 };
357
358 &dwc3_0 {
359 #address-cells = <1>;
360 #size-cells = <0>;
361
362 hub_port0: port@1 {
363 reg = <1>;
364 #trigger-source-cells = <0>;
365 };
366 };
367
368 &dwc3_1 {
369 #address-cells = <1>;
370 #size-cells = <0>;
371
372 hub_port1: port@1 {
373 reg = <1>;
374 #trigger-source-cells = <0>;
375 };
376 };
377
378 &pcie0 {
379 status = "okay";
380 };
381
382 &pcie1 {
383 status = "okay";
384 max-link-speed = <1>;
385 };
386
387 &qcom_pinmux {
388 button_pins: button_pins {
389 mux {
390 pins = "gpio6", "gpio54", "gpio55", "gpio56", "gpio57",
391 "gpio58", "gpio64", "gpio65";
392 function = "gpio";
393 drive-strength = <2>;
394 bias-pull-up;
395 };
396 };
397
398 led_pins: led_pins {
399 mux {
400 pins = "gpio7", "gpio8", "gpio9", "gpio16", "gpio22",
401 "gpio23", "gpio24", "gpio25", "gpio26", "gpio53";
402 function = "gpio";
403 drive-strength = <2>;
404 bias-pull-up;
405 };
406 };
407
408 uart0_pins: uart0_pins {
409 mux {
410 pins = "gpio10", "gpio11";
411 function = "gsbi4";
412 drive-strength = <12>;
413 bias-disable;
414 };
415 };
416
417 spi_pins: spi_pins {
418 mux {
419 pins = "gpio18", "gpio19", "gpio21";
420 function = "gsbi5";
421 bias-pull-down;
422 };
423
424 data {
425 pins = "gpio18", "gpio19";
426 drive-strength = <10>;
427 };
428
429 cs{
430 pins = "gpio20";
431 drive-strength = <10>;
432 bias-pull-up;
433 };
434
435 clk {
436 pins = "gpio21";
437 drive-strength = <12>;
438 };
439 };
440
441 usb_pwr_en_pins: usb_pwr_en_pins {
442 mux{
443 pins = "gpio68";
444 function = "gpio";
445 drive-strength = <2>;
446 bias-pull-up;
447 output-high;
448 };
449 };
450 };