f22838f7b4612fd03db0a6fa8eb0d16386af292f
[openwrt/staging/lynxis/omap.git] / target / linux / ipq806x / files / arch / arm / boot / dts / qcom-ipq8064-c2600.dts
1 #include "qcom-ipq8064-v1.0.dtsi"
2
3 #include <dt-bindings/input/input.h>
4
5 / {
6 model = "TP-Link Archer C2600";
7 compatible = "tplink,c2600", "qcom,ipq8064";
8
9 memory@0 {
10 reg = <0x42000000 0x1e000000>;
11 device_type = "memory";
12 };
13
14 reserved-memory {
15 #address-cells = <1>;
16 #size-cells = <1>;
17 ranges;
18 rsvd@41200000 {
19 reg = <0x41200000 0x300000>;
20 no-map;
21 };
22 };
23
24 aliases {
25 serial0 = &uart4;
26 mdio-gpio0 = &mdio0;
27
28 led-boot = &power;
29 led-failsafe = &general;
30 led-running = &power;
31 led-upgrade = &general;
32 };
33
34 chosen {
35 linux,stdout-path = "serial0:115200n8";
36 };
37
38 soc {
39 pinmux@800000 {
40 button_pins: button_pins {
41 mux {
42 pins = "gpio16", "gpio54", "gpio65";
43 function = "gpio";
44 drive-strength = <2>;
45 bias-pull-up;
46 };
47 };
48
49 i2c4_pins: i2c4_pinmux {
50 mux {
51 pins = "gpio12", "gpio13";
52 function = "gsbi4";
53 drive-strength = <12>;
54 bias-disable;
55 };
56 };
57
58 led_pins: led_pins {
59 mux {
60 pins = "gpio6", "gpio7", "gpio8", "gpio9", "gpio26", "gpio33",
61 "gpio53", "gpio66";
62 function = "gpio";
63 drive-strength = <2>;
64 bias-pull-up;
65 };
66 };
67
68 spi_pins: spi_pins {
69 mux {
70 pins = "gpio18", "gpio19", "gpio21";
71 function = "gsbi5";
72 bias-pull-down;
73 };
74
75 data {
76 pins = "gpio18", "gpio19";
77 drive-strength = <10>;
78 };
79
80 cs {
81 pins = "gpio20";
82 function = "gpio";
83 drive-strength = <10>;
84 bias-pull-up;
85 };
86
87 clk {
88 pins = "gpio21";
89 drive-strength = <12>;
90 };
91 };
92
93 mdio0_pins: mdio0_pins {
94 mux {
95 pins = "gpio0", "gpio1";
96 function = "gpio";
97 drive-strength = <8>;
98 bias-disable;
99 };
100 };
101
102 rgmii2_pins: rgmii2_pins {
103 mux {
104 pins = "gpio27", "gpio28", "gpio29", "gpio30", "gpio31", "gpio32",
105 "gpio51", "gpio52", "gpio59", "gpio60", "gpio61", "gpio62" ;
106 function = "rgmii2";
107 drive-strength = <8>;
108 bias-disable;
109 };
110 };
111
112 usb0_pwr_en_pin: usb0_pwr_en_pin {
113 mux {
114 pins = "gpio25";
115 function = "gpio";
116 drive-strength = <10>;
117 bias-pull-up;
118 output-high;
119 };
120 };
121
122 usb1_pwr_en_pin: usb1_pwr_en_pin {
123 mux {
124 pins = "gpio23";
125 function = "gpio";
126 drive-strength = <10>;
127 bias-pull-up;
128 output-high;
129 };
130 };
131 };
132
133 gsbi@16300000 {
134 qcom,mode = <GSBI_PROT_I2C_UART>;
135 status = "ok";
136 serial@16340000 {
137 status = "ok";
138 };
139 /*
140 * The i2c device on gsbi4 should not be enabled.
141 * On ipq806x designs gsbi4 i2c is meant for exclusive
142 * RPM usage. Turning this on in kernel manifests as
143 * i2c failure for the RPM.
144 */
145 };
146
147 gsbi5: gsbi@1a200000 {
148 qcom,mode = <GSBI_PROT_SPI>;
149 status = "ok";
150
151 spi5: spi@1a280000 {
152 status = "ok";
153 spi-max-frequency = <50000000>;
154
155 pinctrl-0 = <&spi_pins>;
156 pinctrl-names = "default";
157
158 cs-gpios = <&qcom_pinmux 20 GPIO_ACTIVE_HIGH>;
159
160 flash: m25p80@0 {
161 compatible = "jedec,spi-nor";
162 #address-cells = <1>;
163 #size-cells = <1>;
164 spi-max-frequency = <50000000>;
165 reg = <0>;
166
167 SBL1@0 {
168 label = "SBL1";
169 reg = <0x0 0x20000>;
170 read-only;
171 };
172
173 MIBIB@20000 {
174 label = "MIBIB";
175 reg = <0x20000 0x20000>;
176 read-only;
177 };
178
179 SBL2@40000 {
180 label = "SBL2";
181 reg = <0x40000 0x20000>;
182 read-only;
183 };
184
185 SBL3@60000 {
186 label = "SBL3";
187 reg = <0x60000 0x30000>;
188 read-only;
189 };
190
191 DDRCONFIG@90000 {
192 label = "DDRCONFIG";
193 reg = <0x90000 0x10000>;
194 read-only;
195 };
196
197 SSD@a0000 {
198 label = "SSD";
199 reg = <0xa0000 0x10000>;
200 read-only;
201 };
202
203 TZ@b0000 {
204 label = "TZ";
205 reg = <0xb0000 0x30000>;
206 read-only;
207 };
208
209 RPM@e0000 {
210 label = "RPM";
211 reg = <0xe0000 0x20000>;
212 read-only;
213 };
214
215 fs-uboot@100000 {
216 label = "fs-uboot";
217 reg = <0x100000 0x70000>;
218 read-only;
219 };
220
221 uboot-env@170000 {
222 label = "uboot-env";
223 reg = <0x170000 0x40000>;
224 read-only;
225 };
226
227 radio@1b0000 {
228 label = "radio";
229 reg = <0x1b0000 0x40000>;
230 read-only;
231 };
232
233 os-image@1f0000 {
234 label = "os-image";
235 reg = <0x1f0000 0x200000>;
236 };
237
238 rootfs@3f0000 {
239 label = "rootfs";
240 reg = <0x3f0000 0x1b00000>;
241 };
242
243 defaultmac: default-mac@1ef0000 {
244 label = "default-mac";
245 reg = <0x1ef0000 0x00200>;
246 read-only;
247 };
248
249 pin@1ef0200 {
250 label = "pin";
251 reg = <0x1ef0200 0x00200>;
252 read-only;
253 };
254
255 product-info@1ef0400 {
256 label = "product-info";
257 reg = <0x1ef0400 0x0fc00>;
258 read-only;
259 };
260
261 partition-table@1f00000 {
262 label = "partition-table";
263 reg = <0x1f00000 0x10000>;
264 read-only;
265 };
266
267 soft-version@1f10000 {
268 label = "soft-version";
269 reg = <0x1f10000 0x10000>;
270 read-only;
271 };
272
273 support-list@1f20000 {
274 label = "support-list";
275 reg = <0x1f20000 0x10000>;
276 read-only;
277 };
278
279 profile@1f30000 {
280 label = "profile";
281 reg = <0x1f30000 0x10000>;
282 read-only;
283 };
284
285 default-config@1f40000 {
286 label = "default-config";
287 reg = <0x1f40000 0x10000>;
288 read-only;
289 };
290
291 user-config@1f50000 {
292 label = "user-config";
293 reg = <0x1f50000 0x40000>;
294 read-only;
295 };
296
297 qos-db@1f90000 {
298 label = "qos-db";
299 reg = <0x1f90000 0x40000>;
300 read-only;
301 };
302
303 usb-config@1fd0000 {
304 label = "usb-config";
305 reg = <0x1fd0000 0x10000>;
306 read-only;
307 };
308
309 log@1fe0000 {
310 label = "log";
311 reg = <0x1fe0000 0x20000>;
312 read-only;
313 };
314 };
315 };
316 };
317
318 phy@100f8800 { /* USB3 port 1 HS phy */
319 status = "ok";
320 };
321
322 phy@100f8830 { /* USB3 port 1 SS phy */
323 status = "ok";
324 };
325
326 phy@110f8800 { /* USB3 port 0 HS phy */
327 status = "ok";
328 };
329
330 phy@110f8830 { /* USB3 port 0 SS phy */
331 status = "ok";
332 };
333
334 usb30@0 {
335 status = "ok";
336
337 pinctrl-0 = <&usb0_pwr_en_pin>;
338 pinctrl-names = "default";
339 };
340
341 usb30@1 {
342 status = "ok";
343
344 pinctrl-0 = <&usb1_pwr_en_pin>;
345 pinctrl-names = "default";
346 };
347
348 pcie0: pci@1b500000 {
349 status = "ok";
350 phy-tx0-term-offset = <7>;
351 };
352
353 pcie1: pci@1b700000 {
354 status = "ok";
355 phy-tx0-term-offset = <7>;
356 };
357
358 mdio0: mdio {
359 compatible = "virtual,mdio-gpio";
360 #address-cells = <1>;
361 #size-cells = <0>;
362 gpios = <&qcom_pinmux 1 GPIO_ACTIVE_HIGH &qcom_pinmux 0 GPIO_ACTIVE_HIGH>;
363 pinctrl-0 = <&mdio0_pins>;
364 pinctrl-names = "default";
365
366 phy0: ethernet-phy@0 {
367 device_type = "ethernet-phy";
368 reg = <0>;
369 qca,ar8327-initvals = <
370 0x00004 0x7600000 /* PAD0_MODE */
371 0x00008 0x1000000 /* PAD5_MODE */
372 0x0000c 0x80 /* PAD6_MODE */
373 0x000e4 0x6a545 /* MAC_POWER_SEL */
374 0x000e0 0xc74164de /* SGMII_CTRL */
375 0x0007c 0x4e /* PORT0_STATUS */
376 0x00094 0x4e /* PORT6_STATUS */
377 >;
378 };
379
380 phy4: ethernet-phy@4 {
381 device_type = "ethernet-phy";
382 reg = <4>;
383 };
384 };
385
386 gmac1: ethernet@37200000 {
387 status = "ok";
388 phy-mode = "rgmii";
389 qcom,id = <1>;
390
391 pinctrl-0 = <&rgmii2_pins>;
392 pinctrl-names = "default";
393
394 mtd-mac-address = <&defaultmac 0x8>;
395 mtd-mac-address-increment = <1>;
396
397 fixed-link {
398 speed = <1000>;
399 full-duplex;
400 };
401 };
402
403 gmac2: ethernet@37400000 {
404 status = "ok";
405 phy-mode = "sgmii";
406 qcom,id = <2>;
407
408 mtd-mac-address = <&defaultmac 0x8>;
409
410 fixed-link {
411 speed = <1000>;
412 full-duplex;
413 };
414 };
415
416 rpm@108000 {
417 pinctrl-0 = <&i2c4_pins>;
418 pinctrl-names = "default";
419 };
420 };
421
422 gpio-keys {
423 compatible = "gpio-keys";
424 pinctrl-0 = <&button_pins>;
425 pinctrl-names = "default";
426
427 wifi {
428 label = "wifi";
429 gpios = <&qcom_pinmux 49 GPIO_ACTIVE_LOW>;
430 linux,code = <KEY_RFKILL>;
431 };
432
433 reset {
434 label = "reset";
435 gpios = <&qcom_pinmux 64 GPIO_ACTIVE_LOW>;
436 linux,code = <KEY_RESTART>;
437 };
438
439 wps {
440 label = "wps";
441 gpios = <&qcom_pinmux 65 GPIO_ACTIVE_LOW>;
442 linux,code = <KEY_WPS_BUTTON>;
443 };
444
445 ledswitch {
446 label = "ledswitch";
447 gpios = <&qcom_pinmux 16 GPIO_ACTIVE_LOW>;
448 linux,code = <KEY_LIGHTS_TOGGLE>;
449 };
450 };
451
452 gpio-leds {
453 compatible = "gpio-leds";
454 pinctrl-0 = <&led_pins>;
455 pinctrl-names = "default";
456
457 lan {
458 label = "c2600:white:lan";
459 gpios = <&qcom_pinmux 6 GPIO_ACTIVE_HIGH>;
460 };
461
462 usb4 {
463 label = "c2600:white:usb_4";
464 gpios = <&qcom_pinmux 7 GPIO_ACTIVE_HIGH>;
465 };
466
467 usb2 {
468 label = "c2600:white:usb_2";
469 gpios = <&qcom_pinmux 8 GPIO_ACTIVE_HIGH>;
470 };
471
472 wps {
473 label = "c2600:white:wps";
474 gpios = <&qcom_pinmux 9 GPIO_ACTIVE_HIGH>;
475 };
476
477 wan_red {
478 label = "c2600:orange:wan";
479 gpios = <&qcom_pinmux 26 GPIO_ACTIVE_LOW>;
480 };
481
482 wan_blue {
483 label = "c2600:white:wan";
484 gpios = <&qcom_pinmux 33 GPIO_ACTIVE_LOW>;
485 };
486
487 power: status {
488 label = "c2600:white:status";
489 gpios = <&qcom_pinmux 53 GPIO_ACTIVE_HIGH>;
490 default-state = "keep";
491 };
492
493 general: general {
494 label = "c2600:white:general";
495 gpios = <&qcom_pinmux 66 GPIO_ACTIVE_HIGH>;
496 };
497 };
498 };
499
500 &adm_dma {
501 status = "ok";
502 };