GNU Linux-libre 4.9.309-gnu1
[releases.git] / arch / arm / boot / dts / am57xx-idk-common.dtsi
1 /*
2  * Copyright (C) 2015-2016 Texas Instruments Incorporated - http://www.ti.com/
3  *
4  * This program is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License version 2 as
6  * published by the Free Software Foundation.
7  */
8
9 #include "am57xx-industrial-grade.dtsi"
10
11 / {
12         aliases {
13                 rtc0 = &tps659038_rtc;
14                 rtc1 = &rtc;
15         };
16
17         vmain: fixedregulator-vmain {
18                 compatible = "regulator-fixed";
19                 regulator-name = "VMAIN";
20                 regulator-min-microvolt = <5000000>;
21                 regulator-max-microvolt = <5000000>;
22                 regulator-always-on;
23                 regulator-boot-on;
24         };
25
26         v3_3d: fixedregulator-v3_3d {
27                 compatible = "regulator-fixed";
28                 regulator-name = "V3_3D";
29                 vin-supply = <&smps9_reg>;
30                 regulator-min-microvolt = <3300000>;
31                 regulator-max-microvolt = <3300000>;
32                 regulator-always-on;
33                 regulator-boot-on;
34         };
35
36         vtt_fixed: fixedregulator-vtt {
37                 /* TPS51200 */
38                 compatible = "regulator-fixed";
39                 regulator-name = "vtt_fixed";
40                 vin-supply = <&v3_3d>;
41                 regulator-min-microvolt = <3300000>;
42                 regulator-max-microvolt = <3300000>;
43                 regulator-always-on;
44                 regulator-boot-on;
45         };
46 };
47
48 &i2c1 {
49         status = "okay";
50         clock-frequency = <400000>;
51
52         tps659038: tps659038@58 {
53                 compatible = "ti,tps659038";
54                 reg = <0x58>;
55                 interrupts-extended = <&gpio6 16 IRQ_TYPE_LEVEL_HIGH
56                                &dra7_pmx_core 0x418>;
57                 #interrupt-cells = <2>;
58                 interrupt-controller;
59                 ti,system-power-controller;
60                 ti,palmas-override-powerhold;
61
62                 tps659038_pmic {
63                         compatible = "ti,tps659038-pmic";
64
65                         smps12-in-supply = <&vmain>;
66                         smps3-in-supply = <&vmain>;
67                         smps45-in-supply = <&vmain>;
68                         smps6-in-supply = <&vmain>;
69                         smps7-in-supply = <&vmain>;
70                         smps8-in-supply = <&vmain>;
71                         smps9-in-supply = <&vmain>;
72                         ldo1-in-supply = <&vmain>;
73                         ldo2-in-supply = <&vmain>;
74                         ldo3-in-supply = <&vmain>;
75                         ldo4-in-supply = <&vmain>;
76                         ldo9-in-supply = <&vmain>;
77                         ldoln-in-supply = <&vmain>;
78                         ldousb-in-supply = <&vmain>;
79                         ldortc-in-supply = <&vmain>;
80
81                         regulators {
82                                 smps12_reg: smps12 {
83                                         /* VDD_MPU */
84                                         regulator-name = "smps12";
85                                         regulator-min-microvolt = <850000>;
86                                         regulator-max-microvolt = <1250000>;
87                                         regulator-always-on;
88                                         regulator-boot-on;
89                                 };
90
91                                 smps3_reg: smps3 {
92                                         /* VDD_DDR EMIF1 EMIF2 */
93                                         regulator-name = "smps3";
94                                         regulator-min-microvolt = <1350000>;
95                                         regulator-max-microvolt = <1350000>;
96                                         regulator-always-on;
97                                         regulator-boot-on;
98                                 };
99
100                                 smps45_reg: smps45 {
101                                         /* VDD_DSPEVE on AM572 */
102                                         /* VDD_IVA + VDD_DSP on AM571 */
103                                         regulator-name = "smps45";
104                                         regulator-min-microvolt = <850000>;
105                                         regulator-max-microvolt = <1250000>;
106                                         regulator-always-on;
107                                         regulator-boot-on;
108                                 };
109
110                                 smps6_reg: smps6 {
111                                         /* VDD_GPU */
112                                         regulator-name = "smps6";
113                                         regulator-min-microvolt = <850000>;
114                                         regulator-max-microvolt = <1250000>;
115                                         regulator-always-on;
116                                         regulator-boot-on;
117                                 };
118
119                                 smps7_reg: smps7 {
120                                         /* VDD_CORE */
121                                         regulator-name = "smps7";
122                                         regulator-min-microvolt = <850000>;
123                                         regulator-max-microvolt = <1150000>;
124                                         regulator-always-on;
125                                         regulator-boot-on;
126                                 };
127
128                                 smps8_reg: smps8 {
129                                         /* 5728 - VDD_IVAHD */
130                                         /* 5718 - N.C. test point */
131                                         regulator-name = "smps8";
132                                 };
133
134                                 smps9_reg: smps9 {
135                                         /* VDD_3_3D */
136                                         regulator-name = "smps9";
137                                         regulator-min-microvolt = <3300000>;
138                                         regulator-max-microvolt = <3300000>;
139                                         regulator-always-on;
140                                         regulator-boot-on;
141                                 };
142
143                                 ldo1_reg: ldo1 {
144                                         /* VDDSHV8 - VSDMMC  */
145                                         /* NOTE: on rev 1.3a, data supply */
146                                         regulator-name = "ldo1";
147                                         regulator-min-microvolt = <1800000>;
148                                         regulator-max-microvolt = <3300000>;
149                                         regulator-boot-on;
150                                         regulator-always-on;
151                                 };
152
153                                 ldo2_reg: ldo2 {
154                                         /* VDDSH18V */
155                                         regulator-name = "ldo2";
156                                         regulator-min-microvolt = <1800000>;
157                                         regulator-max-microvolt = <1800000>;
158                                         regulator-always-on;
159                                         regulator-boot-on;
160                                 };
161
162                                 ldo3_reg: ldo3 {
163                                         /* R1.3a 572x V1_8PHY_LDO3: USB, SATA */
164                                         regulator-name = "ldo3";
165                                         regulator-min-microvolt = <1800000>;
166                                         regulator-max-microvolt = <1800000>;
167                                         regulator-always-on;
168                                         regulator-boot-on;
169                                 };
170
171                                 ldo4_reg: ldo4 {
172                                         /* R1.3a 572x V1_8PHY_LDO4: PCIE, HDMI*/
173                                         regulator-name = "ldo4";
174                                         regulator-min-microvolt = <1800000>;
175                                         regulator-max-microvolt = <1800000>;
176                                         regulator-always-on;
177                                         regulator-boot-on;
178                                 };
179
180                                 /* LDO5-8 unused */
181
182                                 ldo9_reg: ldo9 {
183                                         /* VDD_RTC  */
184                                         regulator-name = "ldo9";
185                                         regulator-min-microvolt = <840000>;
186                                         regulator-max-microvolt = <1160000>;
187                                         regulator-always-on;
188                                         regulator-boot-on;
189                                 };
190
191                                 ldoln_reg: ldoln {
192                                         /* VDDA_1V8_PLL */
193                                         regulator-name = "ldoln";
194                                         regulator-min-microvolt = <1800000>;
195                                         regulator-max-microvolt = <1800000>;
196                                         regulator-always-on;
197                                         regulator-boot-on;
198                                 };
199
200                                 ldousb_reg: ldousb {
201                                         /* VDDA_3V_USB: VDDA_USBHS33 */
202                                         regulator-name = "ldousb";
203                                         regulator-min-microvolt = <3300000>;
204                                         regulator-max-microvolt = <3300000>;
205                                         regulator-always-on;
206                                         regulator-boot-on;
207                                 };
208
209                                 ldortc_reg: ldortc {
210                                         /* VDDA_RTC  */
211                                         regulator-name = "ldortc";
212                                         regulator-min-microvolt = <1800000>;
213                                         regulator-max-microvolt = <1800000>;
214                                         regulator-always-on;
215                                         regulator-boot-on;
216                                 };
217
218                                 regen1: regen1 {
219                                         /* VDD_3V3_ON */
220                                         regulator-name = "regen1";
221                                         regulator-boot-on;
222                                         regulator-always-on;
223                                 };
224
225                                 regen2: regen2 {
226                                         /* Needed for PMIC internal resource */
227                                         regulator-name = "regen2";
228                                         regulator-boot-on;
229                                         regulator-always-on;
230                                 };
231                         };
232                 };
233
234                 tps659038_rtc: tps659038_rtc {
235                         compatible = "ti,palmas-rtc";
236                         interrupt-parent = <&tps659038>;
237                         interrupts = <8 IRQ_TYPE_EDGE_FALLING>;
238                         wakeup-source;
239                 };
240
241                 tps659038_pwr_button: tps659038_pwr_button {
242                         compatible = "ti,palmas-pwrbutton";
243                         interrupt-parent = <&tps659038>;
244                         interrupts = <1 IRQ_TYPE_EDGE_FALLING>;
245                         wakeup-source;
246                         ti,palmas-long-press-seconds = <12>;
247                 };
248
249                 tps659038_gpio: tps659038_gpio {
250                         compatible = "ti,palmas-gpio";
251                         gpio-controller;
252                         #gpio-cells = <2>;
253                 };
254         };
255 };
256
257 &uart3 {
258         status = "okay";
259         interrupts-extended = <&crossbar_mpu GIC_SPI 69 IRQ_TYPE_LEVEL_HIGH
260                                &dra7_pmx_core 0x248>;
261 };
262
263 &rtc {
264         status = "okay";
265         ext-clk-src;
266 };
267
268 &mac {
269         status = "okay";
270         dual_emac;
271 };
272
273 &cpsw_emac0 {
274         phy_id = <&davinci_mdio>, <0>;
275         phy-mode = "rgmii";
276         dual_emac_res_vlan = <1>;
277 };
278
279 &cpsw_emac1 {
280         phy_id = <&davinci_mdio>, <1>;
281         phy-mode = "rgmii";
282         dual_emac_res_vlan = <2>;
283 };
284
285 &usb2_phy1 {
286         phy-supply = <&ldousb_reg>;
287 };
288
289 &usb2_phy2 {
290         phy-supply = <&ldousb_reg>;
291 };
292
293 &usb1 {
294         dr_mode = "host";
295 };
296
297 &usb2 {
298         dr_mode = "peripheral";
299 };
300
301 &mmc2 {
302         status = "okay";
303         vmmc-supply = <&v3_3d>;
304         bus-width = <8>;
305         ti,non-removable;
306         max-frequency = <96000000>;
307 };
308
309 &qspi {
310         status = "okay";
311
312         spi-max-frequency = <76800000>;
313         m25p80@0 {
314                 compatible = "s25fl256s1", "jedec,spi-nor";
315                 spi-max-frequency = <76800000>;
316                 reg = <0>;
317                 spi-tx-bus-width = <1>;
318                 spi-rx-bus-width = <4>;
319                 #address-cells = <1>;
320                 #size-cells = <1>;
321
322                 /* MTD partition table.
323                  * The ROM checks the first four physical blocks
324                  * for a valid file to boot and the flash here is
325                  * 64KiB block size.
326                  */
327                 partition@0 {
328                         label = "QSPI.SPL";
329                         reg = <0x00000000 0x000040000>;
330                 };
331                 partition@1 {
332                         label = "QSPI.u-boot";
333                         reg = <0x00040000 0x00100000>;
334                 };
335                 partition@2 {
336                         label = "QSPI.u-boot-spl-os";
337                         reg = <0x00140000 0x00080000>;
338                 };
339                 partition@3 {
340                         label = "QSPI.u-boot-env";
341                         reg = <0x001c0000 0x00010000>;
342                 };
343                 partition@4 {
344                         label = "QSPI.u-boot-env.backup1";
345                         reg = <0x001d0000 0x0010000>;
346                 };
347                 partition@5 {
348                         label = "QSPI.kernel";
349                         reg = <0x001e0000 0x0800000>;
350                 };
351                 partition@6 {
352                         label = "QSPI.file-system";
353                         reg = <0x009e0000 0x01620000>;
354                 };
355         };
356 };