blob: c2b4f65b904e050e66ca9e6ce911efd893682743 [file] [log] [blame]
Magnus Damm3cc828f2013-03-29 17:49:37 +09001/*
2 * Device Tree Source for the Lager board
3 *
Sergei Shtylyovda4ea952014-02-20 02:22:31 +03004 * Copyright (C) 2013-2014 Renesas Solutions Corp.
5 * Copyright (C) 2014 Cogent Embedded, Inc.
Magnus Damm3cc828f2013-03-29 17:49:37 +09006 *
7 * This file is licensed under the terms of the GNU General Public License
8 * version 2. This program is licensed "as is" without any warranty of any
9 * kind, whether express or implied.
10 */
11
Kuninori Morimoto8ea7a44a2014-11-03 17:47:56 -080012/*
13 * SSI-AK4643
14 *
15 * SW1: 1: AK4643
16 * 2: CN22
17 * 3: ADV7511
18 *
19 * This command is required when Playback/Capture
20 *
21 * amixer set "LINEOUT Mixer DACL" on
22 */
23
Magnus Damm3cc828f2013-03-29 17:49:37 +090024/dts-v1/;
Laurent Pinchart31c46cb2013-11-09 13:23:53 +010025#include "r8a7790.dtsi"
Laurent Pinchart39fa5112013-12-11 15:13:47 +010026#include <dt-bindings/gpio/gpio.h>
Magnus Dammf7dcd382014-03-18 21:57:48 +090027#include <dt-bindings/input/input.h>
Magnus Damm3cc828f2013-03-29 17:49:37 +090028
29/ {
30 model = "Lager";
31 compatible = "renesas,lager", "renesas,r8a7790";
32
Laurent Pinchart4e9c4872014-04-30 02:31:45 +020033 aliases {
Wolfram Sang7c055892014-09-16 18:10:37 +020034 serial6 = &scifa0;
35 serial7 = &scifa1;
Laurent Pinchart4e9c4872014-04-30 02:31:45 +020036 };
37
Magnus Damm3cc828f2013-03-29 17:49:37 +090038 chosen {
Simon Hormandcbbbaf2013-08-06 16:50:11 +090039 bootargs = "console=ttySC6,115200 ignore_loglevel rw root=/dev/nfs ip=dhcp";
Geert Uytterhoevencf855812014-10-03 17:11:40 +020040 stdout-path = &scifa0;
Magnus Damm3cc828f2013-03-29 17:49:37 +090041 };
42
43 memory@40000000 {
44 device_type = "memory";
Magnus Damm7b16c612014-06-06 15:40:26 +090045 reg = <0 0x40000000 0 0x40000000>;
Magnus Damm3cc828f2013-03-29 17:49:37 +090046 };
47
Simon Horman126f9982014-09-03 09:49:01 +090048 memory@140000000 {
Magnus Damm62bc32a2013-10-31 12:21:41 +090049 device_type = "memory";
Magnus Damm7b16c612014-06-06 15:40:26 +090050 reg = <1 0x40000000 0 0xc0000000>;
Magnus Damm62bc32a2013-10-31 12:21:41 +090051 };
52
Magnus Damm3cc828f2013-03-29 17:49:37 +090053 lbsc {
54 #address-cells = <1>;
55 #size-cells = <1>;
56 };
Laurent Pinchart39fa5112013-12-11 15:13:47 +010057
Magnus Dammf7dcd382014-03-18 21:57:48 +090058 gpio_keys {
59 compatible = "gpio-keys";
60
61 button@1 {
62 linux,code = <KEY_1>;
63 label = "SW2-1";
64 gpio-key,wakeup;
65 debounce-interval = <20>;
66 gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
67 };
68 button@2 {
69 linux,code = <KEY_2>;
70 label = "SW2-2";
71 gpio-key,wakeup;
72 debounce-interval = <20>;
73 gpios = <&gpio1 24 GPIO_ACTIVE_LOW>;
74 };
75 button@3 {
76 linux,code = <KEY_3>;
77 label = "SW2-3";
78 gpio-key,wakeup;
79 debounce-interval = <20>;
80 gpios = <&gpio1 26 GPIO_ACTIVE_LOW>;
81 };
82 button@4 {
83 linux,code = <KEY_4>;
84 label = "SW2-4";
85 gpio-key,wakeup;
86 debounce-interval = <20>;
87 gpios = <&gpio1 28 GPIO_ACTIVE_LOW>;
88 };
89 };
90
Laurent Pinchart39fa5112013-12-11 15:13:47 +010091 leds {
92 compatible = "gpio-leds";
93 led6 {
94 gpios = <&gpio4 22 GPIO_ACTIVE_HIGH>;
95 };
96 led7 {
97 gpios = <&gpio4 23 GPIO_ACTIVE_HIGH>;
98 };
99 led8 {
100 gpios = <&gpio5 17 GPIO_ACTIVE_HIGH>;
101 };
102 };
103
104 fixedregulator3v3: fixedregulator@0 {
105 compatible = "regulator-fixed";
106 regulator-name = "fixed-3.3V";
107 regulator-min-microvolt = <3300000>;
108 regulator-max-microvolt = <3300000>;
109 regulator-boot-on;
110 regulator-always-on;
111 };
Kuninori Morimotoc6119942014-02-12 21:43:19 -0800112
113 vcc_sdhi0: regulator@1 {
114 compatible = "regulator-fixed";
115
116 regulator-name = "SDHI0 Vcc";
117 regulator-min-microvolt = <3300000>;
118 regulator-max-microvolt = <3300000>;
119
120 gpio = <&gpio5 24 GPIO_ACTIVE_HIGH>;
121 enable-active-high;
122 };
123
124 vccq_sdhi0: regulator@2 {
125 compatible = "regulator-gpio";
126
127 regulator-name = "SDHI0 VccQ";
128 regulator-min-microvolt = <1800000>;
129 regulator-max-microvolt = <3300000>;
130
131 gpios = <&gpio5 29 GPIO_ACTIVE_HIGH>;
132 gpios-states = <1>;
133 states = <3300000 1
134 1800000 0>;
135 };
136
137 vcc_sdhi2: regulator@3 {
138 compatible = "regulator-fixed";
139
140 regulator-name = "SDHI2 Vcc";
141 regulator-min-microvolt = <3300000>;
142 regulator-max-microvolt = <3300000>;
143
144 gpio = <&gpio5 25 GPIO_ACTIVE_HIGH>;
145 enable-active-high;
146 };
147
148 vccq_sdhi2: regulator@4 {
149 compatible = "regulator-gpio";
150
151 regulator-name = "SDHI2 VccQ";
152 regulator-min-microvolt = <1800000>;
153 regulator-max-microvolt = <3300000>;
154
155 gpios = <&gpio5 30 GPIO_ACTIVE_HIGH>;
156 gpios-states = <1>;
157 states = <3300000 1
158 1800000 0>;
159 };
Laurent Pinchart3edd18f2014-01-21 16:02:54 +0100160
Kuninori Morimoto8ea7a44a2014-11-03 17:47:56 -0800161 sound {
162 compatible = "simple-audio-card";
163
164 simple-audio-card,format = "left_j";
165 simple-audio-card,bitclock-master = <&sndcodec>;
166 simple-audio-card,frame-master = <&sndcodec>;
167
168 sndcpu: simple-audio-card,cpu {
169 sound-dai = <&rcar_sound>;
170 };
171
172 sndcodec: simple-audio-card,codec {
173 sound-dai = <&ak4643>;
174 system-clock-frequency = <11289600>;
175 };
176 };
177
Laurent Pinchart3edd18f2014-01-21 16:02:54 +0100178 vga-encoder {
179 compatible = "adi,adv7123";
180
181 ports {
182 #address-cells = <1>;
183 #size-cells = <0>;
184
185 port@0 {
186 reg = <0>;
187 adv7123_in: endpoint {
188 remote-endpoint = <&du_out_rgb>;
189 };
190 };
191 port@1 {
192 reg = <1>;
193 adv7123_out: endpoint {
194 remote-endpoint = <&vga_in>;
195 };
196 };
197 };
198 };
199
200 vga {
201 compatible = "vga-connector";
202
203 port {
204 vga_in: endpoint {
205 remote-endpoint = <&adv7123_out>;
206 };
207 };
208 };
209};
210
211&du {
212 pinctrl-0 = <&du_pins>;
213 pinctrl-names = "default";
214 status = "okay";
215
216 ports {
217 port@0 {
218 endpoint {
219 remote-endpoint = <&adv7123_in>;
220 };
221 };
222 port@2 {
223 lvds_connector: endpoint {
224 };
225 };
226 };
Laurent Pinchart39fa5112013-12-11 15:13:47 +0100227};
228
Laurent Pinchart62e43052013-12-11 15:13:49 +0100229&extal_clk {
230 clock-frequency = <20000000>;
231};
232
Laurent Pinchart39fa5112013-12-11 15:13:47 +0100233&pfc {
Laurent Pinchart3024f502014-02-16 22:31:59 +0100234 du_pins: du {
235 renesas,groups = "du_rgb666", "du_sync_1", "du_clk_out_0";
236 renesas,function = "du";
237 };
238
Wolfram Sang7c055892014-09-16 18:10:37 +0200239 scifa0_pins: serial0 {
240 renesas,groups = "scifa0_data";
241 renesas,function = "scifa0";
Laurent Pinchart39fa5112013-12-11 15:13:47 +0100242 };
243
Sergei Shtylyovda4ea952014-02-20 02:22:31 +0300244 ether_pins: ether {
245 renesas,groups = "eth_link", "eth_mdio", "eth_rmii";
246 renesas,function = "eth";
247 };
248
249 phy1_pins: phy1 {
250 renesas,groups = "intc_irq0";
251 renesas,function = "intc";
252 };
253
Wolfram Sang7c055892014-09-16 18:10:37 +0200254 scifa1_pins: serial1 {
255 renesas,groups = "scifa1_data";
256 renesas,function = "scifa1";
Laurent Pinchart39fa5112013-12-11 15:13:47 +0100257 };
258
Kuninori Morimotoc6119942014-02-12 21:43:19 -0800259 sdhi0_pins: sd0 {
Rob Taylorb08eed02014-04-07 20:16:52 +0100260 renesas,groups = "sdhi0_data4", "sdhi0_ctrl";
Kuninori Morimotoc6119942014-02-12 21:43:19 -0800261 renesas,function = "sdhi0";
262 };
263
264 sdhi2_pins: sd2 {
Rob Taylorb08eed02014-04-07 20:16:52 +0100265 renesas,groups = "sdhi2_data4", "sdhi2_ctrl";
Kuninori Morimotoc6119942014-02-12 21:43:19 -0800266 renesas,function = "sdhi2";
267 };
268
Laurent Pinchart39fa5112013-12-11 15:13:47 +0100269 mmc1_pins: mmc1 {
270 renesas,groups = "mmc1_data8", "mmc1_ctrl";
271 renesas,function = "mmc1";
272 };
Geert Uytterhoeven9fe7c4f2014-02-10 11:47:30 +0100273
Geert Uytterhoevenfad6d452014-02-25 11:30:13 +0100274 qspi_pins: spi0 {
Geert Uytterhoeven9fe7c4f2014-02-10 11:47:30 +0100275 renesas,groups = "qspi_ctrl", "qspi_data4";
276 renesas,function = "qspi";
277 };
Geert Uytterhoevenb0403b92014-02-25 11:30:17 +0100278
279 msiof1_pins: spi2 {
280 renesas,groups = "msiof1_clk", "msiof1_sync", "msiof1_rx",
281 "msiof1_tx";
282 renesas,function = "msiof1";
283 };
Benoit Cousson05f72e02014-06-03 21:02:12 +0900284
Wolfram Sangcb9a2b12014-07-10 12:50:56 +0200285 iic1_pins: iic1 {
286 renesas,groups = "iic1";
287 renesas,function = "iic1";
Simon Hormand90bf602014-06-06 16:11:00 +0900288 };
289
Wolfram Sangcb9a2b12014-07-10 12:50:56 +0200290 iic2_pins: iic2 {
291 renesas,groups = "iic2";
292 renesas,function = "iic2";
Simon Hormand90bf602014-06-06 16:11:00 +0900293 };
294
Khiem Nguyen5179ffd2014-07-04 09:19:51 +0900295 iic3_pins: iic3 {
296 renesas,groups = "iic3";
297 renesas,function = "iic3";
Benoit Cousson05f72e02014-06-03 21:02:12 +0900298 };
Ben Dooksd8584662014-06-24 22:02:21 +0400299
Yoshihiro Shimodae03074a2014-10-24 19:44:34 +0900300 hsusb_pins: hsusb {
301 renesas,groups = "usb0_ovc_vbus";
302 renesas,function = "usb0";
303 };
304
Ben Dooksd8584662014-06-24 22:02:21 +0400305 usb0_pins: usb0 {
306 renesas,groups = "usb0";
307 renesas,function = "usb0";
308 };
309
310 usb1_pins: usb1 {
311 renesas,groups = "usb1";
312 renesas,function = "usb1";
313 };
314
315 usb2_pins: usb2 {
316 renesas,groups = "usb2";
317 renesas,function = "usb2";
318 };
Ben Dooksd594c972014-08-13 00:18:26 +0400319
320 vin1_pins: vin {
321 renesas,groups = "vin1_data8", "vin1_clk";
322 renesas,function = "vin1";
323 };
Kuninori Morimoto8ea7a44a2014-11-03 17:47:56 -0800324
325 sound_pins: sound {
326 renesas,groups = "ssi0129_ctrl", "ssi0_data", "ssi1_data";
327 renesas,function = "ssi";
328 };
329
330 sound_clk_pins: sound_clk {
331 renesas,groups = "audio_clk_a";
332 renesas,function = "audio_clk";
333 };
Laurent Pinchart39fa5112013-12-11 15:13:47 +0100334};
335
Sergei Shtylyovda4ea952014-02-20 02:22:31 +0300336&ether {
337 pinctrl-0 = <&ether_pins &phy1_pins>;
338 pinctrl-names = "default";
339
340 phy-handle = <&phy1>;
341 renesas,ether-link-active-low;
342 status = "ok";
343
344 phy1: ethernet-phy@1 {
345 reg = <1>;
346 interrupt-parent = <&irqc0>;
347 interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
Simon Horman1c47a6a2014-04-08 09:21:35 +0900348 micrel,led-mode = <1>;
Sergei Shtylyovda4ea952014-02-20 02:22:31 +0300349 };
350};
351
Laurent Pinchart247fd5e2014-07-09 15:12:41 +0200352&cmt0 {
353 status = "ok";
354};
355
Laurent Pinchart39fa5112013-12-11 15:13:47 +0100356&mmcif1 {
357 pinctrl-0 = <&mmc1_pins>;
358 pinctrl-names = "default";
359
360 vmmc-supply = <&fixedregulator3v3>;
361 bus-width = <8>;
362 non-removable;
363 status = "okay";
Magnus Damm3cc828f2013-03-29 17:49:37 +0900364};
Valentine Barshakc6181b92014-01-14 21:05:31 +0400365
366&sata1 {
367 status = "okay";
368};
Geert Uytterhoeven9fe7c4f2014-02-10 11:47:30 +0100369
Geert Uytterhoevenfad6d452014-02-25 11:30:13 +0100370&qspi {
Geert Uytterhoeven9fe7c4f2014-02-10 11:47:30 +0100371 pinctrl-0 = <&qspi_pins>;
372 pinctrl-names = "default";
373
374 status = "okay";
375
376 flash: flash@0 {
377 #address-cells = <1>;
378 #size-cells = <1>;
379 compatible = "spansion,s25fl512s";
380 reg = <0>;
381 spi-max-frequency = <30000000>;
Geert Uytterhoeven9909d2c2014-04-14 19:36:00 +0200382 spi-tx-bus-width = <4>;
383 spi-rx-bus-width = <4>;
Geert Uytterhoeven9fe7c4f2014-02-10 11:47:30 +0100384 m25p,fast-read;
385
386 partition@0 {
387 label = "loader";
388 reg = <0x00000000 0x00040000>;
389 read-only;
390 };
391 partition@40000 {
392 label = "user";
393 reg = <0x00040000 0x00400000>;
394 read-only;
395 };
396 partition@440000 {
397 label = "flash";
398 reg = <0x00440000 0x03bc0000>;
399 };
400 };
401};
Kuninori Morimotoc6119942014-02-12 21:43:19 -0800402
Wolfram Sang7c055892014-09-16 18:10:37 +0200403&scifa0 {
404 pinctrl-0 = <&scifa0_pins>;
Laurent Pinchart4e9c4872014-04-30 02:31:45 +0200405 pinctrl-names = "default";
406
407 status = "okay";
408};
409
Wolfram Sang7c055892014-09-16 18:10:37 +0200410&scifa1 {
411 pinctrl-0 = <&scifa1_pins>;
Laurent Pinchart4e9c4872014-04-30 02:31:45 +0200412 pinctrl-names = "default";
413
414 status = "okay";
415};
416
Geert Uytterhoevenb0403b92014-02-25 11:30:17 +0100417&msiof1 {
418 pinctrl-0 = <&msiof1_pins>;
419 pinctrl-names = "default";
420
421 status = "okay";
422
423 pmic: pmic@0 {
424 compatible = "renesas,r2a11302ft";
425 reg = <0>;
426 spi-max-frequency = <6000000>;
427 spi-cpol;
428 spi-cpha;
429 };
Geert Uytterhoevenb0403b92014-02-25 11:30:17 +0100430};
431
Kuninori Morimotoc6119942014-02-12 21:43:19 -0800432&sdhi0 {
433 pinctrl-0 = <&sdhi0_pins>;
434 pinctrl-names = "default";
435
436 vmmc-supply = <&vcc_sdhi0>;
437 vqmmc-supply = <&vccq_sdhi0>;
438 cd-gpios = <&gpio3 6 GPIO_ACTIVE_LOW>;
439 status = "okay";
440};
441
442&sdhi2 {
443 pinctrl-0 = <&sdhi2_pins>;
444 pinctrl-names = "default";
445
446 vmmc-supply = <&vcc_sdhi2>;
447 vqmmc-supply = <&vccq_sdhi2>;
448 cd-gpios = <&gpio3 22 GPIO_ACTIVE_LOW>;
449 status = "okay";
450};
Benoit Cousson05f72e02014-06-03 21:02:12 +0900451
Benoit Coussonb989e132014-06-03 21:02:24 +0900452&cpu0 {
453 cpu0-supply = <&vdd_dvfs>;
454};
Ben Dookse489c2a2014-02-12 17:04:33 +0000455
Wolfram Sangcb9a2b12014-07-10 12:50:56 +0200456&iic0 {
Ben Dookse489c2a2014-02-12 17:04:33 +0000457 status = "ok";
458};
459
Wolfram Sangcb9a2b12014-07-10 12:50:56 +0200460&iic1 {
Ben Dookse489c2a2014-02-12 17:04:33 +0000461 status = "ok";
Wolfram Sangcb9a2b12014-07-10 12:50:56 +0200462 pinctrl-0 = <&iic1_pins>;
Ben Dookse1a2c4e2014-02-12 17:04:34 +0000463 pinctrl-names = "default";
Ben Dookse489c2a2014-02-12 17:04:33 +0000464};
465
Wolfram Sangcb9a2b12014-07-10 12:50:56 +0200466&iic2 {
Ben Dookse489c2a2014-02-12 17:04:33 +0000467 status = "ok";
Wolfram Sangcb9a2b12014-07-10 12:50:56 +0200468 pinctrl-0 = <&iic2_pins>;
Ben Dookse1a2c4e2014-02-12 17:04:34 +0000469 pinctrl-names = "default";
Ben Dooksd594c972014-08-13 00:18:26 +0400470
Kuninori Morimoto177d8be2014-11-03 17:47:46 -0800471 clock-frequency = <100000>;
472
Kuninori Morimoto8ea7a44a2014-11-03 17:47:56 -0800473 ak4643: sound-codec@12 {
474 compatible = "asahi-kasei,ak4643";
475 #sound-dai-cells = <0>;
476 reg = <0x12>;
477 };
478
Ben Dooksd594c972014-08-13 00:18:26 +0400479 composite-in@20 {
480 compatible = "adi,adv7180";
481 reg = <0x20>;
482 remote = <&vin1>;
483
484 port {
485 adv7180: endpoint {
486 bus-width = <8>;
487 remote-endpoint = <&vin1ep0>;
488 };
489 };
490 };
Ben Dookse489c2a2014-02-12 17:04:33 +0000491};
492
Khiem Nguyen5179ffd2014-07-04 09:19:51 +0900493&iic3 {
Simon Hormanaca4ec42014-06-09 11:09:44 +0900494 pinctrl-names = "default";
Khiem Nguyen5179ffd2014-07-04 09:19:51 +0900495 pinctrl-0 = <&iic3_pins>;
Simon Hormanaca4ec42014-06-09 11:09:44 +0900496 status = "okay";
497
498 vdd_dvfs: regulator@68 {
Steve Twissbd597f42014-08-22 15:26:55 +0100499 compatible = "dlg,da9210";
Simon Hormanaca4ec42014-06-09 11:09:44 +0900500 reg = <0x68>;
501
502 regulator-min-microvolt = <1000000>;
503 regulator-max-microvolt = <1000000>;
504 regulator-boot-on;
505 regulator-always-on;
506 };
Ben Dookse489c2a2014-02-12 17:04:33 +0000507};
Ben Dooksd8584662014-06-24 22:02:21 +0400508
509&pci0 {
510 status = "okay";
511 pinctrl-0 = <&usb0_pins>;
512 pinctrl-names = "default";
513};
514
515&pci1 {
516 status = "okay";
517 pinctrl-0 = <&usb1_pins>;
518 pinctrl-names = "default";
519};
520
Yoshihiro Shimoda37f7c1b2014-10-24 19:41:47 +0900521&xhci {
522 status = "okay";
523 pinctrl-0 = <&usb2_pins>;
524 pinctrl-names = "default";
525};
526
Ben Dooksd8584662014-06-24 22:02:21 +0400527&pci2 {
528 status = "okay";
529 pinctrl-0 = <&usb2_pins>;
530 pinctrl-names = "default";
531};
Ben Dooksd594c972014-08-13 00:18:26 +0400532
Yoshihiro Shimodae03074a2014-10-24 19:44:34 +0900533&hsusb {
534 status = "okay";
535 pinctrl-0 = <&hsusb_pins>;
536 pinctrl-names = "default";
537 renesas,enable-gpio = <&gpio5 18 GPIO_ACTIVE_HIGH>;
538};
539
Sergei Shtylyov6742caf2014-09-27 01:01:35 +0400540&usbphy {
541 status = "okay";
542};
543
Ben Dooksd594c972014-08-13 00:18:26 +0400544/* composite video input */
545&vin1 {
546 pinctrl-0 = <&vin1_pins>;
547 pinctrl-names = "default";
548
549 status = "ok";
550
551 port {
552 #address-cells = <1>;
553 #size-cells = <0>;
554
555 vin1ep0: endpoint {
556 remote-endpoint = <&adv7180>;
557 bus-width = <8>;
558 };
559 };
560};
Kuninori Morimoto8ea7a44a2014-11-03 17:47:56 -0800561
562&rcar_sound {
563 pinctrl-0 = <&sound_pins &sound_clk_pins>;
564 pinctrl-names = "default";
565
566 #sound-dai-cells = <0>;
567
568 status = "okay";
569
570 rcar_sound,dai {
571 dai0 {
572 playback = <&ssi0>;
573 capture = <&ssi1>;
574 };
575 };
576};
577
578&ssi0 {
579 pio-transfer;
580};
581
582&ssi1 {
583 pio-transfer;
584 shared-pin;
585};