Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu
[deliverable/linux.git] / arch / arm / boot / dts / rk3288-firefly.dtsi
1 /*
2 * Copyright (c) 2014, 2015 FUKAUMI Naoki <naobsd@gmail.com>
3 *
4 * This file is dual-licensed: you can use it either under the terms
5 * of the GPL or the X11 license, at your option. Note that this dual
6 * licensing only applies to this file, and not this project as a
7 * whole.
8 *
9 * a) This file is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License as
11 * published by the Free Software Foundation; either version 2 of the
12 * License, or (at your option) any later version.
13 *
14 * This file is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
18 *
19 * Or, alternatively,
20 *
21 * b) Permission is hereby granted, free of charge, to any person
22 * obtaining a copy of this software and associated documentation
23 * files (the "Software"), to deal in the Software without
24 * restriction, including without limitation the rights to use,
25 * copy, modify, merge, publish, distribute, sublicense, and/or
26 * sell copies of the Software, and to permit persons to whom the
27 * Software is furnished to do so, subject to the following
28 * conditions:
29 *
30 * The above copyright notice and this permission notice shall be
31 * included in all copies or substantial portions of the Software.
32 *
33 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
34 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
35 * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
36 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
37 * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
38 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
39 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
40 * OTHER DEALINGS IN THE SOFTWARE.
41 */
42
43 #include <dt-bindings/input/input.h>
44 #include "rk3288.dtsi"
45
46 / {
47 memory {
48 device_type = "memory";
49 reg = <0 0x80000000>;
50 };
51
52 dovdd_1v8: dovdd-1v8-regulator {
53 compatible = "regulator-fixed";
54 regulator-name = "dovdd_1v8";
55 regulator-min-microvolt = <1800000>;
56 regulator-max-microvolt = <1800000>;
57 vin-supply = <&vcc28_dvp>;
58 };
59
60 ext_gmac: external-gmac-clock {
61 compatible = "fixed-clock";
62 #clock-cells = <0>;
63 clock-frequency = <125000000>;
64 clock-output-names = "ext_gmac";
65 };
66
67 io_domains: io-domains {
68 compatible = "rockchip,rk3288-io-voltage-domain";
69 rockchip,grf = <&grf>;
70
71 audio-supply = <&vcca_33>;
72 bb-supply = <&vcc_io>;
73 dvp-supply = <&dovdd_1v8>;
74 flash0-supply = <&vcc_flash>;
75 flash1-supply = <&vcc_lan>;
76 gpio30-supply = <&vcc_io>;
77 gpio1830-supply = <&vcc_io>;
78 lcdc-supply = <&vcc_io>;
79 sdcard-supply = <&vccio_sd>;
80 wifi-supply = <&vccio_wl>;
81 };
82
83 ir: ir-receiver {
84 compatible = "gpio-ir-receiver";
85 pinctrl-names = "default";
86 pinctrl-0 = <&ir_int>;
87 };
88
89 keys: gpio-keys {
90 compatible = "gpio-keys";
91
92 power {
93 wakeup-source;
94 gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
95 label = "GPIO Power";
96 linux,code = <KEY_POWER>;
97 pinctrl-names = "default";
98 pinctrl-0 = <&pwr_key>;
99 };
100 };
101
102 leds {
103 compatible = "gpio-leds";
104
105 work {
106 gpios = <&gpio8 1 GPIO_ACTIVE_LOW>;
107 label = "firefly:blue:user";
108 linux,default-trigger = "rc-feedback";
109 pinctrl-names = "default";
110 pinctrl-0 = <&work_led>;
111 };
112
113 power {
114 gpios = <&gpio8 2 GPIO_ACTIVE_LOW>;
115 label = "firefly:green:power";
116 linux,default-trigger = "default-on";
117 pinctrl-names = "default";
118 pinctrl-0 = <&power_led>;
119 };
120 };
121
122 vbat_wl: vcc_sys: vsys-regulator {
123 compatible = "regulator-fixed";
124 regulator-name = "vcc_sys";
125 regulator-min-microvolt = <5000000>;
126 regulator-max-microvolt = <5000000>;
127 regulator-always-on;
128 regulator-boot-on;
129 };
130
131 vcc_sd: sdmmc-regulator {
132 compatible = "regulator-fixed";
133 gpio = <&gpio7 11 GPIO_ACTIVE_LOW>;
134 pinctrl-names = "default";
135 pinctrl-0 = <&sdmmc_pwr>;
136 regulator-name = "vcc_sd";
137 regulator-min-microvolt = <3300000>;
138 regulator-max-microvolt = <3300000>;
139 startup-delay-us = <100000>;
140 vin-supply = <&vcc_io>;
141 };
142
143 vcc_flash: flash-regulator {
144 compatible = "regulator-fixed";
145 regulator-name = "vcc_flash";
146 regulator-min-microvolt = <1800000>;
147 regulator-max-microvolt = <1800000>;
148 vin-supply = <&vcc_io>;
149 };
150
151 vcc_5v: usb-regulator {
152 compatible = "regulator-fixed";
153 regulator-name = "vcc_5v";
154 regulator-min-microvolt = <5000000>;
155 regulator-max-microvolt = <5000000>;
156 regulator-always-on;
157 regulator-boot-on;
158 vin-supply = <&vcc_sys>;
159 };
160
161 vcc_host_5v: usb-host-regulator {
162 compatible = "regulator-fixed";
163 enable-active-high;
164 gpio = <&gpio0 14 GPIO_ACTIVE_HIGH>;
165 pinctrl-names = "default";
166 pinctrl-0 = <&host_vbus_drv>;
167 regulator-name = "vcc_host_5v";
168 regulator-min-microvolt = <5000000>;
169 regulator-max-microvolt = <5000000>;
170 regulator-always-on;
171 vin-supply = <&vcc_5v>;
172 };
173
174 vcc_otg_5v: usb-otg-regulator {
175 compatible = "regulator-fixed";
176 enable-active-high;
177 gpio = <&gpio0 12 GPIO_ACTIVE_HIGH>;
178 pinctrl-names = "default";
179 pinctrl-0 = <&otg_vbus_drv>;
180 regulator-name = "vcc_otg_5v";
181 regulator-min-microvolt = <5000000>;
182 regulator-max-microvolt = <5000000>;
183 regulator-always-on;
184 vin-supply = <&vcc_5v>;
185 };
186
187 /*
188 * A TT8142 creates both dovdd_1v8 and vcc28_dvp, controlled
189 * by the dvp_pwr pin.
190 */
191 vcc28_dvp: vcc28-dvp-regulator {
192 compatible = "regulator-fixed";
193 enable-active-high;
194 gpio = <&gpio0 11 GPIO_ACTIVE_HIGH>;
195 pinctrl-names = "default";
196 pinctrl-0 = <&dvp_pwr>;
197 regulator-name = "vcc28_dvp";
198 regulator-min-microvolt = <2800000>;
199 regulator-max-microvolt = <2800000>;
200 regulator-always-on;
201 vin-supply = <&vcc_io>;
202 };
203 };
204
205 &cpu0 {
206 cpu0-supply = <&vdd_cpu>;
207 };
208
209 &emmc {
210 bus-width = <8>;
211 cap-mmc-highspeed;
212 disable-wp;
213 non-removable;
214 num-slots = <1>;
215 pinctrl-names = "default";
216 pinctrl-0 = <&emmc_clk>, <&emmc_cmd>, <&emmc_pwr>, <&emmc_bus8>;
217 vmmc-supply = <&vcc_io>;
218 vqmmc-supply = <&vcc_flash>;
219 status = "okay";
220 };
221
222 &gmac {
223 assigned-clocks = <&cru SCLK_MAC>;
224 assigned-clock-parents = <&ext_gmac>;
225 clock_in_out = "input";
226 pinctrl-names = "default";
227 pinctrl-0 = <&rgmii_pins>, <&phy_rst>, <&phy_pmeb>, <&phy_int>;
228 phy-supply = <&vcc_lan>;
229 phy-mode = "rgmii";
230 snps,reset-active-low;
231 snps,reset-delays-us = <0 10000 1000000>;
232 snps,reset-gpio = <&gpio4 8 GPIO_ACTIVE_LOW>;
233 tx_delay = <0x30>;
234 rx_delay = <0x10>;
235 status = "ok";
236 };
237
238 &hdmi {
239 ddc-i2c-bus = <&i2c5>;
240 status = "okay";
241 };
242
243 &i2c0 {
244 clock-frequency = <400000>;
245 status = "okay";
246
247 vdd_cpu: syr827@40 {
248 compatible = "silergy,syr827";
249 fcs,suspend-voltage-selector = <1>;
250 reg = <0x40>;
251 regulator-name = "vdd_cpu";
252 regulator-min-microvolt = <850000>;
253 regulator-max-microvolt = <1350000>;
254 regulator-always-on;
255 regulator-boot-on;
256 regulator-enable-ramp-delay = <300>;
257 regulator-ramp-delay = <8000>;
258 vin-supply = <&vcc_sys>;
259 };
260
261 vdd_gpu: syr828@41 {
262 compatible = "silergy,syr828";
263 fcs,suspend-voltage-selector = <1>;
264 reg = <0x41>;
265 regulator-name = "vdd_gpu";
266 regulator-min-microvolt = <850000>;
267 regulator-max-microvolt = <1350000>;
268 regulator-always-on;
269 vin-supply = <&vcc_sys>;
270 };
271
272 hym8563: hym8563@51 {
273 compatible = "haoyu,hym8563";
274 reg = <0x51>;
275 #clock-cells = <0>;
276 clock-frequency = <32768>;
277 clock-output-names = "xin32k";
278 interrupt-parent = <&gpio7>;
279 interrupts = <4 IRQ_TYPE_EDGE_FALLING>;
280 pinctrl-names = "default";
281 pinctrl-0 = <&rtc_int>;
282 };
283
284 act8846: act8846@5a {
285 compatible = "active-semi,act8846";
286 reg = <0x5a>;
287 pinctrl-names = "default";
288 pinctrl-0 = <&pmic_vsel>, <&pwr_hold>;
289 system-power-controller;
290
291 vp1-supply = <&vcc_sys>;
292 vp2-supply = <&vcc_sys>;
293 vp3-supply = <&vcc_sys>;
294 vp4-supply = <&vcc_sys>;
295 inl1-supply = <&vcc_sys>;
296 inl2-supply = <&vcc_sys>;
297 inl3-supply = <&vcc_20>;
298
299 regulators {
300 vcc_ddr: REG1 {
301 regulator-name = "vcc_ddr";
302 regulator-min-microvolt = <1200000>;
303 regulator-max-microvolt = <1200000>;
304 regulator-always-on;
305 };
306
307 vcc_io: REG2 {
308 regulator-name = "vcc_io";
309 regulator-min-microvolt = <3300000>;
310 regulator-max-microvolt = <3300000>;
311 regulator-always-on;
312 };
313
314 vdd_log: REG3 {
315 regulator-name = "vdd_log";
316 regulator-min-microvolt = <1100000>;
317 regulator-max-microvolt = <1100000>;
318 regulator-always-on;
319 };
320
321 vcc_20: REG4 {
322 regulator-name = "vcc_20";
323 regulator-min-microvolt = <2000000>;
324 regulator-max-microvolt = <2000000>;
325 regulator-always-on;
326 };
327
328 vccio_sd: REG5 {
329 regulator-name = "vccio_sd";
330 regulator-min-microvolt = <3300000>;
331 regulator-max-microvolt = <3300000>;
332 regulator-always-on;
333 };
334
335 vdd10_lcd: REG6 {
336 regulator-name = "vdd10_lcd";
337 regulator-min-microvolt = <1000000>;
338 regulator-max-microvolt = <1000000>;
339 regulator-always-on;
340 };
341
342 vcca_18: REG7 {
343 regulator-name = "vcca_18";
344 regulator-min-microvolt = <1800000>;
345 regulator-max-microvolt = <1800000>;
346 };
347
348 vcca_33: REG8 {
349 regulator-name = "vcca_33";
350 regulator-min-microvolt = <3300000>;
351 regulator-max-microvolt = <3300000>;
352 };
353
354 vcc_lan: REG9 {
355 regulator-name = "vcc_lan";
356 regulator-min-microvolt = <3300000>;
357 regulator-max-microvolt = <3300000>;
358 };
359
360 vdd_10: REG10 {
361 regulator-name = "vdd_10";
362 regulator-min-microvolt = <1000000>;
363 regulator-max-microvolt = <1000000>;
364 regulator-always-on;
365 };
366
367 vccio_wl: vcc_18: REG11 {
368 regulator-name = "vcc_18";
369 regulator-min-microvolt = <1800000>;
370 regulator-max-microvolt = <1800000>;
371 regulator-always-on;
372 };
373
374 vcc18_lcd: REG12 {
375 regulator-name = "vcc18_lcd";
376 regulator-min-microvolt = <1800000>;
377 regulator-max-microvolt = <1800000>;
378 regulator-always-on;
379 };
380 };
381 };
382 };
383
384 &i2c1 {
385 status = "okay";
386 };
387
388 &i2c2 {
389 status = "okay";
390 };
391
392 &i2c4 {
393 status = "okay";
394 };
395
396 &i2c5 {
397 status = "okay";
398 };
399
400 &pinctrl {
401 pcfg_output_high: pcfg-output-high {
402 output-high;
403 };
404
405 pcfg_output_low: pcfg-output-low {
406 output-low;
407 };
408
409 pcfg_pull_up_drv_12ma: pcfg-pull-up-drv-12ma {
410 bias-pull-up;
411 drive-strength = <12>;
412 };
413
414 act8846 {
415 pwr_hold: pwr-hold {
416 rockchip,pins = <0 1 RK_FUNC_GPIO &pcfg_output_high>;
417 };
418 };
419
420 dvp {
421 dvp_pwr: dvp-pwr {
422 rockchip,pins = <0 11 RK_FUNC_GPIO &pcfg_pull_none>;
423 };
424 };
425
426 gmac {
427 phy_int: phy-int {
428 rockchip,pins = <0 9 RK_FUNC_GPIO &pcfg_pull_up>;
429 };
430
431 phy_pmeb: phy-pmeb {
432 rockchip,pins = <0 8 RK_FUNC_GPIO &pcfg_pull_up>;
433 };
434
435 phy_rst: phy-rst {
436 rockchip,pins = <4 8 RK_FUNC_GPIO &pcfg_output_high>;
437 };
438 };
439
440 hym8563 {
441 rtc_int: rtc-int {
442 rockchip,pins = <7 4 RK_FUNC_GPIO &pcfg_pull_up>;
443 };
444 };
445
446 keys {
447 pwr_key: pwr-key {
448 rockchip,pins = <0 5 RK_FUNC_GPIO &pcfg_pull_up>;
449 };
450 };
451
452 leds {
453 power_led: power-led {
454 rockchip,pins = <8 2 RK_FUNC_GPIO &pcfg_pull_none>;
455 };
456
457 work_led: work-led {
458 rockchip,pins = <8 1 RK_FUNC_GPIO &pcfg_pull_none>;
459 };
460 };
461
462 sdmmc {
463 /*
464 * Default drive strength isn't enough to achieve even
465 * high-speed mode on firefly board so bump up to 12ma.
466 */
467 sdmmc_bus4: sdmmc-bus4 {
468 rockchip,pins = <6 16 RK_FUNC_1 &pcfg_pull_up_drv_12ma>,
469 <6 17 RK_FUNC_1 &pcfg_pull_up_drv_12ma>,
470 <6 18 RK_FUNC_1 &pcfg_pull_up_drv_12ma>,
471 <6 19 RK_FUNC_1 &pcfg_pull_up_drv_12ma>;
472 };
473
474 sdmmc_clk: sdmmc-clk {
475 rockchip,pins = <6 20 RK_FUNC_1 &pcfg_pull_none_12ma>;
476 };
477
478 sdmmc_cmd: sdmmc-cmd {
479 rockchip,pins = <6 21 RK_FUNC_1 &pcfg_pull_up_drv_12ma>;
480 };
481
482 sdmmc_pwr: sdmmc-pwr {
483 rockchip,pins = <7 11 RK_FUNC_GPIO &pcfg_pull_none>;
484 };
485 };
486
487 usb_host {
488 host_vbus_drv: host-vbus-drv {
489 rockchip,pins = <0 14 RK_FUNC_GPIO &pcfg_pull_none>;
490 };
491
492 usbhub_rst: usbhub-rst {
493 rockchip,pins = <8 3 RK_FUNC_GPIO &pcfg_output_high>;
494 };
495 };
496
497 usb_otg {
498 otg_vbus_drv: otg-vbus-drv {
499 rockchip,pins = <0 12 RK_FUNC_GPIO &pcfg_pull_none>;
500 };
501 };
502 };
503
504 &saradc {
505 vref-supply = <&vcc_18>;
506 status = "okay";
507 };
508
509 &sdio0 {
510 bus-width = <4>;
511 disable-wp;
512 non-removable;
513 num-slots = <1>;
514 pinctrl-names = "default";
515 pinctrl-0 = <&sdio0_bus4>, <&sdio0_cmd>, <&sdio0_clk>;
516 vmmc-supply = <&vbat_wl>;
517 vqmmc-supply = <&vccio_wl>;
518 status = "okay";
519 };
520
521 &sdmmc {
522 bus-width = <4>;
523 cap-mmc-highspeed;
524 cap-sd-highspeed;
525 card-detect-delay = <200>;
526 disable-wp;
527 num-slots = <1>;
528 pinctrl-names = "default";
529 pinctrl-0 = <&sdmmc_clk>, <&sdmmc_cmd>, <&sdmmc_cd>, <&sdmmc_bus4>;
530 vmmc-supply = <&vcc_sd>;
531 vqmmc-supply = <&vccio_sd>;
532 status = "okay";
533 };
534
535 &spi0 {
536 pinctrl-names = "default";
537 pinctrl-0 = <&spi0_clk>, <&spi0_cs0>, <&spi0_tx>, <&spi0_rx>, <&spi0_cs1>;
538 status = "okay";
539 };
540
541 &tsadc {
542 rockchip,hw-tshut-mode = <0>;
543 rockchip,hw-tshut-polarity = <0>;
544 status = "okay";
545 };
546
547 &uart0 {
548 pinctrl-names = "default";
549 pinctrl-0 = <&uart0_xfer>, <&uart0_cts>, <&uart0_rts>;
550 status = "okay";
551 };
552
553 &uart1 {
554 status = "okay";
555 };
556
557 &uart2 {
558 status = "okay";
559 };
560
561 &uart3 {
562 status = "okay";
563 };
564
565 &usbphy {
566 status = "okay";
567 };
568
569 &usb_host1 {
570 pinctrl-names = "default";
571 pinctrl-0 = <&usbhub_rst>;
572 status = "okay";
573 };
574
575 &usb_otg {
576 status = "okay";
577 };
578
579 &vopb {
580 status = "okay";
581 };
582
583 &vopb_mmu {
584 status = "okay";
585 };
586
587 &vopl {
588 status = "okay";
589 };
590
591 &vopl_mmu {
592 status = "okay";
593 };
594
595 &wdt {
596 status = "okay";
597 };
This page took 0.04609 seconds and 5 git commands to generate.