a5bfa7e5ae2453dd90832c9957c2263a2ddc276b
[openwrt/staging/wigyori.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
22 / {
23 model = "AVM FRITZ!Box 4040";
24 compatible = "avm,fritzbox-4040", "qcom,ipq4019";
25
26 reserved-memory {
27 #address-cells = <0x1>;
28 #size-cells = <0x1>;
29 ranges;
30
31 rsvd1@87000000 {
32 reg = <0x87000000 0x500000>;
33 no-map;
34 };
35
36 wifi_dump@87500000 {
37 reg = <0x87500000 0x600000>;
38 no-map;
39 };
40
41 rsvd2@87B00000 {
42 reg = <0x87b00000 0x500000>;
43 no-map;
44 };
45 };
46 /*
47 This also works. Maybe it could be smaller still.
48
49 reserved-memory {
50 #address-cells = <0x1>;
51 #size-cells = <0x1>;
52 ranges;
53
54 rsvd1@87E00000 {
55 reg = <0x87e00000 0x200000>;
56 no-map;
57 };
58 };
59 */
60
61 soc {
62 qca8075: ess-switch@c000000 {
63 status = "okay";
64
65 #gpio-cells = <2>;
66 gpio-controller;
67
68 enable-usb-power {
69 gpio-hog;
70 line-name = "enable USB3 power";
71 gpios = <0x7 GPIO_ACTIVE_HIGH>;
72 output-high;
73 };
74 };
75 };
76
77 gpio-keys {
78 compatible = "gpio-keys";
79
80 wlan {
81 label = "wlan";
82 gpios = <&tlmm 0x3a GPIO_ACTIVE_LOW>;
83 linux,code = <KEY_RFKILL>;
84 };
85
86 wps {
87 label = "wps";
88 gpios = <&tlmm 63 GPIO_ACTIVE_LOW>;
89 linux,code = <KEY_WPS_BUTTON>;
90 };
91 };
92
93 aliases {
94 led-boot = &power;
95 led-failsafe = &flash;
96 led-running = &power;
97 led-upgrade = &flash;
98 };
99
100 gpio-leds {
101 compatible = "gpio-leds";
102
103 wlan {
104 label = "fritz4040:green:wlan";
105 gpios = <&qca8075 0x1 GPIO_ACTIVE_HIGH>;
106 };
107
108 panic: info_red {
109 label = "fritz4040:red:info";
110 gpios = <&qca8075 0x3 GPIO_ACTIVE_HIGH>;
111 panic-indicator;
112 };
113
114 wan {
115 label = "fritz4040:green:wan";
116 gpios = <&qca8075 0x5 GPIO_ACTIVE_HIGH>;
117 };
118
119 power: power {
120 label = "fritz4040:green:power";
121 gpios = <&qca8075 0xb GPIO_ACTIVE_HIGH>;
122 };
123
124 lan {
125 label = "fritz4040:green:lan";
126 gpios = <&qca8075 0xd GPIO_ACTIVE_HIGH>;
127 };
128
129 flash: info_amber {
130 label = "fritz4040:amber:info";
131 gpios = <&qca8075 0xf GPIO_ACTIVE_HIGH>;
132 };
133 };
134 };
135
136 &spi_0 { /* BLSP1 QUP1 */
137 status = "ok";
138
139 mx25l25635e@0 {
140 status = "disabled";
141 };
142
143 mx25l25635f@0 {
144 compatible = "mx25l25635f", "jedec,spi-nor";
145 #address-cells = <1>;
146 #size-cells = <0>;
147 reg = <0>;
148 spi-max-frequency = <24000000>;
149 status = "ok";
150 m25p,fast-read;
151
152 partitions {
153 compatible = "fixed-partitions";
154 #address-cells = <1>;
155 #size-cells = <1>;
156
157 partition0@0 {
158 label = "SBL1";
159 reg = <0x00000000 0x00040000>;
160 read-only;
161 };
162 partition1@40000 {
163 label = "MIBIB";
164 reg = <0x00040000 0x00020000>;
165 read-only;
166 };
167 partition2@60000 {
168 label = "QSEE";
169 reg = <0x00060000 0x00060000>;
170 read-only;
171 };
172 partition3@c0000 {
173 label = "CDT";
174 reg = <0x000c0000 0x00010000>;
175 read-only;
176 };
177 partition4@d0000 {
178 label = "DDRPARAMS";
179 reg = <0x000d0000 0x00010000>;
180 read-only;
181 };
182 partition5@e0000 {
183 label = "APPSBLENV"; /* uboot env - empty */
184 reg = <0x000e0000 0x00010000>;
185 read-only;
186 };
187 partition6@f0000 {
188 label = "urlader"; /* APPSBL */
189 reg = <0x000f0000 0x0002dc000>;
190 read-only;
191 };
192 partition7@11dc00 {
193 /* make a backup of this partition! */
194 label = "urlader_config";
195 reg = <0x0011dc00 0x00002400>;
196 read-only;
197 };
198 partition8@120000 {
199 label = "tffs1";
200 reg = <0x00120000 0x00080000>;
201 read-only;
202 };
203 partition9@1a0000 {
204 label = "tffs2";
205 reg = <0x001a0000 0x00080000>;
206 read-only;
207 };
208 partition10@220000 {
209 label = "uboot";
210 reg = <0x00220000 0x00080000>;
211 read-only;
212 };
213 partition11@2A0000 {
214 label = "firmware";
215 reg = <0x002A0000 0x01C60000>;
216 };
217 partition12@1f00000 {
218 label = "jffs2";
219 reg = <0x01F00000 0x00100000>;
220 };
221 };
222 };
223 };
224
225 &cpu0_opp_table {
226 /delete-node/ opp@666000000;
227
228 opp@710000000 {
229 opp-hz = /bits/ 64 <710000000>;
230 clock-latency-ns = <256000>;
231 };
232 };