ath79: mikrotik: fix dts warnings
[openwrt/staging/hauke.git] / target / linux / ath79 / dts / ar7161_buffalo_wzr-hp-ag300h.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "ar7100.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 aliases {
10 led-boot = &led_diag;
11 led-failsafe = &led_diag;
12 led-upgrade = &led_diag;
13 };
14
15 leds {
16 compatible = "gpio-leds";
17
18 led_diag: diag {
19 label = "red:diag";
20 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
21 };
22 };
23
24 ath9k-leds {
25 compatible = "gpio-leds";
26
27 band2g_a {
28 label = "amber:band2g";
29 gpios = <&ath9k0 1 GPIO_ACTIVE_LOW>;
30 };
31
32 usb {
33 label = "green:usb";
34 gpios = <&ath9k0 3 GPIO_ACTIVE_LOW>;
35 trigger-sources = <&usb_ohci_port>, <&usb_ehci_port>;
36 linux,default-trigger = "usbport";
37 };
38
39 band2g_g {
40 label = "green:band2g";
41 gpios = <&ath9k0 5 GPIO_ACTIVE_LOW>;
42 linux,default-trigger = "phy0tpt";
43 };
44
45 band5g_g {
46 label = "green:band5g";
47 gpios = <&ath9k1 1 GPIO_ACTIVE_LOW>;
48 linux,default-trigger = "phy1tpt";
49 };
50
51 router {
52 label = "green:router";
53 gpios = <&ath9k1 3 GPIO_ACTIVE_LOW>;
54 };
55
56 movie_engine {
57 label = "blue:movie_engine";
58 gpios = <&ath9k1 4 GPIO_ACTIVE_LOW>;
59 };
60
61 band5g_a {
62 label = "amber:band5g";
63 gpios = <&ath9k1 5 GPIO_ACTIVE_LOW>;
64 };
65 };
66
67 keys {
68 compatible = "gpio-keys";
69
70 reset {
71 label = "reset";
72 linux,code = <KEY_RESTART>;
73 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
74 debounce-interval = <60>;
75 };
76
77 usb {
78 label = "usb";
79 linux,code = <BTN_2>;
80 gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
81 debounce-interval = <60>;
82 };
83
84 aoss {
85 label = "aoss";
86 linux,code = <KEY_WPS_BUTTON>;
87 gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
88 debounce-interval = <60>;
89 };
90
91 router_auto {
92 label = "router_auto";
93 linux,code = <BTN_6>;
94 linux,input-type = <EV_SW>;
95 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
96 debounce-interval = <60>;
97 };
98
99 router_off {
100 label = "router_off";
101 linux,code = <BTN_5>;
102 linux,input-type = <EV_SW>;
103 gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
104 debounce-interval = <60>;
105 };
106
107 movie_engine {
108 label = "movie_engine";
109 linux,code = <BTN_7>;
110 linux,input-type = <EV_SW>;
111 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
112 debounce-interval = <60>;
113 };
114 };
115
116 gpio-export {
117 compatible = "gpio-export";
118
119 gpio_usb_power {
120 gpio-export,name = "buffalo:power:usb";
121 gpio-export,output = <1>;
122 gpios = <&gpio 2 GPIO_ACTIVE_HIGH>;
123 };
124 };
125
126 flash {
127 compatible = "mtd-concat";
128
129 devices = <&flash0 &flash1>;
130
131 partitions {
132 compatible = "fixed-partitions";
133 #address-cells = <1>;
134 #size-cells = <1>;
135 partition@0 {
136 label = "u-boot";
137 reg = <0x0000000 0x0040000>;
138 read-only;
139 };
140
141 partition@40000 {
142 label = "u-boot-env";
143 reg = <0x0040000 0x0010000>;
144 read-only;
145 };
146
147 art: partition@50000 {
148 label = "art";
149 reg = <0x0050000 0x0010000>;
150 read-only;
151 };
152
153 partition@60000 {
154 compatible = "denx,uimage";
155 label = "firmware";
156 reg = <0x0060000 0x1f90000>;
157 };
158
159 partition@1ff0000 {
160 label = "user_property";
161 reg = <0x1ff0000 0x0010000>;
162 read-only;
163 };
164 };
165 };
166 };
167
168 &usb_phy {
169 status = "okay";
170 };
171
172 &usb1 {
173 status = "okay";
174 };
175
176 &usb2 {
177 status = "okay";
178 };
179
180 &pcie0 {
181 status = "okay";
182
183 ath9k0: wifi@0,11 {
184 compatible = "pci168c,0029";
185 reg = <0x8800 0 0 0 0>;
186 qca,no-eeprom;
187 #gpio-cells = <2>;
188 gpio-controller;
189 };
190
191 ath9k1: wifi@0,12 {
192 compatible = "pci168c,0029";
193 reg = <0x9000 0 0 0 0>;
194 qca,no-eeprom;
195 #gpio-cells = <2>;
196 gpio-controller;
197 };
198 };
199
200 &spi {
201 status = "okay";
202
203
204 flash0: flash@0 {
205 compatible = "jedec,spi-nor";
206 reg = <0>;
207 spi-max-frequency = <50000000>;
208 m25p,fast-read;
209 };
210
211 flash1: flash@1 {
212 compatible = "jedec,spi-nor";
213 reg = <1>;
214 spi-max-frequency = <50000000>;
215 m25p,fast-read;
216 };
217 };
218
219 &mdio0 {
220 status = "okay";
221
222 phy4: ethernet-phy@4 {
223 reg = <4>;
224 phy-mode = "rgmii";
225 };
226 };
227
228 &eth0 {
229 status = "okay";
230
231 nvmem-cells = <&macaddr_art_120c>;
232 nvmem-cell-names = "mac-address";
233
234 fixed-link {
235 speed = <1000>;
236 full-duplex;
237 };
238 };
239
240 &eth1 {
241 status = "okay";
242
243 nvmem-cells = <&macaddr_art_520c>;
244 nvmem-cell-names = "mac-address";
245 mac-address-increment = <1>;
246
247 phy-handle = <&phy4>;
248 };
249
250 &art {
251 compatible = "nvmem-cells";
252 #address-cells = <1>;
253 #size-cells = <1>;
254
255 macaddr_art_120c: macaddr@120c {
256 reg = <0x120c 0x6>;
257 };
258
259 macaddr_art_520c: macaddr@520c {
260 reg = <0x520c 0x6>;
261 };
262 };