ath79: update WA/XC devices UBNT_VERSION to 8.7.4
[openwrt/staging/wigyori.git] / target / linux / ath79 / dts / ar9132_buffalo_wzr-hp-g300nh.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "ar9132.dtsi"
4 #include <dt-bindings/gpio/gpio.h>
5 #include <dt-bindings/input/input.h>
6 #include <dt-bindings/leds/common.h>
7
8 / {
9 aliases {
10 led-boot = &led_diag;
11 led-failsafe = &led_security;
12 led-upgrade = &led_diag;
13 };
14
15 /* There is a GPIO driven NXP 74HC153 dual 4-way multiplexer on board
16 * used for buttons that are on top of the the device.
17 */
18 mux: mux-controller {
19 compatible = "gpio-mux";
20 #mux-control-cells = <0>;
21
22 mux-gpios = <&gpio 9 GPIO_ACTIVE_HIGH>, /* s0 */
23 <&gpio 11 GPIO_ACTIVE_HIGH>; /* s1 */
24 };
25
26 gpio2: key-mux1 {
27 compatible = "gpio-cascade";
28 mux-controls = <&mux>;
29
30 gpio-controller;
31 #gpio-cells = <2>;
32
33 // GPIOs used by this node, the mux pin
34 upstream-gpios = <&gpio 12 GPIO_ACTIVE_HIGH>; /* 1y */
35 };
36
37 gpio3: key-mux2 {
38 compatible = "gpio-cascade";
39 mux-controls = <&mux>;
40
41 gpio-controller;
42 #gpio-cells = <2>;
43
44 // GPIOs used by this node, the mux pin
45 upstream-gpios = <&gpio 14 GPIO_ACTIVE_HIGH>; /* 2y */
46 };
47
48 keys {
49 compatible = "gpio-keys-polled";
50 poll-interval = <20>;
51
52 aoss {
53 label = "aoss";
54 linux,code = <KEY_WPS_BUTTON>;
55 gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
56 debounce-interval = <60>;
57 };
58
59 reset {
60 label = "reset";
61 linux,code = <KEY_RESTART>;
62 gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
63 debounce-interval = <60>;
64 };
65
66 router_on {
67 label = "router_on";
68 linux,code = <BTN_5>;
69 gpios = <&gpio2 2 GPIO_ACTIVE_HIGH>;
70 debounce-interval = <60>;
71 };
72
73 movie_off {
74 label = "movie_off";
75 linux,code = <BTN_3>;
76 gpios = <&gpio2 3 GPIO_ACTIVE_HIGH>;
77 debounce-interval = <60>;
78 };
79
80 usb {
81 label = "usb";
82 linux,code = <BTN_2>;
83 gpios = <&gpio3 1 GPIO_ACTIVE_LOW>;
84 debounce-interval = <60>;
85 };
86
87 router_auto {
88 label = "router_auto";
89 linux,code = <BTN_6>;
90 gpios = <&gpio3 2 GPIO_ACTIVE_HIGH>;
91 debounce-interval = <60>;
92 };
93
94 movie_on {
95 label = "movie_on";
96 linux,code = <BTN_4>;
97 gpios = <&gpio3 3 GPIO_ACTIVE_HIGH>;
98 debounce-interval = <60>;
99 };
100 };
101
102 flash@1e000000 {
103 compatible = "cfi-flash";
104 reg = <0x1e000000 0x2000000>;
105 bank-width = <2>;
106 device-width = <2>;
107
108 partitions {
109 compatible = "fixed-partitions";
110 #address-cells = <1>;
111 #size-cells = <1>;
112
113 partition@0 {
114 label = "u-boot";
115 reg = <0x0000000 0x0040000>;
116 read-only;
117 };
118
119 partition@40000 {
120 label = "u-boot-env";
121 reg = <0x0040000 0x0020000>;
122 read-only;
123 };
124
125 partition@60000 {
126 compatible = "denx,uimage";
127 label = "firmware";
128 reg = <0x0060000 0x1f60000>;
129 };
130
131 partition@1fc0000 {
132 label = "user_property";
133 reg = <0x1fc0000 0x0020000>;
134 read-only;
135 };
136
137 art: partition@1fe0000 {
138 label = "art";
139 reg = <0x1fe0000 0x020000>;
140 read-only;
141
142 nvmem-layout {
143 compatible = "fixed-layout";
144 #address-cells = <1>;
145 #size-cells = <1>;
146
147 macaddr_art_1120c: macaddr@1120c {
148 reg = <0x1120c 0x6>;
149 };
150 };
151 };
152 };
153 };
154
155 leds {
156 compatible = "gpio-leds";
157
158 usb {
159 function = LED_FUNCTION_USB;
160 color = <LED_COLOR_ID_BLUE>;
161 gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
162 trigger-sources = <&hub_port>;
163 linux,default-trigger = "usbport";
164 };
165
166 led_diag: diag {
167 label = "red:diag";
168 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
169 };
170
171 wireless {
172 label = "green:wireless";
173 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
174 linux,default-trigger = "phy0tpt";
175 };
176
177 led_security: security {
178 label = "amber:security";
179 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
180 };
181
182 router {
183 label = "green:router";
184 gpios = <&gpio 18 GPIO_ACTIVE_LOW>;
185 };
186 };
187
188 switch: switch {
189 status = "disabled";
190
191 gpio-sda = <&gpio 19 GPIO_ACTIVE_HIGH>;
192 gpio-sck = <&gpio 20 GPIO_ACTIVE_HIGH>;
193
194 mdio-bus {
195 status = "okay";
196
197 #address-cells = <1>;
198 #size-cells = <0>;
199
200 phy4: ethernet-phy@4 {
201 reg = <4>;
202 phy-mode = "rgmii";
203 };
204 };
205 };
206 };
207
208 &mdio0 {
209 status = "okay";
210 };
211
212 &eth0 {
213 status = "disabled";
214
215 phy-mode = "rgmii";
216 nvmem-cells = <&macaddr_art_1120c>;
217 nvmem-cell-names = "mac-address";
218
219 fixed-link {
220 speed = <1000>;
221 full-duplex;
222 };
223 };
224
225 &mdio1 {
226 status = "okay";
227 };
228
229 &eth1 {
230 status = "disabled";
231
232 compatible = "qca,ar9130-eth", "syscon";
233 reg = <0x1a000000 0x200
234 0x18070004 0x4>;
235
236 pll-reg = <0x4 0x18 22>;
237 pll-handle = <&pll>;
238
239 phy-mode = "rgmii";
240 phy-handle = <&phy4>;
241 resets = <&rst 13>;
242 reset-names = "mac";
243 qca,mac-idx = <1>;
244 nvmem-cells = <&macaddr_art_1120c>;
245 nvmem-cell-names = "mac-address";
246 };
247
248 &wmac {
249 status = "okay";
250
251 mtd-cal-data = <&art 0x11000>;
252 };
253
254 &uart {
255 status = "okay";
256 };
257
258 &usb {
259 status = "okay";
260 };
261
262 &usb_phy {
263 status = "okay";
264 };