1d4be4d3164f5bd420c8c94aec40ade07d4a38b9
[openwrt/staging/hauke.git] / target / linux / ath79 / dts / ar9344_aerohive_hiveap-121.dts
1 // SPDX-License-Identifier: GPL-2.0-only
2
3 #include "ar9344.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "aerohive,hiveap-121", "qca,ar9344";
10 model = "Aerohive HiveAP 121";
11
12 aliases {
13 led-boot = &led_power_white;
14 led-failsafe = &led_power_orange;
15 led-running = &led_power_white;
16 led-upgrade = &led_power_orange;
17 label-mac-device = &eth0;
18 };
19
20 chosen {
21 bootargs = "console=ttyS0,9600";
22 };
23
24 keys {
25 compatible = "gpio-keys";
26
27 reset {
28 label = "Reset button";
29 linux,code = <KEY_RESTART>;
30 gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
31 debounce-interval = <60>;
32 };
33 };
34
35 leds {
36 compatible = "gpio-leds";
37
38 led_power_orange: power_orange {
39 label = "orange:power";
40 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
41 };
42
43 led_power_white: power_white {
44 label = "white:power";
45 gpios = <&gpio 21 GPIO_ACTIVE_LOW>;
46 };
47 };
48
49 i2c {
50 compatible = "i2c-gpio";
51 gpios = <&gpio 13 GPIO_ACTIVE_HIGH /* sda */
52 &gpio 12 GPIO_ACTIVE_HIGH /* scl */
53 >;
54 #address-cells = <1>;
55 #size-cells = <0>;
56
57 tpm@29 {
58 compatible = "atmel,at97sc3204t";
59 reg = <0x29>;
60 };
61 };
62 };
63
64 &ref {
65 clock-frequency = <40000000>;
66 };
67
68 &gpio {
69 pinctrl-names = "default";
70 pinctrl-0 = <&jtag_disable_pins>;
71
72 gpio_ext_lna0 {
73 gpio-hog;
74 gpios = <20 0>;
75 output-low;
76 line-name = "hiveap-121:ext:lna0";
77 };
78
79 gpio_ext_lna1 {
80 gpio-hog;
81 gpios = <19 0>;
82 output-low;
83 line-name = "hiveap-121:ext:lna1";
84 };
85
86 gpio_usb_power {
87 gpio-hog;
88 gpios = <15 0>;
89 output-high;
90 line-name = "hiveap-121:power:usb";
91 };
92 };
93
94 &usb {
95 status = "okay";
96 };
97
98 &usb_phy {
99 status = "okay";
100 };
101
102 &pcie {
103 status = "okay";
104
105 wifi@0,0 {
106 compatible = "pci168c,0030";
107 reg = <0x0000 0 0 0 0>;
108
109 nvmem-cells = <&macaddr_hw_info_0>;
110 nvmem-cell-names = "mac-address";
111 mac-address-increment = <2>;
112 };
113 };
114
115 &spi {
116 status = "okay";
117
118 flash@0 {
119 compatible = "jedec,spi-nor";
120 reg = <0>;
121 spi-max-frequency = <25000000>;
122
123 partitions {
124 compatible = "fixed-partitions";
125 #address-cells = <1>;
126 #size-cells = <1>;
127
128 partition@0 {
129 label = "u-boot";
130 reg = <0x000000 0x80000>;
131 read-only;
132 };
133
134 partition@80000 {
135 label = "u-boot-env";
136 reg = <0x80000 0x10000>;
137 read-only;
138 };
139
140 hw_info: partition@90000 {
141 label = "hw-info";
142 reg = <0x90000 0x10000>;
143 read-only;
144
145 nvmem-layout {
146 compatible = "fixed-layout";
147 #address-cells = <1>;
148 #size-cells = <1>;
149
150 macaddr_hw_info_0: macaddr@0 {
151 reg = <0x0 0x6>;
152 };
153 };
154 };
155
156 partition@a0000 {
157 label = "boot-info";
158 reg = <0xa0000 0x10000>;
159 read-only;
160 };
161
162 partition@b0000 {
163 label = "boot-sinfo";
164 reg = <0xb0000 0x10000>;
165 read-only;
166 };
167 };
168 };
169 };
170
171 &wmac {
172 status = "okay";
173
174 nvmem-cells = <&macaddr_hw_info_0>;
175 nvmem-cell-names = "mac-address";
176 mac-address-increment = <1>;
177 };
178
179 &nand {
180 status = "okay";
181
182 partitions {
183 compatible = "fixed-partitions";
184 #address-cells = <1>;
185 #size-cells = <1>;
186
187 partition@0 {
188 label = "u-boot1";
189 reg = <0x0 0x400000>;
190 read-only;
191 };
192
193 partition@400000 {
194 label = "u-boot-env1";
195 reg = <0x400000 0x400000>;
196 read-only;
197 };
198
199 partition@800000 {
200 label = "kernel";
201 reg = <0x800000 0x500000>;
202 };
203
204 partition@d00000 {
205 label = "ubi";
206 reg = <0xd00000 0x6f00000>;
207 };
208
209 partition@2e00000 {
210 label = "wifi-info";
211 reg = <0x7c00000 0x400000>;
212 read-only;
213 };
214 };
215 };
216
217 &mdio0 {
218 status = "okay";
219
220 phy0: ethernet-phy@0 {
221 reg = <0>;
222 };
223 };
224
225 &eth0 {
226 status = "okay";
227
228 pll-data = <0x06000000 0x00000101 0x00001313>;
229
230 nvmem-cells = <&macaddr_hw_info_0>;
231 nvmem-cell-names = "mac-address";
232
233 phy-mode = "rgmii-id";
234 phy-handle = <&phy0>;
235
236 gmac-config {
237 device = <&gmac>;
238 rgmii-gmac0 = <1>;
239 rxd-delay = <1>;
240 rxdv-delay = <1>;
241 };
242 };