GNU Linux-libre 4.19.286-gnu1
[releases.git] / arch / arm / boot / dts / da850-evm.dts
1 /*
2  * Device Tree for DA850 EVM board
3  *
4  * Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com/
5  *
6  * This program is free software; you can redistribute  it and/or modify it
7  * under  the terms of  the GNU General  Public License as published by the
8  * Free Software Foundation, version 2.
9  */
10 /dts-v1/;
11 #include "da850.dtsi"
12 #include <dt-bindings/gpio/gpio.h>
13
14 / {
15         compatible = "ti,da850-evm", "ti,da850";
16         model = "DA850/AM1808/OMAP-L138 EVM";
17
18         chosen {
19                 stdout-path = &serial2;
20         };
21
22         aliases {
23                 serial0 = &serial0;
24                 serial1 = &serial1;
25                 serial2 = &serial2;
26                 ethernet0 = &eth0;
27                 spi0 = &spi1;
28         };
29
30         backlight: backlight-pwm {
31                 pinctrl-names = "default";
32                 pinctrl-0 = <&ecap2_pins>;
33                 power-supply = <&backlight_lcd>;
34                 compatible = "pwm-backlight";
35                 /*
36                  * The PWM here corresponds to production hardware. The
37                  * schematic needs to be 1015171 (15 March 2010), Rev A
38                  * or newer.
39                  */
40                 pwms = <&ecap2 0 50000 0>;
41                 brightness-levels = <0 10 20 30 40 50 60 70 80 90 99>;
42                 default-brightness-level = <7>;
43         };
44
45         panel {
46                 compatible = "ti,tilcdc,panel";
47                 pinctrl-names = "default";
48                 pinctrl-0 = <&lcd_pins>;
49                 /*
50                  * The vpif and the LCD are mutually exclusive.
51                  * To enable VPIF, change the status below to 'disabled' then
52                  * then change the status of the vpif below to 'okay'
53                  */
54                 status = "okay";
55                 enable-gpios = <&gpio 40 GPIO_ACTIVE_HIGH>; /* lcd_panel_pwr */
56
57                 panel-info {
58                         ac-bias         = <255>;
59                         ac-bias-intrpt  = <0>;
60                         dma-burst-sz    = <16>;
61                         bpp             = <16>;
62                         fdd             = <0x80>;
63                         sync-edge       = <0>;
64                         sync-ctrl       = <1>;
65                         raster-order    = <0>;
66                         fifo-th         = <0>;
67                 };
68
69                 display-timings {
70                         native-mode = <&timing0>;
71                         timing0: 480x272 {
72                                 clock-frequency = <9000000>;
73                                 hactive = <480>;
74                                 vactive = <272>;
75                                 hfront-porch = <3>;
76                                 hback-porch = <2>;
77                                 hsync-len = <42>;
78                                 vback-porch = <3>;
79                                 vfront-porch = <4>;
80                                 vsync-len = <11>;
81                                 hsync-active = <0>;
82                                 vsync-active = <0>;
83                                 de-active = <1>;
84                                 pixelclk-active = <1>;
85                         };
86                 };
87         };
88
89         vbat: fixedregulator0 {
90                 compatible = "regulator-fixed";
91                 regulator-name = "vbat";
92                 regulator-min-microvolt = <5000000>;
93                 regulator-max-microvolt = <5000000>;
94                 regulator-boot-on;
95         };
96
97         baseboard_3v3: fixedregulator-3v3 {
98                 /* TPS73701DCQ */
99                 compatible = "regulator-fixed";
100                 regulator-name = "baseboard_3v3";
101                 regulator-min-microvolt = <3300000>;
102                 regulator-max-microvolt = <3300000>;
103                 vin-supply = <&vbat>;
104                 regulator-always-on;
105                 regulator-boot-on;
106         };
107
108         baseboard_1v8: fixedregulator-1v8 {
109                 /* TPS73701DCQ */
110                 compatible = "regulator-fixed";
111                 regulator-name = "baseboard_1v8";
112                 regulator-min-microvolt = <1800000>;
113                 regulator-max-microvolt = <1800000>;
114                 vin-supply = <&vbat>;
115                 regulator-always-on;
116                 regulator-boot-on;
117         };
118
119         backlight_lcd: backlight-regulator {
120                 compatible = "regulator-fixed";
121                 regulator-name = "lcd_backlight_pwr";
122                 regulator-min-microvolt = <3300000>;
123                 regulator-max-microvolt = <3300000>;
124                 gpio = <&gpio 47 GPIO_ACTIVE_HIGH>; /* lcd_backlight_pwr */
125                 enable-active-high;
126         };
127
128         sound {
129                 compatible = "simple-audio-card";
130                 simple-audio-card,name = "DA850-OMAPL138 EVM";
131                 simple-audio-card,widgets =
132                         "Line", "Line In",
133                         "Line", "Line Out";
134                 simple-audio-card,routing =
135                         "LINE1L", "Line In",
136                         "LINE1R", "Line In",
137                         "Line Out", "LLOUT",
138                         "Line Out", "RLOUT";
139                 simple-audio-card,format = "dsp_b";
140                 simple-audio-card,bitclock-master = <&link0_codec>;
141                 simple-audio-card,frame-master = <&link0_codec>;
142                 simple-audio-card,bitclock-inversion;
143
144                 simple-audio-card,cpu {
145                         sound-dai = <&mcasp0>;
146                         system-clock-frequency = <24576000>;
147                 };
148
149                 link0_codec: simple-audio-card,codec {
150                         sound-dai = <&tlv320aic3106>;
151                         system-clock-frequency = <24576000>;
152                 };
153         };
154 };
155
156 &ecap2 {
157         status = "okay";
158 };
159
160 &ref_clk {
161         clock-frequency = <24000000>;
162 };
163
164 &pmx_core {
165         status = "okay";
166
167         mcasp0_pins: pinmux_mcasp0_pins {
168                 pinctrl-single,bits = <
169                         /*
170                          * AHCLKX, ACLKX, AFSX, AHCLKR, ACLKR,
171                          * AFSR, AMUTE
172                          */
173                         0x00 0x11111111 0xffffffff
174                         /* AXR11, AXR12 */
175                         0x04 0x00011000 0x000ff000
176                 >;
177         };
178         nand_pins: nand_pins {
179                 pinctrl-single,bits = <
180                         /* EMA_WAIT[0], EMA_OE, EMA_WE, EMA_CS[4], EMA_CS[3] */
181                         0x1c 0x10110110  0xf0ff0ff0
182                         /*
183                          * EMA_D[0], EMA_D[1], EMA_D[2],
184                          * EMA_D[3], EMA_D[4], EMA_D[5],
185                          * EMA_D[6], EMA_D[7]
186                          */
187                         0x24 0x11111111  0xffffffff
188                         /* EMA_A[1], EMA_A[2] */
189                         0x30 0x01100000  0x0ff00000
190                 >;
191         };
192 };
193
194 &sata {
195         status = "okay";
196 };
197
198 &serial0 {
199         status = "okay";
200 };
201
202 &serial1 {
203         status = "okay";
204 };
205
206 &serial2 {
207         status = "okay";
208 };
209
210 &rtc0 {
211         status = "okay";
212 };
213
214 &lcdc {
215         status = "okay";
216 };
217
218 &i2c0 {
219         status = "okay";
220         clock-frequency = <100000>;
221         pinctrl-names = "default";
222         pinctrl-0 = <&i2c0_pins>;
223
224         tps: tps@48 {
225                 reg = <0x48>;
226         };
227         tlv320aic3106: tlv320aic3106@18 {
228                 #sound-dai-cells = <0>;
229                 compatible = "ti,tlv320aic3106";
230                 reg = <0x18>;
231                 status = "okay";
232
233                 /* Regulators */
234                 IOVDD-supply = <&vdcdc2_reg>;
235                 AVDD-supply = <&baseboard_3v3>;
236                 DRVDD-supply = <&baseboard_3v3>;
237                 DVDD-supply = <&baseboard_1v8>;
238         };
239         tca6416: gpio@20 {
240                 compatible = "ti,tca6416";
241                 reg = <0x20>;
242                 gpio-controller;
243                 #gpio-cells = <2>;
244         };
245 };
246
247 &wdt {
248         status = "okay";
249 };
250
251 &mmc0 {
252         max-frequency = <50000000>;
253         bus-width = <4>;
254         status = "okay";
255         pinctrl-names = "default";
256         pinctrl-0 = <&mmc0_pins>;
257         cd-gpios = <&gpio 64 GPIO_ACTIVE_LOW>;
258         wp-gpios = <&gpio 65 GPIO_ACTIVE_HIGH>;
259 };
260
261 &spi1 {
262         status = "okay";
263         pinctrl-names = "default";
264         pinctrl-0 = <&spi1_pins &spi1_cs0_pin>;
265         flash: m25p80@0 {
266                 #address-cells = <1>;
267                 #size-cells = <1>;
268                 compatible = "m25p64";
269                 spi-max-frequency = <30000000>;
270                 m25p,fast-read;
271                 reg = <0>;
272                 partition@0 {
273                         label = "U-Boot-SPL";
274                         reg = <0x00000000 0x00010000>;
275                         read-only;
276                 };
277                 partition@1 {
278                         label = "U-Boot";
279                         reg = <0x00010000 0x00080000>;
280                         read-only;
281                 };
282                 partition@2 {
283                         label = "U-Boot-Env";
284                         reg = <0x00090000 0x00010000>;
285                         read-only;
286                 };
287                 partition@3 {
288                         label = "Kernel";
289                         reg = <0x000a0000 0x00280000>;
290                 };
291                 partition@4 {
292                         label = "Filesystem";
293                         reg = <0x00320000 0x00400000>;
294                 };
295                 partition@5 {
296                         label = "MAC-Address";
297                         reg = <0x007f0000 0x00010000>;
298                         read-only;
299                 };
300         };
301 };
302
303 &mdio {
304         status = "okay";
305         pinctrl-names = "default";
306         pinctrl-0 = <&mdio_pins>;
307         bus_freq = <2200000>;
308 };
309
310 &eth0 {
311         status = "okay";
312         pinctrl-names = "default";
313         pinctrl-0 = <&mii_pins>;
314 };
315
316 &gpio {
317         status = "okay";
318 };
319
320 /include/ "tps6507x.dtsi"
321
322 &tps {
323         vdcdc1_2-supply = <&vbat>;
324         vdcdc3-supply = <&vbat>;
325         vldo1_2-supply = <&vbat>;
326
327         regulators {
328                 vdcdc1_reg: regulator@0 {
329                         regulator-name = "VDCDC1_3.3V";
330                         regulator-min-microvolt = <3150000>;
331                         regulator-max-microvolt = <3450000>;
332                         regulator-always-on;
333                         regulator-boot-on;
334                 };
335
336                 vdcdc2_reg: regulator@1 {
337                         regulator-name = "VDCDC2_3.3V";
338                         regulator-min-microvolt = <1710000>;
339                         regulator-max-microvolt = <3450000>;
340                         regulator-always-on;
341                         regulator-boot-on;
342                         ti,defdcdc_default = <1>;
343                 };
344
345                 vdcdc3_reg: regulator@2 {
346                         regulator-name = "VDCDC3_1.2V";
347                         regulator-min-microvolt = <950000>;
348                         regulator-max-microvolt = <1350000>;
349                         regulator-always-on;
350                         regulator-boot-on;
351                         ti,defdcdc_default = <1>;
352                 };
353
354                 ldo1_reg: regulator@3 {
355                         regulator-name = "LDO1_1.8V";
356                         regulator-min-microvolt = <1710000>;
357                         regulator-max-microvolt = <1890000>;
358                         regulator-always-on;
359                         regulator-boot-on;
360                 };
361
362                 ldo2_reg: regulator@4 {
363                         regulator-name = "LDO2_1.2V";
364                         regulator-min-microvolt = <1140000>;
365                         regulator-max-microvolt = <1320000>;
366                         regulator-always-on;
367                         regulator-boot-on;
368                 };
369         };
370 };
371
372 &mcasp0 {
373         #sound-dai-cells = <0>;
374         status = "okay";
375         pinctrl-names = "default";
376         pinctrl-0 = <&mcasp0_pins>;
377
378         op-mode = <0>;          /* MCASP_IIS_MODE */
379         tdm-slots = <2>;
380         /* 4 serializer */
381         serial-dir = <  /* 0: INACTIVE, 1: TX, 2: RX */
382                 0 0 0 0
383                 0 0 0 0
384                 0 0 0 1
385                 2 0 0 0
386         >;
387         tx-num-evt = <32>;
388         rx-num-evt = <32>;
389 };
390
391 &edma0 {
392         ti,edma-reserved-slot-ranges = <32 50>;
393 };
394
395 &edma1 {
396         ti,edma-reserved-slot-ranges = <32 90>;
397 };
398
399 &aemif {
400         pinctrl-names = "default";
401         pinctrl-0 = <&nand_pins>;
402         status = "ok";
403         cs3 {
404                 #address-cells = <2>;
405                 #size-cells = <1>;
406                 clock-ranges;
407                 ranges;
408
409                 ti,cs-chipselect = <3>;
410
411                 nand@2000000,0 {
412                         compatible = "ti,davinci-nand";
413                         #address-cells = <1>;
414                         #size-cells = <1>;
415                         reg = <0 0x02000000 0x02000000
416                                1 0x00000000 0x00008000>;
417
418                         ti,davinci-chipselect = <1>;
419                         ti,davinci-mask-ale = <0>;
420                         ti,davinci-mask-cle = <0>;
421                         ti,davinci-mask-chipsel = <0>;
422                         ti,davinci-ecc-mode = "hw";
423                         ti,davinci-ecc-bits = <4>;
424                         ti,davinci-nand-use-bbt;
425                 };
426         };
427 };
428
429 &usb_phy {
430         status = "okay";
431 };
432
433 &usb0 {
434         status = "okay";
435 };
436
437 &usb1 {
438         status = "okay";
439 };
440
441 &vpif {
442         pinctrl-names = "default";
443         pinctrl-0 = <&vpif_capture_pins>, <&vpif_display_pins>;
444         /*
445          * The vpif and the LCD are mutually exclusive.
446          * To enable VPIF, disable the ti,tilcdc,panel then
447          * change the status below to 'okay'
448          */
449         status = "disabled";
450 };