1/* 2 * (C) Copyright 2017 Rockchip Electronics Co., Ltd 3 * 4 * SPDX-License-Identifier: GPL-2.0+ 5 */ 6 7/dts-v1/; 8#include "px30.dtsi" 9#include "px30-u-boot.dtsi" 10#include <dt-bindings/input/input.h> 11 12/ { 13 model = "Rockchip PX30 EVB"; 14 compatible = "rockchip,px30-evb", "rockchip,px30"; 15 16 chosen { 17 stdout-path = &uart2; 18 }; 19 20 dmc: dmc@20004000 { 21 u-boot,dm-pre-reloc; 22 compatible = "rockchip,px30-dmc", "syscon"; 23 reg = <0x0 0xff2a0000 0x0 0x1000>; 24 }; 25 26 adc-keys { 27 compatible = "adc-keys"; 28 io-channels = <&saradc 2>; 29 io-channel-names = "buttons"; 30 keyup-threshold-microvolt = <1800000>; 31 32 vol-up-key { 33 linux,code = <KEY_VOLUMEUP>; 34 label = "volume up"; 35 press-threshold-microvolt = <10000>; 36 }; 37 38 vol-down-key { 39 linux,code = <KEY_VOLUMEDOWN>; 40 label = "volume down"; 41 press-threshold-microvolt = <170000>; 42 }; 43 44 home-key { 45 linux,code = <KEY_HOME>; 46 label = "home"; 47 press-threshold-microvolt = <254000>; 48 }; 49 50 menu-key { 51 linux,code = <KEY_MENU>; 52 label = "menu"; 53 press-threshold-microvolt = <414000>; 54 }; 55 56 esc-key { 57 linux,code = <KEY_ESC>; 58 label = "esc"; 59 press-threshold-microvolt = <614000>; 60 }; 61 }; 62}; 63 64 65&i2c0 { 66 status = "okay"; 67 68 rk817: pmic@20 { 69 compatible = "rockchip,rk817"; 70 reg = <0x20>; 71 interrupt-parent = <&gpio0>; 72 interrupts = <7 IRQ_TYPE_LEVEL_LOW>; 73 pinctrl-names = "default"; 74 pinctrl-0 = <&pmic_int>; 75 rockchip,system-power-controller; 76 wakeup-source; 77 #clock-cells = <1>; 78 clock-output-names = "xin32k", "rk808-clkout2"; 79 80 vcc1-supply = <&vccsys>; 81 vcc2-supply = <&vccsys>; 82 vcc3-supply = <&vccsys>; 83 vcc4-supply = <&vccsys>; 84 vcc5-supply = <&vccsys>; 85 vcc6-supply = <&vccsys>; 86 vcc7-supply = <&vcc_3v0>; 87 vcc8-supply = <&vccsys>; 88 vcc9-supply = <&dcdc_boost>; 89 90 vccsys: vccsys{ 91 compatible = "regulator-fixed"; 92 regulator-name = "vcc3v8_sys"; 93 regulator-always-on; 94 regulator-boot-on; 95 regulator-min-microvolt = <3800000>; 96 regulator-max-microvolt = <3800000>; 97 }; 98 99 rk817_pin0_ts: rk817_pin0_ts { 100 pins = "gpio0"; 101 function = "pin_fun0"; 102 }; 103 104 rk817_pin0_gpio: rk817_pin0_gpio { 105 pins = "gpio0"; 106 function = "gpio"; 107 }; 108 109 rk817_pin1_gt: rk817_pin1_gt { 110 pins = "gpio1"; 111 function = "pin_fun0"; 112 }; 113 114 rk817_pin1_gpio: rk817_pin1_gpio { 115 pins = "gpio1"; 116 function = "gpio"; 117 }; 118 119 pwrkey { 120 status = "okay"; 121 }; 122 123 regulators { 124 vdd_arm: DCDC_REG1 { 125 regulator-always-on; 126 regulator-boot-on; 127 regulator-min-microvolt = <950000>; 128 regulator-max-microvolt = <1350000>; 129 regulator-ramp-delay = <6001>; 130 regulator-initial-mode = <0x1>; 131 regulator-name = "vdd_arm"; 132 regulator-state-mem { 133 regulator-on-in-suspend; 134 regulator-suspend-microvolt = <700000>; 135 }; 136 }; 137 138 vdd_logic: DCDC_REG2 { 139 regulator-always-on; 140 regulator-boot-on; 141 regulator-min-microvolt = <950000>; 142 regulator-max-microvolt = <1350000>; 143 regulator-ramp-delay = <6001>; 144 regulator-initial-mode = <0x1>; 145 regulator-name = "vdd_logic"; 146 regulator-state-mem { 147 regulator-off-in-suspend; 148 regulator-suspend-microvolt = <800000>; 149 }; 150 }; 151 152 vcc_ddr: DCDC_REG3 { 153 regulator-always-on; 154 regulator-boot-on; 155 regulator-initial-mode = <0x1>; 156 regulator-name = "vcc_ddr"; 157 regulator-state-mem { 158 regulator-on-in-suspend; 159 }; 160 }; 161 162 vcc_3v0: DCDC_REG4 { 163 regulator-always-on; 164 regulator-boot-on; 165 regulator-min-microvolt = <3000000>; 166 regulator-max-microvolt = <3000000>; 167 regulator-initial-mode = <0x1>; 168 regulator-name = "vcc_3v0"; 169 regulator-state-mem { 170 regulator-off-in-suspend; 171 regulator-suspend-microvolt = <3000000>; 172 }; 173 }; 174 175 vcc2v5_ddr: LDO_REG1 { 176 regulator-always-on; 177 regulator-boot-on; 178 regulator-min-microvolt = <2500000>; 179 regulator-max-microvolt = <2500000>; 180 regulator-name = "vcc2v5_ddr"; 181 regulator-state-mem { 182 regulator-on-in-suspend; 183 regulator-suspend-microvolt = <2500000>; 184 }; 185 }; 186 187 vcc1v8_soc: LDO_REG2 { 188 regulator-always-on; 189 regulator-boot-on; 190 regulator-min-microvolt = <1800000>; 191 regulator-max-microvolt = <1800000>; 192 193 regulator-name = "vcc1v8_soc"; 194 regulator-state-mem { 195 regulator-on-in-suspend; 196 regulator-suspend-microvolt = <1800000>; 197 }; 198 }; 199 200 vdd1v0_soc: LDO_REG3 { 201 regulator-always-on; 202 regulator-boot-on; 203 regulator-min-microvolt = <1000000>; 204 regulator-max-microvolt = <1000000>; 205 206 regulator-name = "vcc1v0_soc"; 207 regulator-state-mem { 208 regulator-off-in-suspend; 209 regulator-suspend-microvolt = <1000000>; 210 }; 211 }; 212 213 vcc3v0_pmu: LDO_REG4 { 214 regulator-always-on; 215 regulator-boot-on; 216 regulator-min-microvolt = <3000000>; 217 regulator-max-microvolt = <3000000>; 218 219 regulator-name = "vcc3v0_pmu"; 220 regulator-state-mem { 221 regulator-off-in-suspend; 222 regulator-suspend-microvolt = <3000000>; 223 }; 224 }; 225 226 vccio_sd: LDO_REG5 { 227 regulator-always-on; 228 regulator-boot-on; 229 regulator-min-microvolt = <3300000>; 230 regulator-max-microvolt = <3300000>; 231 232 regulator-name = "vccio_sd"; 233 regulator-state-mem { 234 regulator-on-in-suspend; 235 regulator-suspend-microvolt = <3300000>; 236 }; 237 }; 238 239 vcc_sd: LDO_REG6 { 240 regulator-always-on; 241 regulator-boot-on; 242 regulator-min-microvolt = <3300000>; 243 regulator-max-microvolt = <3300000>; 244 245 regulator-name = "vcc_sd"; 246 regulator-state-mem { 247 regulator-on-in-suspend; 248 regulator-suspend-microvolt = <3300000>; 249 }; 250 }; 251 252 vcc2v8_dvp: LDO_REG7 { 253 regulator-always-on; 254 regulator-boot-on; 255 regulator-min-microvolt = <2800000>; 256 regulator-max-microvolt = <2800000>; 257 258 regulator-name = "vcc2v8_dvp"; 259 regulator-state-mem { 260 regulator-off-in-suspend; 261 regulator-suspend-microvolt = <2800000>; 262 }; 263 }; 264 265 vcc1v8_dvp: LDO_REG8 { 266 regulator-always-on; 267 regulator-boot-on; 268 regulator-min-microvolt = <1800000>; 269 regulator-max-microvolt = <1800000>; 270 271 regulator-name = "vcc1v8_dvp"; 272 regulator-state-mem { 273 regulator-on-in-suspend; 274 regulator-suspend-microvolt = <1800000>; 275 }; 276 }; 277 278 vdd1v5_dvp: LDO_REG9 { 279 regulator-always-on; 280 regulator-boot-on; 281 regulator-min-microvolt = <1500000>; 282 regulator-max-microvolt = <1500000>; 283 284 regulator-name = "vdd1v5_dvp"; 285 regulator-state-mem { 286 regulator-off-in-suspend; 287 regulator-suspend-microvolt = <1500000>; 288 }; 289 }; 290 291 dcdc_boost: BOOST { 292 regulator-always-on; 293 regulator-boot-on; 294 regulator-min-microvolt = <4700000>; 295 regulator-max-microvolt = <5400000>; 296 regulator-name = "boost"; 297 }; 298 299 otg_switch: OTG_SWITCH { 300 regulator-always-on; 301 regulator-boot-on; 302 regulator-name = "otg_switch"; 303 }; 304 }; 305 306 battery { 307 compatible = "rk817,battery"; 308 ocv_table = <3500 3625 3685 3697 3718 3735 3748 309 3760 3774 3788 3802 3816 3834 3853 310 3877 3908 3946 3975 4018 4071 4106>; 311 design_capacity = <2500>; 312 design_qmax = <2750>; 313 bat_res = <100>; 314 sleep_enter_current = <300>; 315 sleep_exit_current = <300>; 316 sleep_filter_current = <100>; 317 power_off_thresd = <3500>; 318 zero_algorithm_vol = <3850>; 319 max_soc_offset = <60>; 320 monitor_sec = <5>; 321 sample_res = <10>; 322 virtual_power = <1>; 323 }; 324 325 charger { 326 compatible = "rk817,charger"; 327 min_input_voltage = <4500>; 328 max_input_current = <1500>; 329 max_chrg_current = <1300>; 330 max_chrg_voltage = <4200>; 331 chrg_term_mode = <1>; 332 chrg_finish_cur = <300>; 333 virtual_power = <0>; 334 dc_det_adc = <0>; 335 }; 336 }; 337}; 338 339&emmc { 340 u-boot,dm-pre-reloc; 341 fifo-mode; 342 bus-width = <8>; 343 cap-mmc-highspeed; 344 supports-emmc; 345 disable-wp; 346 non-removable; 347 num-slots = <1>; 348 pinctrl-names = "default"; 349 pinctrl-0 = <&emmc_clk &emmc_cmd &emmc_bus8>; 350 status = "okay"; 351}; 352 353&saradc { 354 status = "okay"; 355}; 356 357&pinctrl { 358 pmic { 359 pmic_int: pmic_int { 360 rockchip,pins = 361 <0 7 RK_FUNC_GPIO &pcfg_pull_up>; 362 }; 363 }; 364}; 365 366&u2phy { 367 status = "okay"; 368}; 369 370&u2phy_otg { 371 status = "okay"; 372}; 373 374&u2phy_host { 375 status = "okay"; 376}; 377