2 * (C) Copyright 2017 Rockchip Electronics Co., Ltd
4 * SPDX-License-Identifier: GPL-2.0+
7 #include <dt-bindings/gpio/gpio.h>
8 #include <dt-bindings/interrupt-controller/irq.h>
9 #include <dt-bindings/interrupt-controller/arm-gic.h>
10 #include <dt-bindings/pinctrl/rockchip.h>
11 #include <dt-bindings/clock/rk3128-cru.h>
12 #include "skeleton.dtsi"
15 compatible = "rockchip,rk3128";
16 rockchip,sram = <&sram>;
17 interrupt-parent = <&gic>;
39 device_type = "memory";
40 reg = <0x60000000 0x40000000>;
44 compatible = "arm,cortex-a7-pmu";
45 interrupts = <GIC_SPI 76 IRQ_TYPE_LEVEL_HIGH>,
46 <GIC_SPI 77 IRQ_TYPE_LEVEL_HIGH>,
47 <GIC_SPI 78 IRQ_TYPE_LEVEL_HIGH>,
48 <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
54 enable-method = "rockchip,rk3128-smp";
58 compatible = "arm,cortex-a7";
64 #cooling-cells = <2>; /* min followed by max */
65 clock-latency = <40000>;
66 clocks = <&cru ARMCLK>;
71 compatible = "arm,cortex-a7";
77 compatible = "arm,cortex-a7";
83 compatible = "arm,cortex-a7";
88 cpu_axi_bus: cpu_axi_bus {
89 compatible = "rockchip,cpu_axi_bus";
100 reg = <0x10128080 0x20>;
104 reg = <0x1012a000 0x20>;
108 reg = <0x1012c000 0x20>;
112 reg = <0x1012d000 0x20>;
116 reg = <0x1012e000 0x20>;
120 reg = <0x1012f000 0x20>;
123 reg = <0x1012f080 0x20>;
127 reg = <0x1012f100 0x20>;
131 reg = <0x1012f180 0x20>;
132 rockchip,priority = <3 3>;
136 reg = <0x1012f200 0x20>;
137 rockchip,priority = <3 3>;
142 #address-cells = <1>;
147 reg = <0x10128000 0x20>;
148 rockchip,read-latency = <0x3f>;
154 compatible = "arm,psci";
156 cpu_suspend = <0x84000001>;
157 cpu_off = <0x84000002>;
158 cpu_on = <0x84000003>;
159 migrate = <0x84000005>;
163 compatible = "arm,amba-bus";
164 #address-cells = <1>;
166 interrupt-parent = <&gic>;
169 pdma: pdma@20078000 {
170 compatible = "arm,pl330", "arm,primecell";
171 reg = <0x20078000 0x4000>;
172 arm,pl330-broken-no-flushp;//2
173 interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>,
174 <GIC_SPI 1 IRQ_TYPE_LEVEL_HIGH>;
176 clocks = <&cru ACLK_DMAC2>;
177 clock-names = "apb_pclk";
182 compatible = "fixed-clock";
183 clock-frequency = <24000000>;
184 clock-output-names = "xin24m";
189 compatible = "fixed-clock";
191 clock-frequency = <12000000>;
192 clock-output-names = "xin12m";
197 compatible = "arm,armv7-timer";
198 arm,cpu-registers-not-fw-configured;
199 interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>,
200 <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>;
201 clock-frequency = <24000000>;
205 compatible = "arm,armv7-timer";
206 reg = <0x20044000 0xb8>;
207 interrupts = <GIC_SPI 28 IRQ_TYPE_LEVEL_HIGH>;
208 rockchip,broadcast = <1>;
211 watchdog: wdt@2004c000 {
212 compatible = "rockchip,watch dog";
213 reg = <0x2004c000 0x100>;
214 clock-names = "pclk_wdt";
215 interrupts = <GIC_SPI 34 IRQ_TYPE_LEVEL_HIGH>;
217 rockchip,timeout = <60>;
218 rockchip,atboot = <1>;
219 rockchip,debug = <0>;
222 reset: reset@20000110 {
223 compatible = "rockchip,reset";
224 reg = <0x20000110 0x24>;
228 nandc: nandc@10500000 {
229 compatible = "rockchip,rk-nandc";
230 reg = <0x10500000 0x4000>;
231 interrupts = <GIC_SPI 18 IRQ_TYPE_LEVEL_HIGH>;
232 pinctrl-names = "default";
233 pinctrl-0 = <&nandc_ale &nandc_cle &nandc_wrn &nandc_rdn &nandc_rdy &nandc_cs0 &nandc_data>;
235 clocks = <&cru SCLK_NANDC>,
238 clock-names = "clk_nandc", "g_clk_nandc", "hclk_nandc";
243 compatible = "rockchip,rk3128-dmc", "syscon";
244 reg = <0x0 0x20004000 0x0 0x1000>;
247 cru: clock-controller@20000000 {
249 compatible = "rockchip,rk3128-cru";
250 reg = <0x20000000 0x1000>;
251 rockchip,grf = <&grf>;
254 assigned-clocks = <&cru PLL_GPLL>;
255 assigned-clock-rates = <594000000>;
258 uart0: serial0@20060000 {
259 compatible = "rockchip,rk3128-uart", "snps,dw-apb-uart";
260 reg = <0x20060000 0x100>;
261 interrupts = <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH>;
264 clock-frequency = <24000000>;
265 clocks = <&cru SCLK_UART0>, <&cru PCLK_UART0>;
266 clock-names = "baudclk", "apb_pclk";
267 pinctrl-names = "default";
268 pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>;
269 dmas = <&pdma 2>, <&pdma 3>;
273 uart1: serial1@20064000 {
274 compatible = "rockchip,rk3128-uart", "snps,dw-apb-uart";
275 reg = <0x20064000 0x100>;
276 interrupts = <GIC_SPI 21 IRQ_TYPE_LEVEL_HIGH>;
279 clock-frequency = <24000000>;
280 clocks = <&cru SCLK_UART1>, <&cru PCLK_UART1>;
281 clock-names = "baudclk", "apb_pclk";
282 pinctrl-names = "default";
283 pinctrl-0 = <&uart1_xfer>;
284 dmas = <&pdma 4>, <&pdma 5>;
288 uart2: serial2@20068000 {
289 compatible = "rockchip,rk3128-uart", "snps,dw-apb-uart";
290 reg = <0x20068000 0x100>;
291 interrupts = <GIC_SPI 22 IRQ_TYPE_LEVEL_HIGH>;
294 clock-frequency = <24000000>;
295 clocks = <&cru SCLK_UART2>, <&cru PCLK_UART2>;
296 clock-names = "baudclk", "apb_pclk";
297 pinctrl-names = "default";
298 pinctrl-0 = <&uart2_xfer>;
299 dmas = <&pdma 6>, <&pdma 7>;
303 saradc: saradc@2006c000 {
304 compatible = "rockchip,saradc";
305 reg = <0x2006c000 0x100>;
306 interrupts = <GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>;
307 #io-channel-cells = <1>;
308 clocks = <&cru SCLK_SARADC>, <&cru PCLK_SARADC>;
309 clock-names = "saradc", "apb_pclk";
310 resets = <&cru SRST_SARADC>;
311 reset-names = "saradc-apb";
315 pwm0: pwm0@20050000 {
316 compatible = "rockchip,rk3128-pwm", "rockchip,rk3288-pwm";
317 reg = <0x20050000 0x10>;
319 pinctrl-names = "default";
320 pinctrl-0 = <&pwm0_pin>;
321 clocks = <&cru PCLK_PWM>;
325 pwm1: pwm1@20050010 {
326 compatible = "rockchip,rk3128-pwm", "rockchip,rk3288-pwm";
327 reg = <0x20050010 0x10>;
329 pinctrl-names = "default";
330 pinctrl-0 = <&pwm1_pin>;
331 clocks = <&cru PCLK_PWM>;
335 pwm2: pwm2@20050020 {
336 compatible = "rockchip,rk3128-pwm", "rockchip,rk3288-pwm";
337 reg = <0x20050020 0x10>;
339 pinctrl-names = "default";
340 pinctrl-0 = <&pwm2_pin>;
341 clocks = <&cru PCLK_PWM>;
345 pwm3: pwm3@20050030 {
346 compatible = "rockchip,rk3128-pwm", "rockchip,rk3288-pwm";
347 reg = <0x20050030 0x10>;
349 pinctrl-names = "default";
350 pinctrl-0 = <&pwm3_pin>;
351 clocks = <&cru PCLK_PWM>;
355 sram: sram@10080400 {
356 compatible = "rockchip,rk3128-smp-sram", "mmio-sram";
357 reg = <0x10080400 0x1C00>;
362 pmu: syscon@100a0000 {
363 compatible = "rockchip,rk3128-pmu", "syscon", "simple-mfd";
364 reg = <0x100a0000 0x1000>;
365 #address-cells = <1>;
369 gic: interrupt-controller@10139000 {
370 compatible = "arm,gic-400";
371 interrupt-controller;
372 #interrupt-cells = <3>;
373 #address-cells = <0>;
374 reg = <0x10139000 0x1000>,
378 interrupts = <GIC_PPI 9 0xf04>;
382 compatible = "rockchip,rk3128-usb2phy";
384 rockchip,grf = <&grf>;
385 clocks = <&cru SCLK_OTGPHY0>;
386 clock-names = "phyclk";
388 clock-output-names = "usb480m_phy";
392 u2phy_otg: otg-port {
394 interrupts = <GIC_SPI 35 IRQ_TYPE_LEVEL_HIGH>,
395 <GIC_SPI 51 IRQ_TYPE_LEVEL_HIGH>,
396 <GIC_SPI 52 IRQ_TYPE_LEVEL_HIGH>;
397 interrupt-names = "otg-bvalid", "otg-id",
402 u2phy_host: host-port {
404 interrupts = <GIC_SPI 53 IRQ_TYPE_LEVEL_HIGH>;
405 interrupt-names = "linestate";
410 usb_otg: usb@10180000 {
411 compatible = "rockchip,rk3128-usb", "rockchip,rk3288-usb",
413 reg = <0x10180000 0x40000>;
414 interrupts = <GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>;
423 usb_host_ehci: usb@101c0000 {
424 compatible = "generic-ehci";
425 reg = <0x101c0000 0x20000>;
426 interrupts = <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>;
432 usb_host_ohci: usb@101e0000 {
433 compatible = "generic-ohci";
434 reg = <0x101e0000 0x20000>;
435 interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_HIGH>;
441 sdmmc: dwmmc@10214000 {
442 compatible = "rockchip,rk312x-dw-mshc", "rockchip,rk3288-dw-mshc";
443 reg = <0x10214000 0x4000>;
444 max-frequency = <150000000>;
445 interrupts = <GIC_SPI 14 IRQ_TYPE_LEVEL_HIGH>;
446 clocks = <&cru HCLK_SDMMC>, <&cru SCLK_SDMMC>,
447 <&cru SCLK_SDMMC_DRV>, <&cru SCLK_SDMMC_SAMPLE>;
448 clock-names = "biu", "ciu", "ciu_drv", "ciu_sample";
449 fifo-depth = <0x100>;
450 pinctrl-names = "default";
451 pinctrl-0 = <&sdmmc_clk &sdmmc_cmd &sdmmc_bus4>;
456 emmc: dwmmc@1021c000 {
458 compatible = "rockchip,rk3128-dw-mshc", "rockchip,rk3288-dw-mshc";
459 reg = <0x1021c000 0x4000>;
460 max-frequency = <150000000>;
461 interrupts = <GIC_SPI 16 IRQ_TYPE_LEVEL_HIGH>;
462 clocks = <&cru HCLK_EMMC>, <&cru SCLK_EMMC>,
463 <&cru SCLK_EMMC_DRV>, <&cru SCLK_EMMC_SAMPLE>;
464 clock-names = "biu", "ciu", "ciu_drv", "ciu_sample";
466 default-sample-phase = <158>;
468 fifo-depth = <0x100>;
469 pinctrl-names = "default";
470 pinctrl-0 = <&emmc_clk &emmc_cmd &emmc_bus8>;
471 resets = <&cru SRST_EMMC>;
472 reset-names = "reset";
476 i2c0: i2c0@20072000 {
477 compatible = "rockchip,rk3128-i2c", "rockchip,rk3288-i2c";
478 reg = <20072000 0x1000>;
479 interrupts = <GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH>;
480 #address-cells = <1>;
483 clocks = <&cru PCLK_I2C0>;
484 pinctrl-names = "default";
485 pinctrl-0 = <&i2c0_xfer>;
488 i2c1: i2c1@20056000 {
489 compatible = "rockchip,rk3128-i2c", "rockchip,rk3288-i2c";
490 reg = <0x20056000 0x1000>;
491 interrupts = <GIC_SPI 25 IRQ_TYPE_LEVEL_HIGH>;
492 #address-cells = <1>;
495 clocks = <&cru PCLK_I2C1>;
496 pinctrl-names = "default";
497 pinctrl-0 = <&i2c1_xfer>;
500 i2c2: i2c2@2005a000 {
501 compatible = "rockchip,rk3128-i2c", "rockchip,rk3288-i2c";
502 reg = <0x2005a000 0x1000>;
503 interrupts = <GIC_SPI 26 IRQ_TYPE_LEVEL_HIGH>;
504 #address-cells = <1>;
507 clocks = <&cru PCLK_I2C2>;
508 pinctrl-names = "default";
509 pinctrl-0 = <&i2c2_xfer>;
512 i2c3: i2c3@2005e000 {
513 compatible = "rockchip,rk3128-i2c", "rockchip,rk3288-i2c";
514 reg = <0x2005e000 0x1000>;
515 interrupts = <GIC_SPI 27 IRQ_TYPE_LEVEL_HIGH>;
516 #address-cells = <1>;
519 clocks = <&cru PCLK_I2C3>;
520 pinctrl-names = "default";
521 pinctrl-0 = <&i2c3_xfer>;
525 compatible = "rockchip,rk3128-spi", "rockchip,rk3288-spi";
526 reg = <0x20074000 0x1000>;
527 interrupts = <GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH>;
528 #address-cells = <1>;
530 pinctrl-names = "default";
531 pinctrl-0 = <&spi0_txd_mux0 &spi0_rxd_mux0 &spi0_clk_mux0 &spi0_cs0_mux0 &spi0_cs1_mux0>;
532 rockchip,spi-src-clk = <0>;
534 clocks =<&cru SCLK_SPI>, <&cru PCLK_SPI>;
535 clock-names = "spi","pclk_spi0";
536 dmas = <&pdma 8>, <&pdma 9>;
538 dma-names = "tx", "rx";
541 grf: syscon@20008000 {
543 compatible = "rockchip,rk3128-grf", "syscon";
544 reg = <0x20008000 0x1000>;
547 pinctrl: pinctrl@20008000 {
548 compatible = "rockchip,rk3128-pinctrl";
549 reg = <0x20008000 0xA8>,
553 reg-names = "base", "mux", "pull", "drv";
554 rockchip,grf = <&grf>;
555 #address-cells = <1>;
559 gpio0: gpio0@2007c000 {
560 compatible = "rockchip,gpio-bank";
561 reg = <0x2007c000 0x100>;
562 interrupts = <GIC_SPI 36 IRQ_TYPE_LEVEL_HIGH>;
563 clocks = <&cru PCLK_GPIO0>;
566 interrupt-controller;
567 #interrupt-cells = <2>;
570 gpio1: gpio1@20080000 {
571 compatible = "rockchip,gpio-bank";
572 reg = <0x20080000 0x100>;
573 interrupts = <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>;
574 clocks = <&cru PCLK_GPIO1>;
577 interrupt-controller;
578 #interrupt-cells = <2>;
581 gpio2: gpio2@20084000 {
582 compatible = "rockchip,gpio-bank";
583 reg = <0x20084000 0x100>;
584 interrupts = <GIC_SPI 38 IRQ_TYPE_LEVEL_HIGH>;
585 clocks = <&cru PCLK_GPIO2>;
588 interrupt-controller;
589 #interrupt-cells = <2>;
592 gpio3: gpio2@20088000 {
593 compatible = "rockchip,gpio-bank";
594 reg = <0x20088000 0x100>;
595 interrupts = <GIC_SPI 39 IRQ_TYPE_LEVEL_HIGH>;
596 clocks = <&cru PCLK_GPIO3>;
599 interrupt-controller;
600 #interrupt-cells = <2>;
603 pcfg_pull_up: pcfg-pull-up {
607 pcfg_pull_down: pcfg-pull-down {
611 pcfg_pull_none: pcfg-pull-none {
617 * We run eMMC at max speed; bump up drive strength.
618 * We also have external pulls, so disable the internal ones.
622 rockchip,pins = <2 7 RK_FUNC_2 &pcfg_pull_none>;
626 rockchip,pins = <2 4 RK_FUNC_2 &pcfg_pull_none>;
629 emmc_pwren: emmc-pwren {
630 rockchip,pins = <2 5 RK_FUNC_2 &pcfg_pull_none>;
633 emmc_bus8: emmc-bus8 {
634 rockchip,pins = <1 24 RK_FUNC_2 &pcfg_pull_none>,
635 <1 25 RK_FUNC_2 &pcfg_pull_none>,
636 <1 26 RK_FUNC_2 &pcfg_pull_none>,
637 <1 27 RK_FUNC_2 &pcfg_pull_none>,
638 <1 28 RK_FUNC_2 &pcfg_pull_none>,
639 <1 29 RK_FUNC_2 &pcfg_pull_none>,
640 <1 30 RK_FUNC_2 &pcfg_pull_none>,
641 <1 31 RK_FUNC_2 &pcfg_pull_none>;
646 nandc_ale:nandc-ale {
647 rockchip,pins = <0 18 RK_FUNC_1 &pcfg_pull_none>;
650 nandc_cle:nandc-cle {
651 rockchip,pins = <0 18 RK_FUNC_1 &pcfg_pull_none>;
654 nandc_wrn:nandc-wrn {
655 rockchip,pins = <0 18 RK_FUNC_1 &pcfg_pull_none>;
658 nandc_rdn:nandc-rdn {
659 rockchip,pins = <0 18 RK_FUNC_1 &pcfg_pull_none>;
662 nandc_rdy:nandc-rdy {
663 rockchip,pins = <0 18 RK_FUNC_1 &pcfg_pull_none>;
666 nandc_cs0:nandc-cs0 {
667 rockchip,pins = <0 18 RK_FUNC_1 &pcfg_pull_none>;
670 nandc_data: nandc-data {
671 rockchip,pins = <0 18 RK_FUNC_1 &pcfg_pull_none>;
676 uart0_xfer: uart0-xfer {
677 rockchip,pins = <0 16 RK_FUNC_1 &pcfg_pull_none>,
678 <0 17 RK_FUNC_1 &pcfg_pull_none>;
681 uart0_cts: uart0-cts {
682 rockchip,pins = <0 18 RK_FUNC_1 &pcfg_pull_none>;
685 uart0_rts: uart0-rts {
686 rockchip,pins = <0 19 RK_FUNC_1 &pcfg_pull_none>;
691 uart1_xfer: uart1-xfer {
692 rockchip,pins = <2 22 RK_FUNC_1 &pcfg_pull_none>,
693 <2 23 RK_FUNC_1 &pcfg_pull_none>;
698 uart2_xfer: uart2-xfer {
699 rockchip,pins = <1 18 RK_FUNC_2 &pcfg_pull_none>,
700 <1 19 RK_FUNC_2 &pcfg_pull_none>;
705 sdmmc_clk: sdmmc-clk {
706 rockchip,pins = <1 RK_PC0 1 &pcfg_pull_none>;
709 sdmmc_cmd: sdmmc-cmd {
710 rockchip,pins = <1 RK_PC1 1 &pcfg_pull_up>;
714 rockchip,pins = <1 RK_PA7 1 &pcfg_pull_up>;
717 sdmmc_pwren: sdmmc-pwren {
718 rockchip,pins = <1 RK_PB6 1 &pcfg_pull_up>;
721 sdmmc_bus4: sdmmc-bus4 {
722 rockchip,pins = <1 RK_PC2 1 &pcfg_pull_up>,
723 <1 RK_PC3 1 &pcfg_pull_up>,
724 <1 RK_PC4 1 &pcfg_pull_up>,
725 <1 RK_PC5 1 &pcfg_pull_up>;
731 rockchip,pins = <0 0 RK_FUNC_2 &pcfg_pull_none>;
737 rockchip,pins = <0 1 RK_FUNC_2 &pcfg_pull_none>;
743 rockchip,pins = <0 1 2 &pcfg_pull_none>;
749 rockchip,pins = <0 27 1 &pcfg_pull_none>;
754 i2c0_xfer: i2c0-xfer {
755 rockchip,pins = <0 0 RK_FUNC_1 &pcfg_pull_none>,
756 <0 1 RK_FUNC_1 &pcfg_pull_none>;
761 i2c1_xfer: i2c1-xfer {
762 rockchip,pins = <0 2 RK_FUNC_1 &pcfg_pull_none>,
763 <0 3 RK_FUNC_1 &pcfg_pull_none>;
768 i2c2_xfer: i2c2-xfer {
769 rockchip,pins = <2 20 3 &pcfg_pull_none>,
770 <2 21 3 &pcfg_pull_none>;
775 i2c3_xfer: i2c3-xfer {
776 rockchip,pins = <0 6 RK_FUNC_1 &pcfg_pull_none>,
777 <0 7 RK_FUNC_1 &pcfg_pull_none>;
782 spi0_txd_mux0:spi0-txd-mux0 {
783 rockchip,pins = <2 4 RK_FUNC_2 &pcfg_pull_none>;
786 spi0_rxd_mux0:spi0-rxd-mux0 {
787 rockchip,pins = <2 4 RK_FUNC_2 &pcfg_pull_none>;
790 spi0_clk_mux0:spi0-clk-mux0 {
791 rockchip,pins = <2 4 RK_FUNC_2 &pcfg_pull_none>;
794 spi0_cs0_mux0:spi0-cs0-mux0 {
795 rockchip,pins = <2 4 RK_FUNC_2 &pcfg_pull_none>;
798 spi0_cs1_mux0:spi0-cs1-mux0 {
799 rockchip,pins = <2 4 RK_FUNC_2 &pcfg_pull_none>;