54a15c49c1bd3c6e5ce48762698e8406ad77db85
[openwrt/openwrt.git] / target / linux / ath79 / dts / ar7161_ruckus_gd11.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 compatible = "ruckus,gd11", "qca,ar7161";
10
11 aliases {
12 led-boot = &led_power_green;
13 led-failsafe = &led_power_red;
14 led-running = &led_power_green;
15 led-upgrade = &led_power_red;
16 label-mac-device = &eth0;
17 };
18
19 keys: keys {
20 compatible = "gpio-keys";
21
22 reset {
23 label = "reset";
24 linux,code = <KEY_RESTART>;
25 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
26 debounce-interval = <60>;
27 };
28 };
29
30 leds {
31 compatible = "gpio-leds";
32 dir-green {
33 label = "green:dir";
34 gpios = <&gpio 6 GPIO_ACTIVE_HIGH>;
35 };
36
37 opt-green {
38 label = "green:opt";
39 gpios = <&gpio 7 GPIO_ACTIVE_HIGH>;
40 };
41
42 led_power_green: power-green {
43 label = "green:power";
44 gpios = <&gpio 0 GPIO_ACTIVE_HIGH>;
45 default-state = "on";
46 };
47
48 led_power_red: power-red {
49 label = "red:power";
50 gpios = <&gpio 1 GPIO_ACTIVE_HIGH>;
51 panic-indicator;
52 };
53
54 wlan2g-green {
55 label = "green:wlan2g";
56 gpios = <&gpio 2 GPIO_ACTIVE_HIGH>;
57 linux,default-trigger = "phy0assoc";
58 };
59
60 wlan2g-yellow {
61 label = "yellow:wlan2g";
62 gpios = <&gpio 3 GPIO_ACTIVE_HIGH>;
63 linux,default-trigger = "phy0tpt";
64 };
65
66 wlan5g-green {
67 label = "green:wlan5g";
68 gpios = <&gpio 4 GPIO_ACTIVE_HIGH>;
69 linux,default-trigger = "phy1assoc";
70 };
71
72 wlan5g-yellow {
73 label = "yellow:wlan5g";
74 gpios = <&gpio 5 GPIO_ACTIVE_HIGH>;
75 linux,default-trigger = "phy1tpt";
76 };
77 };
78
79 reserved-memory {
80 #address-cells = <1>;
81 #size-cells = <1>;
82 ranges;
83
84 ruckus-himem@3ff0000 {
85 /* Ruckus Himem area used to control
86 * redundant boot image selection
87 */
88 compatible = "nvmem-rmem";
89 reg = <0x3ff0000 0x10000>;
90 no-map;
91 };
92 };
93
94 beamforming-2g-spi {
95 compatible = "spi-gpio";
96 mosi-gpios = <&ath9k0 5 GPIO_ACTIVE_HIGH>;
97 sck-gpios = <&ath9k0 6 GPIO_ACTIVE_HIGH>;
98 num-chipselects = <0>;
99 #address-cells = <1>;
100 #size-cells = <0>;
101
102 beamforming_2g_gpio: beamforming-2g-gpio@0 {
103 compatible = "fairchild,74hc595";
104 reg = <0>;
105 registers-number = <1>;
106 spi-max-frequency = <24000000>;
107 gpio-controller;
108 #gpio-cells = <2>;
109 };
110 };
111
112 beamforming-5g-spi {
113 compatible = "spi-gpio";
114 mosi-gpios = <&ath9k1 5 GPIO_ACTIVE_HIGH>;
115 sck-gpios = <&ath9k1 6 GPIO_ACTIVE_HIGH>;
116 num-chipselects = <0>;
117 #address-cells = <1>;
118 #size-cells = <0>;
119
120 beamforming_5g_gpio: beamforming-5g-gpio@0 {
121 compatible = "fairchild,74hc595";
122 reg = <0>;
123 registers-number = <1>;
124 spi-max-frequency = <24000000>;
125 gpio-controller;
126 #gpio-cells = <2>;
127 };
128 };
129 };
130
131 &pcie0 {
132 status = "okay";
133
134 ath9k0: wifi@11,0 { /* 2.4 GHz */
135 compatible = "pci168c,0029";
136 reg = <0x8800 0 0 0 0>;
137 nvmem-cells = <&macaddr_bdata_60>;
138 nvmem-cell-names = "mac-address";
139 #gpio-cells = <2>;
140 gpio-controller;
141 };
142
143 ath9k1: wifi@12,0 { /* 5 GHz */
144 compatible = "pci168c,0029";
145 reg = <0x9000 0 0 0 0>;
146 nvmem-cells = <&macaddr_bdata_76>;
147 nvmem-cell-names = "mac-address";
148 #gpio-cells = <2>;
149 gpio-controller;
150 };
151 };
152
153 &mdio0 {
154 status = "okay";
155
156 phy0: ethernet-phy@1e {
157 reg = <0x1e>;
158 };
159 };
160
161 &eth0 {
162 status = "okay";
163 nvmem-cells = <&macaddr_bdata_66>;
164 nvmem-cell-names = "mac-address";
165
166 pll-data = <0x00110000 0x00001099 0x00991099>;
167 phy-handle = <&phy0>;
168 phy-mode = "rgmii-id";
169 };
170
171 &spi {
172 status = "okay";
173
174 flash@0 {
175 compatible = "jedec,spi-nor";
176 reg = <0>;
177 spi-max-frequency = <104000000>;
178 m25p,fast-read;
179
180 partitions {
181 compatible = "fixed-partitions";
182 #address-cells = <1>;
183 #size-cells = <1>;
184
185 partition@0 {
186 reg = <0x0 0x40000>;
187 label = "u-boot";
188 read-only;
189 };
190
191 /* On stock FW this encompasses rcks_wlan.main,
192 * rcks_wlan.bkup and datafs partitions
193 */
194 partition@40000 {
195 compatible = "openwrt,uimage", "denx,uimage";
196 reg = <0x40000 0xf40000>;
197 label = "firmware";
198 };
199
200 partition@f80000 {
201 compatible = "u-boot,env";
202 reg = <0xf80000 0x40000>;
203 label = "u-boot-env";
204 };
205
206 board_data: partition@fc0000 {
207 reg = <0xfc0000 0x40000>;
208 label = "board-data";
209 read-only;
210 };
211 };
212 };
213 };
214
215 &usb1 {
216 status = "okay";
217 };
218
219 &usb2 {
220 status = "okay";
221 };
222
223 &usb_phy {
224 status = "okay";
225 };