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