ipq40xx: switch default to 6.6
[openwrt/openwrt.git] / target / linux / ipq40xx / files-6.1 / arch / arm / boot / dts / qcom-ipq4018-hap-ac2.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2 /* Copyright (c) 2020, Robert Marko <robimarko@gmail.com> */
3
4 #include "qcom-ipq4019.dtsi"
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7 #include <dt-bindings/leds/common.h>
8 #include <dt-bindings/soc/qcom,tcsr.h>
9
10 / {
11 model = "MikroTik hAP ac2";
12 compatible = "mikrotik,hap-ac2";
13
14 memory {
15 device_type = "memory";
16 reg = <0x80000000 0x08000000>;
17 };
18
19 chosen {
20 stdout-path = "serial0:115200n8";
21 };
22
23 aliases {
24 led-boot = &led_user;
25 led-failsafe = &led_user;
26 led-running = &led_user;
27 led-upgrade = &led_user;
28 };
29
30 soc {
31 rng@22000 {
32 status = "okay";
33 };
34
35 counter@4a1000 {
36 compatible = "qcom,qca-gcnt";
37 reg = <0x4a1000 0x4>;
38 };
39
40 tcsr@1949000 {
41 compatible = "qcom,tcsr";
42 reg = <0x1949000 0x100>;
43 qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
44 };
45
46 tcsr@194b000 {
47 /* select hostmode */
48 compatible = "qcom,tcsr";
49 reg = <0x194b000 0x100>;
50 qcom,usb-hsphy-mode-select = <TCSR_USB_HSPHY_HOST_MODE>;
51 status = "okay";
52 };
53
54 ess_tcsr@1953000 {
55 compatible = "qcom,tcsr";
56 reg = <0x1953000 0x1000>;
57 qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
58 };
59
60 tcsr@1957000 {
61 compatible = "qcom,tcsr";
62 reg = <0x1957000 0x100>;
63 qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
64 };
65
66 usb3@8af8800 {
67 status = "okay";
68
69 dwc3@8a00000 {
70 phys = <&usb3_hs_phy>;
71 phy-names = "usb2-phy";
72 };
73 };
74
75 crypto@8e3a000 {
76 status = "okay";
77 };
78
79 watchdog@b017000 {
80 status = "okay";
81 };
82 };
83
84 keys {
85 compatible = "gpio-keys";
86
87 reset {
88 label = "reset";
89 gpios = <&tlmm 63 GPIO_ACTIVE_LOW>;
90 linux,code = <KEY_RESTART>;
91 };
92
93 mode {
94 label = "mode";
95 gpios = <&tlmm 5 GPIO_ACTIVE_LOW>;
96 linux,code = <KEY_RFKILL>;
97 };
98 };
99
100 leds {
101 compatible = "gpio-leds";
102
103 power {
104 function = LED_FUNCTION_POWER;
105 color = <LED_COLOR_ID_GREEN>;
106 gpios = <&tlmm 0 GPIO_ACTIVE_HIGH>;
107 default-state = "keep";
108 panic-indicator;
109 };
110
111 led_user: user {
112 label = "green:user";
113 gpios = <&tlmm 3 GPIO_ACTIVE_HIGH>;
114 };
115 };
116 };
117
118 &tlmm {
119 serial_pins: serial_pinmux {
120 mux {
121 pins = "gpio60", "gpio61";
122 function = "blsp_uart0";
123 bias-disable;
124 };
125 };
126
127 spi_0_pins: spi_0_pinmux {
128 pin {
129 function = "blsp_spi0";
130 pins = "gpio55", "gpio56", "gpio57";
131 drive-strength = <2>;
132 bias-disable;
133 };
134 pin_cs {
135 function = "gpio";
136 pins = "gpio54";
137 drive-strength = <2>;
138 bias-disable;
139 output-high;
140 };
141 };
142
143 enable-usb-power {
144 gpio-hog;
145 gpios = <2 GPIO_ACTIVE_HIGH>;
146 output-high;
147 line-name = "enable USB power";
148 };
149 };
150
151 &blsp_dma {
152 status = "okay";
153 };
154
155 &blsp1_spi1 {
156 status = "okay";
157
158 pinctrl-0 = <&spi_0_pins>;
159 pinctrl-names = "default";
160 cs-gpios = <&tlmm 54 GPIO_ACTIVE_HIGH>;
161
162 flash@0 {
163 reg = <0>;
164 compatible = "jedec,spi-nor";
165 spi-max-frequency = <40000000>;
166
167 partitions {
168 compatible = "fixed-partitions";
169 #address-cells = <1>;
170 #size-cells = <1>;
171
172 partition@0 {
173 label = "Qualcomm";
174 reg = <0x0 0x80000>;
175 read-only;
176 };
177
178 partition@80000 {
179 compatible = "mikrotik,routerboot-partitions";
180 #address-cells = <1>;
181 #size-cells = <1>;
182 label = "RouterBoot";
183 reg = <0x80000 0x80000>;
184
185 hard_config {
186 read-only;
187 size = <0x2000>;
188 };
189
190 dtb_config {
191 read-only;
192 };
193
194 soft_config {
195 };
196 };
197
198 partition@100000 {
199 compatible = "mikrotik,minor";
200 label = "firmware";
201 reg = <0x100000 0xf00000>;
202 };
203 };
204 };
205 };
206
207 &blsp1_uart1 {
208 status = "okay";
209
210 pinctrl-0 = <&serial_pins>;
211 pinctrl-names = "default";
212 };
213
214 &cryptobam {
215 status = "okay";
216 };
217
218 &usb3_hs_phy {
219 status = "okay";
220 };
221
222 &mdio {
223 status = "okay";
224 };
225
226 &ethphy0 {
227 qcom,single-led-1000;
228 qcom,single-led-100;
229 qcom,single-led-10;
230 };
231
232 &ethphy1 {
233 qcom,single-led-1000;
234 qcom,single-led-100;
235 qcom,single-led-10;
236 };
237
238 &ethphy2 {
239 qcom,single-led-1000;
240 qcom,single-led-100;
241 qcom,single-led-10;
242 };
243
244 &ethphy3 {
245 qcom,single-led-1000;
246 qcom,single-led-100;
247 qcom,single-led-10;
248 };
249
250 &ethphy4 {
251 qcom,single-led-1000;
252 qcom,single-led-100;
253 qcom,single-led-10;
254 };
255
256 &gmac {
257 status = "okay";
258 };
259
260 &switch {
261 status = "okay";
262 };
263
264 &swport1 {
265 status = "okay";
266 label = "lan4";
267 };
268
269 &swport2 {
270 status = "okay";
271 label = "lan3";
272 };
273
274 &swport3 {
275 status = "okay";
276 label = "lan2";
277 };
278
279 &swport4 {
280 status = "okay";
281 label = "lan1";
282 };
283
284 &swport5 {
285 status = "okay";
286 };
287
288 &wifi0 {
289 status = "okay";
290
291 qcom,ath10k-calibration-variant = "MikroTik-hAP-ac2";
292 };
293
294 &wifi1 {
295 status = "okay";
296
297 qcom,ath10k-calibration-variant = "MikroTik-hAP-ac2";
298 };