Jagan Teki | 208badd | 2019-03-11 13:50:03 +0530 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0+ |
| 2 | /* |
| 3 | * Copyright (C) 2019 Jagan Teki <jagan@amarulasolutions.com> |
| 4 | */ |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 5 | #define USB_CLASS_HUB 9 |
Jagan Teki | 208badd | 2019-03-11 13:50:03 +0530 | [diff] [blame] | 6 | |
Simon Glass | 8251e03 | 2020-07-19 13:55:58 -0600 | [diff] [blame] | 7 | #include "rockchip-u-boot.dtsi" |
| 8 | |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 9 | / { |
| 10 | aliases { |
| 11 | mmc0 = &sdhci; |
| 12 | mmc1 = &sdmmc; |
Jagan Teki | 77c31a8 | 2020-05-09 22:26:23 +0530 | [diff] [blame] | 13 | pci0 = &pcie0; |
Simon Glass | 8251e03 | 2020-07-19 13:55:58 -0600 | [diff] [blame] | 14 | spi1 = &spi1; |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 15 | }; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 16 | |
Jonas Karlman | 747c957 | 2024-04-30 15:30:18 +0000 | [diff] [blame] | 17 | chosen { |
| 18 | u-boot,spl-boot-order = "same-as-spl", &sdhci, &sdmmc; |
| 19 | }; |
| 20 | |
Jonas Karlman | 47f7e5f | 2024-04-30 15:30:20 +0000 | [diff] [blame] | 21 | pmusgrf: syscon@ff330000 { |
| 22 | compatible = "rockchip,rk3399-pmusgrf", "syscon"; |
| 23 | reg = <0x0 0xff330000 0x0 0xe3d4>; |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 24 | bootph-all; |
Jonas Karlman | 47f7e5f | 2024-04-30 15:30:20 +0000 | [diff] [blame] | 25 | }; |
| 26 | |
| 27 | cic: syscon@ff620000 { |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 28 | compatible = "rockchip,rk3399-cic", "syscon"; |
| 29 | reg = <0x0 0xff620000 0x0 0x100>; |
Jonas Karlman | 47f7e5f | 2024-04-30 15:30:20 +0000 | [diff] [blame] | 30 | bootph-all; |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 31 | }; |
| 32 | |
| 33 | dfi: dfi@ff630000 { |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 34 | reg = <0x00 0xff630000 0x00 0x4000>; |
| 35 | compatible = "rockchip,rk3399-dfi"; |
| 36 | rockchip,pmu = <&pmugrf>; |
| 37 | clocks = <&cru PCLK_DDR_MON>; |
| 38 | clock-names = "pclk_ddr_mon"; |
Jonas Karlman | 47f7e5f | 2024-04-30 15:30:20 +0000 | [diff] [blame] | 39 | bootph-all; |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 40 | }; |
| 41 | |
Lin Jinhan | 3e714cf | 2020-03-31 17:39:57 +0800 | [diff] [blame] | 42 | rng: rng@ff8b8000 { |
Jonas Karlman | 64ba61f | 2024-02-17 00:22:36 +0000 | [diff] [blame] | 43 | compatible = "rockchip,rk3399-crypto"; |
Lin Jinhan | 3e714cf | 2020-03-31 17:39:57 +0800 | [diff] [blame] | 44 | reg = <0x0 0xff8b8000 0x0 0x1000>; |
Lin Jinhan | 3e714cf | 2020-03-31 17:39:57 +0800 | [diff] [blame] | 45 | }; |
| 46 | |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 47 | dmc: dmc { |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 48 | compatible = "rockchip,rk3399-dmc"; |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 49 | reg = <0x0 0xffa80000 0x0 0x0800 |
| 50 | 0x0 0xffa80800 0x0 0x1800 |
| 51 | 0x0 0xffa82000 0x0 0x2000 |
| 52 | 0x0 0xffa84000 0x0 0x1000 |
| 53 | 0x0 0xffa88000 0x0 0x0800 |
| 54 | 0x0 0xffa88800 0x0 0x1800 |
| 55 | 0x0 0xffa8a000 0x0 0x2000 |
| 56 | 0x0 0xffa8c000 0x0 0x1000>; |
Jonas Karlman | 47f7e5f | 2024-04-30 15:30:20 +0000 | [diff] [blame] | 57 | devfreq-events = <&dfi>; |
| 58 | interrupts = <GIC_SPI 1 IRQ_TYPE_LEVEL_HIGH 0>; |
| 59 | clocks = <&cru SCLK_DDRCLK>; |
| 60 | clock-names = "dmc_clk"; |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 61 | bootph-all; |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 62 | }; |
Simon Glass | 8251e03 | 2020-07-19 13:55:58 -0600 | [diff] [blame] | 63 | }; |
| 64 | |
Quentin Schulz | 12df9cf | 2022-09-02 15:10:54 +0200 | [diff] [blame] | 65 | #if defined(CONFIG_ROCKCHIP_SPI_IMAGE) && defined(CONFIG_HAS_ROM) |
Simon Glass | 8251e03 | 2020-07-19 13:55:58 -0600 | [diff] [blame] | 66 | &binman { |
Simon Glass | f126822 | 2023-01-07 14:07:17 -0700 | [diff] [blame] | 67 | multiple-images; |
Simon Glass | 8251e03 | 2020-07-19 13:55:58 -0600 | [diff] [blame] | 68 | rom { |
| 69 | filename = "u-boot.rom"; |
| 70 | size = <0x400000>; |
| 71 | pad-byte = <0xff>; |
| 72 | |
| 73 | mkimage { |
| 74 | args = "-n rk3399 -T rkspi"; |
| 75 | u-boot-spl { |
| 76 | }; |
| 77 | }; |
| 78 | u-boot-img { |
| 79 | offset = <0x40000>; |
| 80 | }; |
| 81 | u-boot { |
| 82 | offset = <0x300000>; |
| 83 | }; |
| 84 | fdtmap { |
| 85 | }; |
| 86 | }; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 87 | }; |
Simon Glass | f126822 | 2023-01-07 14:07:17 -0700 | [diff] [blame] | 88 | #endif /* CONFIG_ROCKCHIP_SPI_IMAGE && CONFIG_HAS_ROM */ |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 89 | |
Peter Robinson | 94fb4c4 | 2020-01-20 09:17:00 +0000 | [diff] [blame] | 90 | &cru { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 91 | bootph-all; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 92 | }; |
| 93 | |
Yifeng Zhao | d7e4c32 | 2021-11-01 12:43:47 +0800 | [diff] [blame] | 94 | &emmc_phy { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 95 | bootph-all; |
Yifeng Zhao | d7e4c32 | 2021-11-01 12:43:47 +0800 | [diff] [blame] | 96 | }; |
| 97 | |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 98 | &grf { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 99 | bootph-all; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 100 | }; |
| 101 | |
| 102 | &pinctrl { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 103 | bootph-all; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 104 | }; |
| 105 | |
Jagan Teki | 9b54585 | 2019-07-16 17:27:34 +0530 | [diff] [blame] | 106 | &pmu { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 107 | bootph-all; |
Jagan Teki | 9b54585 | 2019-07-16 17:27:34 +0530 | [diff] [blame] | 108 | }; |
| 109 | |
Jonas Karlman | 47f7e5f | 2024-04-30 15:30:20 +0000 | [diff] [blame] | 110 | &pmucru { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 111 | bootph-all; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 112 | }; |
| 113 | |
Jonas Karlman | 47f7e5f | 2024-04-30 15:30:20 +0000 | [diff] [blame] | 114 | &pmugrf { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 115 | bootph-all; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 116 | }; |
| 117 | |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 118 | &sdhci { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 119 | bootph-all; |
Jonas Karlman | 47f7e5f | 2024-04-30 15:30:20 +0000 | [diff] [blame] | 120 | max-frequency = <200000000>; |
| 121 | |
| 122 | /* mmc to sram can't do dma, prevent aborts transferring TF-A parts */ |
Jonas Karlman | f79c537 | 2023-05-06 17:41:11 +0000 | [diff] [blame] | 123 | u-boot,spl-fifo-mode; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 124 | }; |
| 125 | |
Jagan Teki | 208badd | 2019-03-11 13:50:03 +0530 | [diff] [blame] | 126 | &sdmmc { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 127 | bootph-all; |
Deepak Das | 4ef2ded | 2020-04-15 08:55:24 +0530 | [diff] [blame] | 128 | |
| 129 | /* mmc to sram can't do dma, prevent aborts transferring TF-A parts */ |
| 130 | u-boot,spl-fifo-mode; |
Jagan Teki | 208badd | 2019-03-11 13:50:03 +0530 | [diff] [blame] | 131 | }; |
Jagan Teki | 60c5fed | 2019-05-07 23:51:51 +0530 | [diff] [blame] | 132 | |
| 133 | &spi1 { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 134 | bootph-all; |
Jagan Teki | 60c5fed | 2019-05-07 23:51:51 +0530 | [diff] [blame] | 135 | }; |
Jagan Teki | 2ff51fd | 2019-06-21 00:25:02 +0530 | [diff] [blame] | 136 | |
Jagan Teki | 2ff51fd | 2019-06-21 00:25:02 +0530 | [diff] [blame] | 137 | &uart2 { |
Simon Glass | d3a98cb | 2023-02-13 08:56:33 -0700 | [diff] [blame] | 138 | bootph-all; |
Jonas Karlman | fab0bd3 | 2024-04-30 15:30:23 +0000 | [diff] [blame^] | 139 | clock-frequency = <24000000>; |
| 140 | }; |
| 141 | |
| 142 | &uart2c_xfer { |
| 143 | bootph-pre-sram; |
| 144 | bootph-pre-ram; |
Jagan Teki | 2ff51fd | 2019-06-21 00:25:02 +0530 | [diff] [blame] | 145 | }; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 146 | |
| 147 | &vopb { |
Jonas Karlman | 9851991 | 2024-04-30 15:30:21 +0000 | [diff] [blame] | 148 | bootph-some-ram; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 149 | }; |
| 150 | |
| 151 | &vopl { |
Jonas Karlman | 9851991 | 2024-04-30 15:30:21 +0000 | [diff] [blame] | 152 | bootph-some-ram; |
Peter Robinson | dd44a15 | 2019-11-09 20:30:05 +0000 | [diff] [blame] | 153 | }; |