ipq806x: add ipq4019 support
[openwrt/openwrt.git] / target / linux / ipq806x / files-4.9 / arch / arm / boot / dts / qcom-ipq4019-fritz4040.dts
1 /* Copyright (c) 2015, The Linux Foundation. All rights reserved.
2 *
3 * Permission to use, copy, modify, and/or distribute this software for any
4 * purpose with or without fee is hereby granted, provided that the above
5 * copyright notice and this permission notice appear in all copies.
6 *
7 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
8 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
9 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
10 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
11 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
12 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
13 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
14 *
15 */
16
17 #include "qcom-ipq4019-ap.dk01.1.dtsi"
18 #include "qcom-ipq4019-bus.dtsi"
19 #include <dt-bindings/gpio/gpio.h>
20 #include <dt-bindings/input/input.h>
21 #include <dt-bindings/soc/qcom,tcsr.h>
22
23 / {
24 model = "AVM FRITZ!Box 4040";
25 compatible = "avm,fritzbox-4040", "qcom,ipq4019";
26
27 reserved-memory {
28 #address-cells = <0x1>;
29 #size-cells = <0x1>;
30 ranges;
31
32 rsvd1@87000000 {
33 reg = <0x87000000 0x500000>;
34 no-map;
35 };
36
37 wifi_dump@87500000 {
38 reg = <0x87500000 0x600000>;
39 no-map;
40 };
41
42 rsvd2@87B00000 {
43 reg = <0x87b00000 0x500000>;
44 no-map;
45 };
46 };
47 /*
48 This also works. Maybe it could be smaller still.
49
50 reserved-memory {
51 #address-cells = <0x1>;
52 #size-cells = <0x1>;
53 ranges;
54
55 rsvd1@87E00000 {
56 reg = <0x87e00000 0x200000>;
57 no-map;
58 };
59 };
60 */
61
62 soc {
63 tcsr@194b000 {
64 /* select hostmode */
65 compatible = "qcom,tcsr";
66 reg = <0x194b000 0x100>;
67 qcom,usb-hsphy-mode-select = <TCSR_USB_HSPHY_HOST_MODE>;
68 status = "ok";
69 };
70
71 ess_tcsr@1953000 {
72 compatible = "qcom,tcsr";
73 reg = <0x1953000 0x1000>;
74 qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
75 };
76
77
78 tcsr@1949000 {
79 compatible = "qcom,tcsr";
80 reg = <0x1949000 0x100>;
81 qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
82 };
83
84 tcsr@1957000 {
85 compatible = "qcom,tcsr";
86 reg = <0x1957000 0x100>;
87 qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
88 };
89
90 counter@4a1000 {
91 compatible = "qcom,qca-gcnt";
92 reg = <0x4a1000 0x4>;
93 };
94
95 mdio@90000 {
96 status = "okay";
97 };
98
99 qca8075: ess-switch@c000000 {
100 status = "okay";
101
102 #gpio-cells = <2>;
103 gpio-controller;
104
105 enable-usb-power {
106 gpio-hog;
107 line-name = "enable USB3 power";
108 gpios = <0x7 GPIO_ACTIVE_HIGH>;
109 output-high;
110 };
111 };
112
113 ess-psgmii@98000 {
114 status = "okay";
115 };
116
117 edma@c080000 {
118 status = "okay";
119 };
120
121 wifi@a000000 {
122 status = "okay";
123 };
124
125 wifi@a800000 {
126 status = "okay";
127 };
128
129 cryptobam: dma@8e04000 {
130 status = "okay";
131 };
132
133 crypto@8e3a000 {
134 status = "okay";
135 };
136 };
137
138 gpio-keys {
139 compatible = "gpio-keys";
140
141 wlan {
142 label = "wlan";
143 gpios = <&tlmm 0x3a GPIO_ACTIVE_LOW>;
144 linux,code = <KEY_RFKILL>;
145 };
146
147 wps {
148 label = "wps";
149 gpios = <&tlmm 63 GPIO_ACTIVE_LOW>;
150 linux,code = <KEY_WPS_BUTTON>;
151 };
152 };
153
154 aliases {
155 led-boot = &power;
156 led-failsafe = &flash;
157 led-running = &power;
158 led-upgrade = &flash;
159 };
160
161 gpio-leds {
162 compatible = "gpio-leds";
163
164 wlan {
165 label = "fritz4040:green:wlan";
166 gpios = <&qca8075 0x1 GPIO_ACTIVE_HIGH>;
167 };
168
169 panic: info_red {
170 label = "fritz4040:red:info";
171 gpios = <&qca8075 0x3 GPIO_ACTIVE_HIGH>;
172 panic-indicator;
173 };
174
175 wan {
176 label = "fritz4040:green:wan";
177 gpios = <&qca8075 0x5 GPIO_ACTIVE_HIGH>;
178 };
179
180 power: power {
181 label = "fritz4040:green:power";
182 gpios = <&qca8075 0xb GPIO_ACTIVE_HIGH>;
183 };
184
185 lan {
186 label = "fritz4040:green:lan";
187 gpios = <&qca8075 0xd GPIO_ACTIVE_HIGH>;
188 };
189
190 flash: info_amber {
191 label = "fritz4040:amber:info";
192 gpios = <&qca8075 0xf GPIO_ACTIVE_HIGH>;
193 };
194 };
195 };
196
197 &spi_0 { /* BLSP1 QUP1 */
198 status = "ok";
199
200 mx25l25635e@0 {
201 status = "disabled";
202 };
203
204 mx25l25635f@0 {
205 compatible = "mx25l25635f", "jedec,spi-nor";
206 #address-cells = <1>;
207 #size-cells = <0>;
208 reg = <0>;
209 spi-max-frequency = <24000000>;
210 status = "ok";
211 m25p,fast-read;
212
213 partitions {
214 compatible = "fixed-partitions";
215 #address-cells = <1>;
216 #size-cells = <1>;
217
218 partition0@0 {
219 label = "SBL1";
220 reg = <0x00000000 0x00040000>;
221 read-only;
222 };
223 partition1@40000 {
224 label = "MIBIB";
225 reg = <0x00040000 0x00020000>;
226 read-only;
227 };
228 partition2@60000 {
229 label = "QSEE";
230 reg = <0x00060000 0x00060000>;
231 read-only;
232 };
233 partition3@c0000 {
234 label = "CDT";
235 reg = <0x000c0000 0x00010000>;
236 read-only;
237 };
238 partition4@d0000 {
239 label = "DDRPARAMS";
240 reg = <0x000d0000 0x00010000>;
241 read-only;
242 };
243 partition5@e0000 {
244 label = "APPSBLENV"; /* uboot env - empty */
245 reg = <0x000e0000 0x00010000>;
246 read-only;
247 };
248 partition6@f0000 {
249 label = "urlader"; /* APPSBL */
250 reg = <0x000f0000 0x0002dc000>;
251 read-only;
252 };
253 partition7@11dc00 {
254 /* make a backup of this partition! */
255 label = "urlader_config";
256 reg = <0x0011dc00 0x00002400>;
257 read-only;
258 };
259 partition8@120000 {
260 label = "tffs1";
261 reg = <0x00120000 0x00080000>;
262 read-only;
263 };
264 partition9@1a0000 {
265 label = "tffs2";
266 reg = <0x001a0000 0x00080000>;
267 read-only;
268 };
269 partition10@220000 {
270 label = "uboot";
271 reg = <0x00220000 0x00080000>;
272 read-only;
273 };
274 partition11@2A0000 {
275 label = "image"; /* firmware */
276 reg = <0x002A0000 0x01C60000>;
277 };
278 partition12@1f00000 {
279 label = "jffs2";
280 reg = <0x01F00000 0x00100000>;
281 };
282 };
283 };
284 };
285
286 &cpu0_opp_table {
287 /delete-node/ opp@666000000;
288
289 opp@710000000 {
290 opp-hz = /bits/ 64 <710000000>;
291 clock-latency-ns = <256000>;
292 };
293 };