ath79: fix dts warnings
[openwrt/openwrt.git] / target / linux / ath79 / dts / qca9563_tplink_tl-wr1043n.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 "qca956x.dtsi"
8
9 / {
10 chosen {
11 bootargs = "console=ttyS0,115200n8";
12 };
13
14 aliases {
15 led-status = &system;
16 };
17
18 gpio_leds: leds {
19 compatible = "gpio-leds";
20
21 system: system {
22 label = "tp-link:green:system";
23 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
24 linux,default-trigger = "heartbeat";
25 };
26
27 wifi_green {
28 label = "tp-link:green:wlan";
29 gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
30 default-state = "off";
31 linux,default-trigger = "phy0tpt";
32 };
33
34 wifi_wps {
35 label = "tp-link:green:wps";
36 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
37 default-state = "off";
38 };
39
40 wan {
41 label = "tp-link:green:wan";
42 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
43 default-state = "off";
44 };
45
46 wan_fail {
47 label = "tp-link:orange:wan";
48 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
49 default-state = "off";
50 };
51
52 lan1 {
53 label = "tp-link:green:lan1";
54 gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
55 default-state = "off";
56 };
57
58 lan2 {
59 label = "tp-link:green:lan2";
60 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
61 default-state = "off";
62 };
63
64 lan3 {
65 label = "tp-link:green:lan3";
66 gpios = <&gpio 21 GPIO_ACTIVE_LOW>;
67 default-state = "off";
68 };
69
70 lan4 {
71 label = "tp-link:green:lan4";
72 gpios = <&gpio 20 GPIO_ACTIVE_LOW>;
73 default-state = "off";
74 };
75 };
76
77 keys {
78 compatible = "gpio-keys";
79
80 reset {
81 label = "Reset button";
82 linux,code = <KEY_RESTART>;
83 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
84 debounce-interval = <60>;
85 };
86
87 wifi {
88 label = "RFKILL button";
89 linux,code = <KEY_RFKILL>;
90 gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
91 debounce-interval = <60>;
92 };
93 };
94
95 gpio-export {
96 compatible = "gpio-export";
97 #size-cells = <0>;
98
99 gpio_usb_power {
100 gpio-export,name = "tp-link:power:usb";
101 gpio-export,output = <1>;
102 gpios = <&gpio 8 GPIO_ACTIVE_HIGH>;
103 };
104 };
105 };
106
107 &uart {
108 status = "okay";
109 };
110
111 &gpio {
112 status = "okay";
113 };
114
115 &spi {
116 status = "okay";
117 num-cs = <1>;
118
119 flash@0 {
120 compatible = "jedec,spi-nor";
121 reg = <0>;
122 spi-max-frequency = <25000000>;
123
124 partitions {
125 compatible = "fixed-partitions";
126 #address-cells = <1>;
127 #size-cells = <1>;
128
129 partition@0 {
130 label = "u-boot";
131 reg = <0x000000 0x020000>;
132 read-only;
133 };
134
135 partition@20000 {
136 label = "firmware";
137 reg = <0x020000 0xf30000>;
138 };
139
140 info: partition@f50000 {
141 label = "product-info";
142 reg = <0xf50000 0x020000>;
143 read-only;
144 };
145
146 partition@f70000 {
147 label = "config";
148 reg = <0xf70000 0x050000>;
149 read-only;
150 };
151
152 partition@fc0000 {
153 label = "partition-table";
154 reg = <0xfc0000 0x010000>;
155 read-only;
156 };
157
158 partition@fd0000 {
159 label = "logs";
160 reg = <0xfd0000 0x020000>;
161 read-only;
162 };
163
164 art: partition@ff0000 {
165 label = "ART";
166 reg = <0xff0000 0x010000>;
167 read-only;
168 };
169 };
170 };
171 };
172
173 &mdio0 {
174 status = "okay";
175
176 phy-mask = <0>;
177 phy0: ethernet-phy@0 {
178 reg = <0>;
179 phy-mode = "sgmii";
180
181 qca,ar8327-initvals = <
182 0x04 0x00080080 /* PORT0 PAD MODE CTRL */
183 0x7c 0x0000007e /* PORT0_STATUS */
184 >;
185 };
186 };
187
188 &eth0 {
189 status = "okay";
190
191 mtd-mac-address = <&info 0x8>;
192 phy-mode = "sgmii";
193 phy-handle = <&phy0>;
194 };
195
196 &wmac {
197 status = "okay";
198 mtd-cal-data = <&art 0x1000>;
199 mtd-mac-address = <&info 0x8>;
200 };