ipq40xx: device-tree overhaul
[openwrt/staging/jogo.git] / target / linux / ipq40xx / files-4.14 / arch / arm / boot / dts / qcom-ipq4028-wpj428.dts
1 /* Copyright (c) 2015, The Linux Foundation. All rights reserved.
2 * Copyright (c) 2017, Christian Mehlis <christian@m3hlis.de>
3 * Copyright (c) 2017-2018, Sven Eckelmann <sven.eckelmann@openmesh.com>
4 *
5 * Permission to use, copy, modify, and/or distribute this software for any
6 * purpose with or without fee is hereby granted, provided that the above
7 * copyright notice and this permission notice appear in all copies.
8 *
9 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16 *
17 */
18
19 #include "qcom-ipq4019.dtsi"
20 #include <dt-bindings/gpio/gpio.h>
21 #include <dt-bindings/input/input.h>
22 #include <dt-bindings/soc/qcom,tcsr.h>
23
24 / {
25 model = "Compex WPJ428";
26 compatible = "compex,wpj428", "qcom,ipq4019";
27
28 soc {
29 mdio@90000 {
30 status = "okay";
31 };
32
33 ess-psgmii@98000 {
34 status = "okay";
35 };
36
37 tcsr@194b000 {
38 /* select hostmode */
39 compatible = "qcom,tcsr";
40 reg = <0x194b000 0x100>;
41 qcom,usb-hsphy-mode-select = <TCSR_USB_HSPHY_HOST_MODE>;
42 status = "okay";
43 };
44
45 tcsr@1949000 {
46 compatible = "qcom,tcsr";
47 reg = <0x1949000 0x100>;
48 qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
49 };
50
51 ess_tcsr@1953000 {
52 compatible = "qcom,tcsr";
53 reg = <0x1953000 0x1000>;
54 qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
55 };
56
57 tcsr@1957000 {
58 compatible = "qcom,tcsr";
59 reg = <0x1957000 0x100>;
60 qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
61 };
62
63 usb2: usb2@60f8800 {
64 status = "okay";
65 };
66
67 usb3: usb3@8af8800 {
68 status = "okay";
69 };
70
71 crypto@8e3a000 {
72 status = "okay";
73 };
74
75 watchdog@b017000 {
76 status = "okay";
77 };
78
79 ess-switch@c000000 {
80 switch_lan_bmp = <0x10>;
81 switch_wan_bmp = <0x20>;
82
83 status = "okay";
84 };
85
86 edma@c080000 {
87 status = "okay";
88 };
89 };
90
91 gpio-keys {
92 compatible = "gpio-keys";
93
94 reset {
95 label = "reset";
96 gpios = <&tlmm 63 GPIO_ACTIVE_LOW>;
97 linux,code = <KEY_RESTART>;
98 };
99 };
100
101 aliases {
102 led-boot = &status;
103 led-failsafe = &status;
104 led-upgrade = &status;
105 };
106
107 gpio-leds {
108 compatible = "gpio-leds";
109
110 status: rss4 {
111 label = "wpj428:green:rss4";
112 gpios = <&tlmm 5 GPIO_ACTIVE_HIGH>;
113 default-state = "off";
114 };
115
116 rss3 {
117 label = "wpj428:green:rss3";
118 gpios = <&tlmm 4 GPIO_ACTIVE_HIGH>;
119 default-state = "off";
120 };
121 };
122
123 beeper: beeper {
124 compatible = "gpio-beeper";
125 gpios = <&tlmm 58 GPIO_ACTIVE_HIGH>;
126 };
127 };
128
129 &tlmm {
130 serial_pins: serial_pinmux {
131 mux {
132 pins = "gpio60", "gpio61";
133 function = "blsp_uart0";
134 bias-disable;
135 };
136 };
137
138 spi_0_pins: spi_0_pinmux {
139 pin {
140 function = "blsp_spi0";
141 pins = "gpio55", "gpio56", "gpio57";
142 drive-strength = <12>;
143 bias-disable;
144 };
145 pin_cs {
146 function = "gpio";
147 pins = "gpio54";
148 drive-strength = <2>;
149 bias-disable;
150 output-high;
151 };
152 };
153 };
154
155 &blsp_dma {
156 status = "okay";
157 };
158
159 &blsp1_spi1 {
160 pinctrl-0 = <&spi_0_pins>;
161 pinctrl-names = "default";
162 status = "okay";
163 cs-gpios = <&tlmm 54 GPIO_ACTIVE_HIGH>;
164
165 m25p80@0 {
166 #address-cells = <1>;
167 #size-cells = <1>;
168 compatible = "jedec,spi-nor";
169 reg = <0>;
170 spi-max-frequency = <24000000>;
171
172 partitions {
173 compatible = "fixed-partitions";
174 #address-cells = <1>;
175 #size-cells = <1>;
176
177 partition0@0 {
178 label = "0:SBL1";
179 reg = <0x00000000 0x00040000>;
180 read-only;
181 };
182 partition1@40000 {
183 label = "0:MIBIB";
184 reg = <0x00040000 0x00020000>;
185 read-only;
186 };
187 partition2@60000 {
188 label = "0:QSEE";
189 reg = <0x00060000 0x00060000>;
190 read-only;
191 };
192 partition3@c0000 {
193 label = "0:CDT";
194 reg = <0x000c0000 0x00010000>;
195 read-only;
196 };
197 partition4@d0000 {
198 label = "0:DDRPARAMS";
199 reg = <0x000d0000 0x00010000>;
200 read-only;
201 };
202 partition5@e0000 {
203 label = "0:APPSBLENV"; /* uboot env*/
204 reg = <0x000e0000 0x00010000>;
205 read-only;
206 };
207 partition5@f0000 {
208 label = "0:APPSBL"; /* uboot */
209 reg = <0x000f0000 0x00080000>;
210 read-only;
211 };
212 partition5@170000 {
213 label = "0:ART";
214 reg = <0x00170000 0x00010000>;
215 read-only;
216 };
217 partition6@180000 {
218 compatible = "denx,fit";
219 label = "firmware";
220 reg = <0x00180000 0x01e80000>;
221 };
222 };
223 };
224 };
225
226 &blsp1_uart1 {
227 pinctrl-0 = <&serial_pins>;
228 pinctrl-names = "default";
229 status = "okay";
230 };
231
232 &cryptobam {
233 status = "okay";
234 };
235
236 &gmac0 {
237 qcom,phy_mdio_addr = <4>;
238 qcom,poll_required = <1>;
239 qcom,forced_speed = <1000>;
240 qcom,forced_duplex = <1>;
241 vlan_tag = <2 0x20>;
242 };
243
244 &gmac1 {
245 qcom,phy_mdio_addr = <3>;
246 qcom,poll_required = <1>;
247 qcom,forced_speed = <1000>;
248 qcom,forced_duplex = <1>;
249 vlan_tag = <1 0x10>;
250 };
251
252 &usb3_ss_phy {
253 status = "okay";
254 };
255
256 &usb3_hs_phy {
257 status = "okay";
258 };
259
260 &usb2_hs_phy {
261 status = "okay";
262 };
263
264 &wifi0 {
265 status = "okay";
266 };
267
268 &wifi1 {
269 status = "okay";
270 };