b04a61dc0438ad24f6db5cf5f1904d57455b3fae
[oweals/openwrt.git] / target / linux / ipq40xx / files-4.19 / arch / arm / boot / dts / qcom-ipq4019-fritzbox-7530.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "qcom-ipq4019.dtsi"
4 #include <dt-bindings/gpio/gpio.h>
5 #include <dt-bindings/input/input.h>
6 #include <dt-bindings/soc/qcom,tcsr.h>
7
8 / {
9         model = "AVM FRITZ!Box 7530";
10         compatible = "avm,fritzbox-7530";
11
12         aliases {
13                 led-boot = &power_green;
14                 led-failsafe = &info_red;
15                 led-running = &power_green;
16                 led-upgrade = &info_green;
17         };
18
19         soc {
20                 rng@22000 {
21                         status = "okay";
22                 };
23
24                 mdio@90000 {
25                         status = "okay";
26                 };
27
28                 ess-psgmii@98000 {
29                         status = "okay";
30                 };
31
32                 tcsr@1949000 {
33                         compatible = "qcom,tcsr";
34                         reg = <0x1949000 0x100>;
35                         qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
36                 };
37
38                 tcsr@194b000 {
39                         compatible = "qcom,tcsr";
40                         reg = <0x194b000 0x100>;
41                         qcom,usb-hsphy-mode-select = <TCSR_USB_HSPHY_HOST_MODE>;
42                 };
43
44                 ess_tcsr@1953000 {
45                         compatible = "qcom,tcsr";
46                         reg = <0x1953000 0x1000>;
47                         qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
48                 };
49
50                 tcsr@1957000 {
51                         compatible = "qcom,tcsr";
52                         reg = <0x1957000 0x100>;
53                         qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
54                 };
55
56                 usb3@8af8800 {
57                         status = "okay";
58                 };
59
60                 crypto@8e3a000 {
61                         status = "okay";
62                 };
63
64                 watchdog@b017000 {
65                         status = "okay";
66                 };
67
68                 ess-switch@c000000 {
69                         status = "okay";
70                 };
71
72                 edma@c080000 {
73                         status = "okay";
74                         qcom,num_gmac = <1>;
75                 };
76         };
77
78         keys {
79                 compatible = "gpio-keys";
80
81                 wlan {
82                         label = "wlan";
83                         gpios = <&tlmm 42 GPIO_ACTIVE_LOW>;
84                         linux,code = <KEY_RFKILL>;
85                 };
86
87                 wps {
88                         label = "wps";
89                         gpios = <&tlmm 41 GPIO_ACTIVE_LOW>;
90                         linux,code = <KEY_WPS_BUTTON>;
91                 };
92
93                 dect {
94                         label = "dect";
95                         gpios = <&tlmm 43 GPIO_ACTIVE_LOW>;
96                         linux,code = <KEY_PHONE>;
97                 };
98         };
99
100         leds {
101                 compatible = "gpio-leds";
102
103                 info_red: info_red {
104                         label = "fritzbox-7530:red:info";
105                         gpios = <&tlmm 32 GPIO_ACTIVE_LOW>;
106                 };
107
108                 info_green: info {
109                         label = "fritzbox-7530:green:info";
110                         gpios = <&tlmm 33 GPIO_ACTIVE_LOW>;
111                 };
112
113                 wlan {
114                         label = "fritzbox-7530:green:wlan";
115                         gpios = <&tlmm 34 GPIO_ACTIVE_LOW>;
116                 };
117
118                 fon {
119                         label = "fritzbox-7530:green:fon";
120                         gpios = <&tlmm 35 GPIO_ACTIVE_LOW>;
121                 };
122
123                 power_green: power {
124                         label = "fritzbox-7530:green:power";
125                         gpios = <&tlmm 39 GPIO_ACTIVE_LOW>;
126                 };
127
128                 wps {
129                         label = "fritzbox-7530:green:wps";
130                         gpios = <&tlmm 45 GPIO_ACTIVE_LOW>;
131                 };
132         };
133 };
134
135 &tlmm {
136         serial_0_pins: serial_pinmux {
137                 mux {
138                         pins = "gpio16", "gpio17";
139                         function = "blsp_uart0";
140                         bias-disable;
141                 };
142         };
143
144         nand_pins: nand_pins {
145                 pullups {
146                         pins = "gpio53", "gpio58", "gpio59";
147                         function = "qpic";
148                         bias-pull-up;
149                 };
150
151                 pulldowns {
152                         pins = "gpio54", "gpio55", "gpio56",
153                                 "gpio57", "gpio60", "gpio61",
154                                 "gpio62", "gpio63", "gpio64",
155                                 "gpio65", "gpio66", "gpio67",
156                                 "gpio68", "gpio69";
157                         function = "qpic";
158                         bias-pull-down;
159                 };
160         };
161
162         usb-power {
163                 line-name = "enable USB3 power";
164                 gpios = <49 GPIO_ACTIVE_HIGH>;
165                 gpio-hog;
166                 output-high;
167         };
168 };
169
170 &nand {
171         pinctrl-0 = <&nand_pins>;
172         pinctrl-names = "default";
173         status = "okay";
174
175         nand@0 {
176                 partitions {
177                         compatible = "fixed-partitions";
178                         #address-cells = <1>;
179                         #size-cells = <1>;
180
181                         partition@0 {
182                                 label = "SBL1";
183                                 reg = <0x000000 0x80000>;
184                                 read-only;
185                         };
186
187                         partition@80000 {
188                                 label = "MIBIB";
189                                 reg = <0x080000 0x80000>;
190                                 read-only;
191                         };
192
193                         partition@100000 {
194                                 label = "QSEE";
195                                 reg = <0x100000 0x80000>;
196                                 read-only;
197                         };
198
199                         partition@180000 {
200                                 label = "CDT";
201                                 reg = <0x180000 0x40000>;
202                                 read-only;
203                         };
204
205                         partition@1c0000 {
206                                 label = "QSEE_B";
207                                 reg = <0x1c0000 0x80000>;
208                                 read-only;
209                         };
210
211                         partition@240000 {
212                                 label = "urlader0";
213                                 reg = <0x240000 0x40000>;
214                                 read-only;
215                         };
216
217                         partition@280000 {
218                                 label = "urlader1";
219                                 reg = <0x280000 0x40000>;
220                                 read-only;
221                         };
222
223                         partition@2c0000 {
224                                 label = "nand-tffs";
225                                 reg = <0x2c0000 0x840000>;
226                                 read-only;
227                         };
228
229                         partition@b00000 {
230                                 /* 'kernel1' in AVM firmware */
231                                 label = "uboot0";
232                                 reg = <0xb00000 0x400000>;
233                         };
234
235                         partition@f00000 {
236                                 /* 'kernel2' in AVM firmware */
237                                 label = "uboot1";
238                                 reg = <0xf00000 0x400000>;
239                         };
240
241                         partition@1300000 {
242                                 label = "ubi";
243                                 reg = <0x1300000 0x6d00000>;
244                         };
245                 };
246         };
247 };
248
249 &cryptobam {
250         status = "okay";
251 };
252
253 &blsp_dma {
254         status = "okay";
255 };
256
257 &blsp1_uart1 {
258         pinctrl-0 = <&serial_0_pins>;
259         pinctrl-names = "default";
260         status = "okay";
261 };
262
263 &usb3_ss_phy {
264         status = "okay";
265 };
266
267 &usb3_hs_phy {
268         status = "okay";
269 };
270
271 &qpic_bam {
272         status = "okay";
273 };
274
275 &wifi0 {
276         status = "okay";
277         qcom,ath10k-calibration-variant = "AVM-FRITZBox-7530";
278 };
279
280 &wifi1 {
281         status = "okay";
282         qcom,ath10k-calibration-variant = "AVM-FRITZBox-7530";
283 };
284
285 &pcie0 {
286         status = "okay";
287
288         perst-gpio = <&tlmm 38 GPIO_ACTIVE_LOW>;
289         wake-gpio = <&tlmm 50 GPIO_ACTIVE_LOW>;
290
291         bridge@0,0 {
292                 reg = <0x00000000 0 0 0 0>;
293                 #address-cells = <3>;
294                 #size-cells = <2>;
295                 ranges;
296
297                 dsl@1,0 {
298                         compatible = "intel,vrx518";
299                         status = "okay";
300                         reg = <0x00010000 0 0 0 0>;
301                 };
302         };
303 };