20ff48cc272515bf1ecc6072d8c2d545106d82cf
[openwrt/staging/hauke.git] / target / linux / ath79 / dts / ar9344_enterasys_ws-ap3705i.dts
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 "ar9344.dtsi"
8
9 / {
10 compatible = "enterasys,ws-ap3705i", "qca,ar9344";
11 model = "Enterasys WS-AP3705i";
12
13 chosen {
14 bootargs = "console=ttyS0,115200n8";
15 };
16
17 aliases {
18 led-boot = &led_power_green;
19 led-failsafe = &led_power_red;
20 led-running = &led_power_green;
21 led-upgrade = &led_power_red;
22 label-mac-device = &eth0;
23 };
24
25 mtd-concat {
26 compatible = "mtd-concat";
27 devices = <&concat0 &concat1>;
28
29 partitions {
30 compatible = "fixed-partitions";
31 #address-cells = <1>;
32 #size-cells = <1>;
33
34 partition@0 {
35 compatible = "denx,uimage";
36 label = "firmware";
37 reg = <0x0 0x1dd0000>;
38 };
39 };
40 };
41
42 leds {
43 compatible = "gpio-leds";
44
45 pinctrl-names = "default";
46 pinctrl-0 = <&enable_gpio_11 &enable_gpio_16>;
47
48 led_power_green: power_green {
49 label = "ws-ap3705i:green:power";
50 gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
51 };
52
53 led_power_red: power_red {
54 label = "ws-ap3705i:red:power";
55 gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
56 };
57
58 lan_blue {
59 label = "ws-ap3705i:blue:lan";
60 gpios = <&gpio 19 GPIO_ACTIVE_HIGH>;
61 };
62
63 lan_green {
64 label = "ws-ap3705i:green:lan";
65 gpios = <&gpio 20 GPIO_ACTIVE_HIGH>;
66 };
67
68 radio2 {
69 label = "ws-ap3705i:green:radio2";
70 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
71 linux,default-trigger = "phy0tpt";
72 };
73 };
74
75 ath9k-leds {
76 compatible = "gpio-leds";
77
78 radio1 {
79 label = "ws-ap3705i:green:radio1";
80 gpios = <&ath9k 0 GPIO_ACTIVE_LOW>;
81 linux,default-trigger = "phy1tpt";
82 };
83 };
84
85 keys {
86 compatible = "gpio-keys";
87
88 reset {
89 label = "Reset button";
90 linux,code = <KEY_RESTART>;
91 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
92 };
93 };
94 };
95
96 &ref {
97 clock-frequency = <40000000>;
98 };
99
100 &uart {
101 status = "okay";
102 };
103
104 &pinmux {
105 enable_gpio_16: pinmux_enable_gpio_16 {
106 pinctrl-single,bits = <0x10 0x0 0x000000ff>;
107 };
108
109 enable_gpio_11: pinmux_enable_gpio_11 {
110 pinctrl-single,bits = <0x8 0x0 0xff000000>;
111 };
112 };
113
114 &wmac {
115 status = "okay";
116 qca,no-eeprom;
117 };
118
119 &spi {
120 status = "okay";
121
122 cs-gpios = <0>, <0>;
123 num-cs = <2>;
124
125 flash@0 {
126 compatible = "jedec,spi-nor";
127 reg = <0>;
128 spi-max-frequency = <25000000>;
129
130 partitions {
131 compatible = "fixed-partitions";
132 #address-cells = <1>;
133 #size-cells = <1>;
134
135 partition@0 {
136 label = "u-boot-bak";
137 reg = <0x0 0x80000>;
138 read-only;
139 };
140
141 partition@80000 {
142 label = "u-boot-env0";
143 reg = <0x80000 0x10000>;
144 read-only;
145 };
146
147 partition@90000 {
148 label = "u-boot-env1";
149 reg = <0x90000 0x10000>;
150 read-only;
151 };
152
153 partition@a0000 {
154 label = "u-boot";
155 reg = <0xa0000 0x80000>;
156 read-only;
157 };
158
159 partition@120000 {
160 label = "calibrate";
161 reg = <0x120000 0x10000>;
162 read-only;
163 };
164
165 partition@130000 {
166 label = "nvram";
167 reg = <0x130000 0x100000>;
168 read-only;
169 };
170
171 concat0: partition@230000 {
172 label = "concat0";
173 reg = <0x230000 0xdd0000>;
174 };
175 };
176 };
177
178 flash@1 {
179 compatible = "jedec,spi-nor";
180 reg = <1>;
181 spi-max-frequency = <25000000>;
182
183 partitions {
184 compatible = "fixed-partitions";
185 #address-cells = <1>;
186 #size-cells = <1>;
187
188 concat1: partition@0 {
189 label = "concat1";
190 reg = <0x0 0x1000000>;
191 };
192 };
193 };
194 };
195
196 &pcie {
197 status = "okay";
198
199 ath9k: wifi@0,0 {
200 compatible = "pci168c,0033";
201 reg = <0x0000 0 0 0 0>;
202 qca,no-eeprom;
203 #gpio-cells = <2>;
204 gpio-controller;
205 };
206 };
207
208 &mdio0 {
209 status = "okay";
210
211 phy0: ethernet-phy@0 {
212 reg = <0>;
213 };
214 };
215
216 &eth0 {
217 status = "okay";
218
219 pll-data = <0x1e000000 0x08000101 0x08001313>;
220
221 phy-mode = "rgmii";
222 phy-handle = <&phy0>;
223
224 gmac-config {
225 device = <&gmac>;
226 rgmii-gmac0 = <1>;
227 rxd-delay = <0>;
228 rxdv-delay = <0>;
229 txen-delay = <0>;
230 txd-delay = <0>;
231 };
232 };