1/* 2 * Copyright (c) 2017 Fuzhou Rockchip Electronics Co., Ltd 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/dts-v1/; 44#include "rk3288-evb.dtsi" 45#include "rk3288-android.dtsi" 46 47/ { 48 compatible = "rockchip,rk3288-evb-android-rk818-hdmi", "rockchip,rk3288"; 49 50 sdio_pwrseq: sdio-pwrseq { 51 compatible = "mmc-pwrseq-simple"; 52 clocks = <&rk818 1>; 53 clock-names = "ext_clock"; 54 55 /* 56 * On the module itself this is one of these (depending 57 * on the actual card populated): 58 * - SDIO_RESET_L_WL_REG_ON 59 * - PDN (power down when low) 60 */ 61 reset-gpios = <&gpio4 28 GPIO_ACTIVE_LOW>; 62 }; 63 64 wireless-bluetooth { 65 clocks = <&rk818 1>; 66 clock-names = "ext_clock"; 67 }; 68 69 /delete-node/ sdmmc-regulator; 70 71 vcc_lcd: vcc-lcd { 72 compatible = "regulator-fixed"; 73 regulator-boot-on; 74 enable-active-high; 75 gpio = <&gpio7 3 GPIO_ACTIVE_HIGH>; 76 pinctrl-names = "default"; 77 pinctrl-0 = <&lcd_en>; 78 regulator-name = "vcc_lcd"; 79 vin-supply = <&vcc_io>; 80 }; 81 82 xin32k: xin32k { 83 compatible = "fixed-clock"; 84 clock-frequency = <32768>; 85 clock-output-names = "xin32k"; 86 #clock-cells = <0>; 87 }; 88}; 89 90&cpu0 { 91 cpu-supply = <&vdd_cpu>; 92}; 93 94&dfi { 95 status = "okay"; 96}; 97 98&dmc { 99 center-supply = <&vdd_logic>; 100 status = "okay"; 101}; 102 103&gpu { 104 status = "okay"; 105 mali-supply = <&vdd_gpu>; 106}; 107 108&hdmi { 109 status = "okay"; 110}; 111 112&hdmi_analog_sound { 113 status = "okay"; 114}; 115 116&hdmi_in_vopl { 117 status = "disabled"; 118}; 119 120&hdmi_in_vopb { 121 status = "okay"; 122}; 123 124&i2c0 { 125 clock-frequency = <400000>; 126 127 vdd_cpu: syr827@40 { 128 compatible = "silergy,syr827"; 129 reg = <0x40>; 130 vin-supply = <&vcc_sys>; 131 regulator-compatible = "fan53555-reg"; 132 pinctrl-0 = <&vsel1_gpio>; 133 vsel-gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>; 134 regulator-name = "vdd_cpu"; 135 regulator-min-microvolt = <712500>; 136 regulator-max-microvolt = <1500000>; 137 regulator-ramp-delay = <1000>; 138 fcs,suspend-voltage-selector = <1>; 139 regulator-always-on; 140 regulator-boot-on; 141 regulator-initial-state = <3>; 142 regulator-state-mem { 143 regulator-off-in-suspend; 144 }; 145 }; 146 147 rk818: pmic@1c { 148 compatible = "rockchip,rk818"; 149 reg = <0x1c>; 150 status = "okay"; 151 152 clock-output-names = "rk818-clkout1", "wifibt_32kin"; 153 interrupt-parent = <&gpio0>; 154 interrupts = <4 IRQ_TYPE_LEVEL_LOW>; 155 pinctrl-names = "default"; 156 pinctrl-0 = <&pmic_int>; 157 rockchip,system-power-controller; 158 wakeup-source; 159 #clock-cells = <1>; 160 161 vcc1-supply = <&vcc_sys>; 162 vcc2-supply = <&vcc_sys>; 163 vcc3-supply = <&vcc_sys>; 164 vcc4-supply = <&vcc_sys>; 165 vcc6-supply = <&vcc_sys>; 166 vcc7-supply = <&vcc_sys>; 167 vcc8-supply = <&vcc_sys>; 168 vcc9-supply = <&vcc_io>; 169 boost-supply = <&vcc_sys>; 170 h_5v-supply = <&boost>; 171 172 regulators { 173 vdd_logic: DCDC_REG1 { 174 regulator-name = "vdd_logic"; 175 regulator-always-on; 176 regulator-boot-on; 177 regulator-min-microvolt = <800000>; 178 regulator-max-microvolt = <1250000>; 179 regulator-ramp-delay = <6001>; 180 regulator-state-mem { 181 regulator-on-in-suspend; 182 regulator-suspend-microvolt = <1000000>; 183 }; 184 }; 185 186 vdd_gpu: DCDC_REG2 { 187 regulator-name = "vdd_gpu"; 188 regulator-always-on; 189 regulator-boot-on; 190 regulator-min-microvolt = <800000>; 191 regulator-max-microvolt = <1250000>; 192 regulator-ramp-delay = <6001>; 193 regulator-state-mem { 194 regulator-on-in-suspend; 195 regulator-suspend-microvolt = <1000000>; 196 }; 197 }; 198 199 vcc_ddr: DCDC_REG3 { 200 regulator-always-on; 201 regulator-boot-on; 202 regulator-name = "vcc_ddr"; 203 regulator-state-mem { 204 regulator-on-in-suspend; 205 }; 206 }; 207 208 vcc_io: DCDC_REG4 { 209 regulator-always-on; 210 regulator-boot-on; 211 regulator-min-microvolt = <3300000>; 212 regulator-max-microvolt = <3300000>; 213 regulator-name = "vcc_io"; 214 regulator-state-mem { 215 regulator-off-in-suspend; 216 }; 217 }; 218 219 boost: DCDC_BOOST { 220 regulator-always-on; 221 regulator-boot-on; 222 regulator-min-microvolt = <5000000>; 223 regulator-max-microvolt = <5000000>; 224 regulator-name = "boost"; 225 regulator-state-mem { 226 regulator-on-in-suspend; 227 }; 228 }; 229 230 vcca_codec: LDO_REG1 { 231 regulator-always-on; 232 regulator-boot-on; 233 regulator-min-microvolt = <3300000>; 234 regulator-max-microvolt = <3300000>; 235 regulator-name = "vcca_codec"; 236 regulator-state-mem { 237 regulator-off-in-suspend; 238 }; 239 }; 240 241 vcc_tp: LDO_REG2 { 242 regulator-always-on; 243 regulator-boot-on; 244 regulator-min-microvolt = <3300000>; 245 regulator-max-microvolt = <3300000>; 246 regulator-name = "vcc_tp"; 247 regulator-state-mem { 248 regulator-off-in-suspend; 249 }; 250 }; 251 252 vdd_10: LDO_REG3 { 253 regulator-always-on; 254 regulator-boot-on; 255 regulator-min-microvolt = <1000000>; 256 regulator-max-microvolt = <1000000>; 257 regulator-name = "vdd_10"; 258 regulator-state-mem { 259 regulator-on-in-suspend; 260 regulator-suspend-microvolt = <1000000>; 261 }; 262 }; 263 264 vcc18_lcd: LDO_REG4 { 265 regulator-always-on; 266 regulator-boot-on; 267 regulator-min-microvolt = <1800000>; 268 regulator-max-microvolt = <1800000>; 269 regulator-name = "vcc18_lcd"; 270 regulator-state-mem { 271 regulator-off-in-suspend; 272 }; 273 }; 274 275 vccio_pmu: LDO_REG5 { 276 regulator-always-on; 277 regulator-boot-on; 278 regulator-min-microvolt = <3300000>; 279 regulator-max-microvolt = <3300000>; 280 regulator-name = "vccio_pmu"; 281 regulator-state-mem { 282 regulator-on-in-suspend; 283 regulator-suspend-microvolt = <3300000>; 284 }; 285 }; 286 287 vdd10_lcd: LDO_REG6 { 288 regulator-always-on; 289 regulator-boot-on; 290 regulator-min-microvolt = <1000000>; 291 regulator-max-microvolt = <1000000>; 292 regulator-name = "vdd10_lcd"; 293 regulator-state-mem { 294 regulator-off-in-suspend; 295 }; 296 }; 297 298 vcc_18: LDO_REG7 { 299 regulator-always-on; 300 regulator-boot-on; 301 regulator-min-microvolt = <1800000>; 302 regulator-max-microvolt = <1800000>; 303 regulator-name = "vcc_18"; 304 regulator-state-mem { 305 regulator-on-in-suspend; 306 regulator-suspend-microvolt = <1800000>; 307 }; 308 }; 309 310 vccio_wl: LDO_REG8 { 311 regulator-always-on; 312 regulator-boot-on; 313 regulator-min-microvolt = <1800000>; 314 regulator-max-microvolt = <3300000>; 315 regulator-name = "vccio_wl"; 316 regulator-state-mem { 317 regulator-on-in-suspend; 318 regulator-suspend-microvolt = <3300000>; 319 }; 320 }; 321 322 vccio_sd: LDO_REG9 { 323 regulator-always-on; 324 regulator-boot-on; 325 regulator-min-microvolt = <1800000>; 326 regulator-max-microvolt = <3300000>; 327 regulator-name = "vccio_sd"; 328 regulator-state-mem { 329 regulator-on-in-suspend; 330 regulator-suspend-microvolt = <3300000>; 331 }; 332 }; 333 334 vcc_sd: SWITCH_REG { 335 regulator-always-on; 336 regulator-boot-on; 337 regulator-name = "vcc_sd"; 338 regulator-state-mem { 339 regulator-on-in-suspend; 340 }; 341 }; 342 343 h_5v: HDMI_SWITCH { 344 regulator-always-on; 345 regulator-boot-on; 346 regulator-name = "h_5v"; 347 regulator-state-mem { 348 regulator-on-in-suspend; 349 }; 350 }; 351 }; 352 }; 353}; 354 355&i2c1 { 356 status = "okay"; 357 clock-frequency = <400000>; 358 359 mpu6050@68 { 360 compatible = "invensense,mpu6050"; 361 status = "okay"; 362 pinctrl-names = "default"; 363 pinctrl-0 = <&mpu6050_irq_gpio>; 364 reg = <0x68>; 365 irq-gpio = <&gpio8 0 IRQ_TYPE_EDGE_RISING>; 366 mpu-int_config = <0x10>; 367 mpu-level_shifter = <0>; 368 mpu-orientation = <0 1 0 1 0 0 0 0 1>; 369 orientation-x= <0>; 370 orientation-y= <1>; 371 orientation-z= <0>; 372 support-hw-poweroff = <1>; 373 mpu-debug = <1>; 374 }; 375}; 376 377&lvds_panel { 378 power-supply = <&vcc_lcd>; 379}; 380 381&rockchip_suspend { 382 status = "okay"; 383}; 384 385&tsadc { 386 rockchip,hw-tshut-polarity = <1>; /* tshut polarity 0:LOW 1:HIGH */ 387}; 388 389&pinctrl { 390 lcd { 391 lcd_en: lcd-en { 392 rockchip,pins = <7 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>; 393 }; 394 }; 395 396 mpu6050 { 397 mpu6050_irq_gpio: mpu6050-irq-gpio { 398 rockchip,pins = <8 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>; 399 }; 400 }; 401 402 pmic { 403 pmic_int: pmic-int { 404 rockchip,pins = <0 RK_PA4 RK_FUNC_GPIO &pcfg_pull_up>; 405 }; 406 vsel1_gpio: vsel1-gpio { 407 rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_down>; 408 }; 409 }; 410}; 411