ath79: Add support for TP-Link CPE210 v3
[oweals/openwrt.git] / target / linux / ath79 / dts / qca9533_tplink_cpe210.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2 /dts-v1/;
3
4 #include <dt-bindings/gpio/gpio.h>
5 #include <dt-bindings/input/input.h>
6
7 #include "qca953x.dtsi"
8
9 / {
10         chosen {
11                 bootargs = "console=ttyS0,115200n8";
12         };
13
14         aliases {
15                 led-boot = &system;
16                 led-failsafe = &system;
17                 led-running = &system;
18                 led-upgrade = &system;
19         };
20
21         leds {
22                 compatible = "gpio-leds";
23
24                 lan {
25                         label = "tp-link:green:lan";
26                         gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
27                 };
28
29                 link1 {
30                         label = "tp-link:green:link1";
31                         gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
32                 };
33
34                 link2 {
35                         label = "tp-link:green:link2";
36                         gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
37                 };
38
39                 link3 {
40                         label = "tp-link:green:link3";
41                         gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
42                 };
43
44                 system: link4 {
45                         label = "tp-link:green:link4";
46                         gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
47                 };
48         };
49
50 };
51
52 &uart {
53         status = "okay";
54 };
55
56 &spi {
57         status = "okay";
58         num-cs = <1>;
59
60         flash@0 {
61                 #address-cells = <1>;
62                 #size-cells = <1>;
63                 compatible = "jedec,spi-nor";
64                 reg = <0>;
65                 spi-max-frequency = <25000000>;
66
67                 partitions {
68                         compatible = "fixed-partitions";
69                         #address-cells = <1>;
70                         #size-cells = <1>;
71
72                         uboot: partition@0 {
73                                 label = "u-boot";
74                                 reg = <0x000000 0x020000>;
75                                 read-only;
76                         };
77
78                         partition@20000 {
79                                 label = "partition-table";
80                                 reg = <0x020000 0x10000>;
81                                 read-only;
82                         };
83
84                         info: partition@30000 {
85                                 label = "product-info";
86                                 reg = <0x030000 0x10000>;
87                                 read-only;
88                         };
89
90                         partition@40000 {
91                                 label = "firmware";
92                                 reg = <0x040000 0x780000>;
93                                 compatible = "tplink,firmware";
94                         };
95
96                         config: partition@7c0000 {
97                                 label = "config";
98                                 reg = <0x7c0000 0x30000>;
99                                 read-only;
100                         };
101
102                         ART: partition@7f0000 {
103                                 label = "ART";
104                                 reg = <0x7f0000 0x10000>;
105                                 read-only;
106                         };
107                 };
108         };
109 };
110
111 &eth0 {
112         status = "okay";
113         phy-handle = <&swphy4>;
114         mtd-mac-address = <&info 0x8>;
115 };
116
117 &eth1 {
118         compatible = "syscon", "simple-mfd";
119 };
120
121 &wmac {
122         status = "okay";
123         mtd-cal-data = <&ART 0x1000>;
124         mtd-mac-address = <&info 0x8>;
125 };