Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 1 | // SPDX-License-Identifier: (GPL-2.0+ OR MIT) |
Kever Yang | b647442 | 2017-06-23 17:17:51 +0800 | [diff] [blame] | 2 | |
| 3 | /dts-v1/; |
| 4 | |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 5 | #include <dt-bindings/input/input.h> |
| 6 | #include "rk3229.dtsi" |
Kever Yang | b647442 | 2017-06-23 17:17:51 +0800 | [diff] [blame] | 7 | |
| 8 | / { |
| 9 | model = "Rockchip RK3229 Evaluation board"; |
| 10 | compatible = "rockchip,rk3229-evb", "rockchip,rk3229"; |
| 11 | |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 12 | aliases { |
| 13 | mmc0 = &emmc; |
| 14 | }; |
| 15 | |
Kever Yang | b647442 | 2017-06-23 17:17:51 +0800 | [diff] [blame] | 16 | memory@60000000 { |
| 17 | device_type = "memory"; |
| 18 | reg = <0x60000000 0x40000000>; |
| 19 | }; |
| 20 | |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 21 | dc_12v: dc-12v-regulator { |
| 22 | compatible = "regulator-fixed"; |
| 23 | regulator-name = "dc_12v"; |
| 24 | regulator-always-on; |
| 25 | regulator-boot-on; |
| 26 | regulator-min-microvolt = <12000000>; |
| 27 | regulator-max-microvolt = <12000000>; |
| 28 | }; |
| 29 | |
Kever Yang | b647442 | 2017-06-23 17:17:51 +0800 | [diff] [blame] | 30 | ext_gmac: ext_gmac { |
| 31 | compatible = "fixed-clock"; |
| 32 | clock-frequency = <125000000>; |
| 33 | clock-output-names = "ext_gmac"; |
| 34 | #clock-cells = <0>; |
| 35 | }; |
| 36 | |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 37 | vcc_host: vcc-host-regulator { |
| 38 | compatible = "regulator-fixed"; |
| 39 | enable-active-high; |
| 40 | gpio = <&gpio3 RK_PC4 GPIO_ACTIVE_HIGH>; |
| 41 | pinctrl-names = "default"; |
| 42 | pinctrl-0 = <&host_vbus_drv>; |
| 43 | regulator-name = "vcc_host"; |
| 44 | regulator-always-on; |
| 45 | regulator-boot-on; |
| 46 | vin-supply = <&vcc_sys>; |
| 47 | }; |
| 48 | |
Kever Yang | b647442 | 2017-06-23 17:17:51 +0800 | [diff] [blame] | 49 | vcc_phy: vcc-phy-regulator { |
| 50 | compatible = "regulator-fixed"; |
| 51 | enable-active-high; |
| 52 | regulator-name = "vcc_phy"; |
| 53 | regulator-min-microvolt = <1800000>; |
| 54 | regulator-max-microvolt = <1800000>; |
| 55 | regulator-always-on; |
| 56 | regulator-boot-on; |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 57 | vin-supply = <&vccio_1v8>; |
Kever Yang | b647442 | 2017-06-23 17:17:51 +0800 | [diff] [blame] | 58 | }; |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 59 | |
| 60 | vcc_sys: vcc-sys-regulator { |
| 61 | compatible = "regulator-fixed"; |
| 62 | regulator-name = "vcc_sys"; |
| 63 | regulator-always-on; |
| 64 | regulator-boot-on; |
| 65 | regulator-min-microvolt = <5000000>; |
| 66 | regulator-max-microvolt = <5000000>; |
| 67 | vin-supply = <&dc_12v>; |
| 68 | }; |
| 69 | |
| 70 | vccio_1v8: vccio-1v8-regulator { |
| 71 | compatible = "regulator-fixed"; |
| 72 | regulator-name = "vccio_1v8"; |
| 73 | regulator-min-microvolt = <1800000>; |
| 74 | regulator-max-microvolt = <1800000>; |
| 75 | regulator-always-on; |
| 76 | vin-supply = <&vcc_sys>; |
| 77 | }; |
| 78 | |
| 79 | vccio_3v3: vccio-3v3-regulator { |
| 80 | compatible = "regulator-fixed"; |
| 81 | regulator-name = "vccio_3v3"; |
| 82 | regulator-min-microvolt = <3300000>; |
| 83 | regulator-max-microvolt = <3300000>; |
| 84 | regulator-always-on; |
| 85 | vin-supply = <&vcc_sys>; |
| 86 | }; |
| 87 | |
| 88 | vdd_arm: vdd-arm-regulator { |
| 89 | compatible = "pwm-regulator"; |
| 90 | pwms = <&pwm1 0 25000 1>; |
| 91 | pwm-supply = <&vcc_sys>; |
| 92 | regulator-name = "vdd_arm"; |
| 93 | regulator-min-microvolt = <950000>; |
| 94 | regulator-max-microvolt = <1400000>; |
| 95 | regulator-always-on; |
| 96 | regulator-boot-on; |
| 97 | }; |
| 98 | |
| 99 | vdd_log: vdd-log-regulator { |
| 100 | compatible = "pwm-regulator"; |
| 101 | pwms = <&pwm2 0 25000 1>; |
| 102 | pwm-supply = <&vcc_sys>; |
| 103 | regulator-name = "vdd_log"; |
| 104 | regulator-min-microvolt = <1000000>; |
| 105 | regulator-max-microvolt = <1300000>; |
| 106 | regulator-always-on; |
| 107 | regulator-boot-on; |
| 108 | }; |
| 109 | |
| 110 | gpio_keys { |
| 111 | compatible = "gpio-keys"; |
| 112 | autorepeat; |
| 113 | pinctrl-names = "default"; |
| 114 | pinctrl-0 = <&pwr_key>; |
| 115 | |
| 116 | power_key: power-key { |
| 117 | label = "GPIO Key Power"; |
| 118 | gpios = <&gpio3 23 GPIO_ACTIVE_LOW>; |
| 119 | linux,code = <KEY_POWER>; |
| 120 | debounce-interval = <100>; |
| 121 | wakeup-source; |
| 122 | }; |
| 123 | }; |
| 124 | }; |
| 125 | |
| 126 | &cpu0 { |
| 127 | cpu-supply = <&vdd_arm>; |
| 128 | }; |
| 129 | |
| 130 | &cpu1 { |
| 131 | cpu-supply = <&vdd_arm>; |
| 132 | }; |
| 133 | |
| 134 | &cpu2 { |
| 135 | cpu-supply = <&vdd_arm>; |
| 136 | }; |
| 137 | |
| 138 | &cpu3 { |
| 139 | cpu-supply = <&vdd_arm>; |
| 140 | }; |
| 141 | |
| 142 | &emmc { |
| 143 | cap-mmc-highspeed; |
| 144 | non-removable; |
| 145 | status = "okay"; |
Kever Yang | b647442 | 2017-06-23 17:17:51 +0800 | [diff] [blame] | 146 | }; |
| 147 | |
Kever Yang | b647442 | 2017-06-23 17:17:51 +0800 | [diff] [blame] | 148 | &gmac { |
| 149 | assigned-clocks = <&cru SCLK_MAC_EXTCLK>, <&cru SCLK_MAC>; |
| 150 | assigned-clock-parents = <&ext_gmac>, <&cru SCLK_MAC_EXTCLK>; |
| 151 | clock_in_out = "input"; |
| 152 | phy-supply = <&vcc_phy>; |
| 153 | phy-mode = "rgmii"; |
| 154 | pinctrl-names = "default"; |
| 155 | pinctrl-0 = <&rgmii_pins>; |
| 156 | snps,reset-gpio = <&gpio2 RK_PD0 GPIO_ACTIVE_LOW>; |
| 157 | snps,reset-active-low; |
| 158 | snps,reset-delays-us = <0 10000 1000000>; |
| 159 | tx_delay = <0x30>; |
| 160 | rx_delay = <0x10>; |
| 161 | status = "okay"; |
| 162 | }; |
| 163 | |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 164 | &io_domains { |
| 165 | status = "okay"; |
| 166 | |
| 167 | vccio1-supply = <&vccio_3v3>; |
| 168 | vccio2-supply = <&vccio_1v8>; |
| 169 | vccio4-supply = <&vccio_3v3>; |
| 170 | }; |
| 171 | |
| 172 | &pinctrl { |
| 173 | keys { |
| 174 | pwr_key: pwr-key { |
| 175 | rockchip,pins = <3 RK_PC7 RK_FUNC_GPIO &pcfg_pull_up>; |
| 176 | }; |
| 177 | }; |
| 178 | |
| 179 | usb { |
| 180 | host_vbus_drv: host-vbus-drv { |
| 181 | rockchip,pins = <3 RK_PC4 RK_FUNC_GPIO &pcfg_pull_none>; |
| 182 | }; |
| 183 | }; |
| 184 | }; |
| 185 | |
| 186 | &pwm1 { |
Kever Yang | b647442 | 2017-06-23 17:17:51 +0800 | [diff] [blame] | 187 | status = "okay"; |
| 188 | }; |
| 189 | |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 190 | &pwm2 { |
Kever Yang | a2a1bfe | 2017-07-21 18:21:09 +0800 | [diff] [blame] | 191 | status = "okay"; |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 192 | }; |
| 193 | |
| 194 | &tsadc { |
| 195 | rockchip,hw-tshut-mode = <0>; /* tshut mode 0:CRU 1:GPIO */ |
| 196 | status = "okay"; |
Kever Yang | a2a1bfe | 2017-07-21 18:21:09 +0800 | [diff] [blame] | 197 | }; |
| 198 | |
Kever Yang | b647442 | 2017-06-23 17:17:51 +0800 | [diff] [blame] | 199 | &uart2 { |
| 200 | status = "okay"; |
| 201 | }; |
Meng Dongyang | 0124062 | 2017-07-13 10:59:54 +0800 | [diff] [blame] | 202 | |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 203 | &u2phy0 { |
| 204 | status = "okay"; |
| 205 | |
| 206 | u2phy0_otg: otg-port { |
| 207 | status = "okay"; |
| 208 | }; |
| 209 | |
| 210 | u2phy0_host: host-port { |
| 211 | phy-supply = <&vcc_host>; |
| 212 | status = "okay"; |
| 213 | }; |
| 214 | }; |
| 215 | |
| 216 | &u2phy1 { |
| 217 | status = "okay"; |
| 218 | |
| 219 | u2phy1_otg: otg-port { |
| 220 | phy-supply = <&vcc_host>; |
| 221 | status = "okay"; |
| 222 | }; |
| 223 | |
| 224 | u2phy1_host: host-port { |
| 225 | phy-supply = <&vcc_host>; |
| 226 | status = "okay"; |
| 227 | }; |
| 228 | }; |
| 229 | |
| 230 | &usb_host0_ehci { |
| 231 | status = "okay"; |
| 232 | }; |
| 233 | |
| 234 | &usb_host0_ohci { |
| 235 | status = "okay"; |
| 236 | }; |
| 237 | |
| 238 | &usb_host1_ehci { |
| 239 | status = "okay"; |
| 240 | }; |
| 241 | |
| 242 | &usb_host1_ohci { |
| 243 | status = "okay"; |
| 244 | }; |
| 245 | |
| 246 | &usb_host2_ehci { |
| 247 | status = "okay"; |
| 248 | }; |
| 249 | |
| 250 | &usb_host2_ohci { |
| 251 | status = "okay"; |
| 252 | }; |
| 253 | |
Johan Jonker | 6980e83 | 2022-04-15 23:21:35 +0200 | [diff] [blame] | 254 | &usb_otg { |
Johan Jonker | d3cb756 | 2022-04-15 23:21:36 +0200 | [diff] [blame] | 255 | status = "okay"; |
Meng Dongyang | 0124062 | 2017-07-13 10:59:54 +0800 | [diff] [blame] | 256 | }; |