Klaus Goger | fce152a6 | 2017-12-15 12:44:27 +0100 | [diff] [blame] | 1 | // SPDX-License-Identifier: (GPL-2.0+ OR MIT) |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 2 | |
| 3 | /dts-v1/; |
| 4 | |
| 5 | #include "rk3036.dtsi" |
| 6 | |
| 7 | / { |
| 8 | model = "Rockchip RK3036 KylinBoard"; |
| 9 | compatible = "rockchip,rk3036-kylin", "rockchip,rk3036"; |
| 10 | |
Javier Martinez Canillas | 4c2b306 | 2016-09-09 10:01:06 -0400 | [diff] [blame] | 11 | memory@60000000 { |
Heiko Stuebner | fbf1504 | 2016-03-30 17:33:24 +0200 | [diff] [blame] | 12 | device_type = "memory"; |
| 13 | reg = <0x60000000 0x20000000>; |
| 14 | }; |
| 15 | |
Caesar Wang | fe25313 | 2016-01-28 16:43:30 +0800 | [diff] [blame] | 16 | leds: gpio-leds { |
| 17 | compatible = "gpio-leds"; |
| 18 | |
| 19 | work { |
Andy Yan | e9e79d5 | 2016-10-22 20:54:55 +0800 | [diff] [blame] | 20 | gpios = <&gpio2 RK_PD6 GPIO_ACTIVE_HIGH>; |
Caesar Wang | fe25313 | 2016-01-28 16:43:30 +0800 | [diff] [blame] | 21 | label = "kylin:red:led"; |
| 22 | pinctrl-names = "default"; |
| 23 | pinctrl-0 = <&led_ctl>; |
| 24 | }; |
| 25 | }; |
| 26 | |
Caesar Wang | 4a9d0b0 | 2016-01-15 21:49:53 +0800 | [diff] [blame] | 27 | sdio_pwrseq: sdio-pwrseq { |
| 28 | compatible = "mmc-pwrseq-simple"; |
| 29 | pinctrl-names = "default"; |
| 30 | pinctrl-0 = <&bt_wake_h>; |
| 31 | |
| 32 | /* |
| 33 | * On the module itself this is one of these (depending |
| 34 | * on the actual card populated): |
| 35 | * - SDIO_RESET_L_WL_REG_ON |
| 36 | * - SDIO_RESET_L_WL_RST |
| 37 | * - SDIO_RESET_L_BT_EN |
| 38 | */ |
Andy Yan | e9e79d5 | 2016-10-22 20:54:55 +0800 | [diff] [blame] | 39 | reset-gpios = <&gpio0 RK_PD2 GPIO_ACTIVE_LOW>, /* WL_REG_ON */ |
| 40 | <&gpio0 RK_PD3 GPIO_ACTIVE_LOW>, /* WL_RST */ |
| 41 | <&gpio2 RK_PB1 GPIO_ACTIVE_LOW>; /* BT_EN */ |
Caesar Wang | 4a9d0b0 | 2016-01-15 21:49:53 +0800 | [diff] [blame] | 42 | }; |
| 43 | |
Caesar Wang | 47bf3a5 | 2016-01-07 16:25:45 +0800 | [diff] [blame] | 44 | sound { |
| 45 | compatible = "simple-audio-card"; |
| 46 | simple-audio-card,format = "i2s"; |
| 47 | simple-audio-card,name = "rockchip,rt5616-codec"; |
Xing Zheng | f6bb9d5f | 2016-01-29 16:49:21 +0800 | [diff] [blame] | 48 | simple-audio-card,mclk-fs = <512>; |
Caesar Wang | 47bf3a5 | 2016-01-07 16:25:45 +0800 | [diff] [blame] | 49 | simple-audio-card,widgets = |
| 50 | "Microphone", "Microphone Jack", |
| 51 | "Headphone", "Headphone Jack"; |
| 52 | simple-audio-card,routing = |
| 53 | "MIC1", "Microphone Jack", |
| 54 | "MIC2", "Microphone Jack", |
| 55 | "Microphone Jack", "micbias1", |
| 56 | "Headphone Jack", "HPOL", |
| 57 | "Headphone Jack", "HPOR"; |
| 58 | |
| 59 | simple-audio-card,cpu { |
| 60 | sound-dai = <&i2s>; |
| 61 | }; |
| 62 | |
| 63 | simple-audio-card,codec { |
| 64 | sound-dai = <&rt5616>; |
| 65 | }; |
| 66 | }; |
| 67 | |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 68 | vcc_sys: vsys-regulator { |
| 69 | compatible = "regulator-fixed"; |
| 70 | regulator-name = "vcc_sys"; |
| 71 | regulator-min-microvolt = <5000000>; |
| 72 | regulator-max-microvolt = <5000000>; |
| 73 | regulator-always-on; |
| 74 | regulator-boot-on; |
| 75 | }; |
| 76 | }; |
| 77 | |
| 78 | &acodec { |
| 79 | status = "okay"; |
| 80 | }; |
| 81 | |
Xing Zheng | af671e7 | 2016-03-14 16:02:00 +0800 | [diff] [blame] | 82 | &emac { |
| 83 | pinctrl-names = "default"; |
| 84 | pinctrl-0 = <&emac_xfer>, <&emac_mdio>; |
| 85 | phy = <&phy0>; |
Andy Yan | e9e79d5 | 2016-10-22 20:54:55 +0800 | [diff] [blame] | 86 | phy-reset-gpios = <&gpio2 RK_PC6 GPIO_ACTIVE_LOW>; /* PHY_RST */ |
Xing Zheng | af671e7 | 2016-03-14 16:02:00 +0800 | [diff] [blame] | 87 | phy-reset-duration = <10>; /* millisecond */ |
| 88 | |
| 89 | status = "okay"; |
| 90 | |
| 91 | phy0: ethernet-phy@0 { |
| 92 | reg = <0>; |
| 93 | }; |
| 94 | }; |
| 95 | |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 96 | &emmc { |
| 97 | status = "okay"; |
| 98 | }; |
| 99 | |
Heiko Stuebner | 3584473 | 2017-07-12 19:07:24 +0200 | [diff] [blame] | 100 | &gpu { |
| 101 | mali-supply = <&vdd_gpu>; |
| 102 | status = "okay"; |
| 103 | }; |
| 104 | |
Caesar Wang | cef0abe | 2016-02-02 11:40:50 +0800 | [diff] [blame] | 105 | &hdmi { |
| 106 | status = "okay"; |
| 107 | }; |
| 108 | |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 109 | &i2c1 { |
| 110 | clock-frequency = <400000>; |
| 111 | |
| 112 | status = "okay"; |
| 113 | |
| 114 | rk808: pmic@1b { |
| 115 | compatible = "rockchip,rk808"; |
| 116 | reg = <0x1b>; |
| 117 | interrupt-parent = <&gpio2>; |
Andy Yan | e9e79d5 | 2016-10-22 20:54:55 +0800 | [diff] [blame] | 118 | interrupts = <RK_PA2 IRQ_TYPE_LEVEL_LOW>; |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 119 | pinctrl-names = "default"; |
| 120 | pinctrl-0 = <&pmic_int &global_pwroff>; |
| 121 | rockchip,system-power-controller; |
| 122 | wakeup-source; |
| 123 | #clock-cells = <1>; |
| 124 | clock-output-names = "xin32k", "rk808-clkout2"; |
| 125 | |
| 126 | vcc1-supply = <&vcc_sys>; |
| 127 | vcc2-supply = <&vcc_sys>; |
| 128 | vcc3-supply = <&vcc_sys>; |
| 129 | vcc4-supply = <&vcc_sys>; |
| 130 | vcc6-supply = <&vcc_sys>; |
| 131 | vcc7-supply = <&vcc_sys>; |
| 132 | vcc8-supply = <&vcc_18>; |
| 133 | vcc9-supply = <&vcc_io>; |
| 134 | vcc10-supply = <&vcc_io>; |
| 135 | vcc11-supply = <&vcc_sys>; |
| 136 | vcc12-supply = <&vcc_io>; |
| 137 | vddio-supply = <&vccio_pmu>; |
| 138 | |
| 139 | regulators { |
| 140 | vdd_cpu: DCDC_REG1 { |
| 141 | regulator-always-on; |
| 142 | regulator-boot-on; |
| 143 | regulator-min-microvolt = <750000>; |
| 144 | regulator-max-microvolt = <1350000>; |
| 145 | regulator-name = "vdd_arm"; |
| 146 | regulator-state-mem { |
| 147 | regulator-off-in-suspend; |
| 148 | }; |
| 149 | }; |
| 150 | |
| 151 | vdd_gpu: DCDC_REG2 { |
| 152 | regulator-always-on; |
| 153 | regulator-boot-on; |
| 154 | regulator-min-microvolt = <850000>; |
| 155 | regulator-max-microvolt = <1250000>; |
| 156 | regulator-name = "vdd_gpu"; |
| 157 | regulator-state-mem { |
| 158 | regulator-on-in-suspend; |
| 159 | regulator-suspend-microvolt = <1000000>; |
| 160 | }; |
| 161 | }; |
| 162 | |
| 163 | vcc_ddr: DCDC_REG3 { |
| 164 | regulator-always-on; |
| 165 | regulator-boot-on; |
| 166 | regulator-name = "vcc_ddr"; |
| 167 | regulator-state-mem { |
| 168 | regulator-on-in-suspend; |
| 169 | }; |
| 170 | }; |
| 171 | |
| 172 | vcc_io: DCDC_REG4 { |
| 173 | regulator-always-on; |
| 174 | regulator-boot-on; |
| 175 | regulator-min-microvolt = <3300000>; |
| 176 | regulator-max-microvolt = <3300000>; |
| 177 | regulator-name = "vcc_io"; |
| 178 | regulator-state-mem { |
| 179 | regulator-on-in-suspend; |
| 180 | regulator-suspend-microvolt = <3300000>; |
| 181 | }; |
| 182 | }; |
| 183 | |
| 184 | vccio_pmu: LDO_REG1 { |
| 185 | regulator-always-on; |
| 186 | regulator-boot-on; |
| 187 | regulator-min-microvolt = <3300000>; |
| 188 | regulator-max-microvolt = <3300000>; |
| 189 | regulator-name = "vccio_pmu"; |
| 190 | regulator-state-mem { |
| 191 | regulator-on-in-suspend; |
| 192 | regulator-suspend-microvolt = <3300000>; |
| 193 | }; |
| 194 | }; |
| 195 | |
| 196 | vcc_tp: LDO_REG2 { |
| 197 | regulator-always-on; |
| 198 | regulator-boot-on; |
| 199 | regulator-min-microvolt = <3300000>; |
| 200 | regulator-max-microvolt = <3300000>; |
| 201 | regulator-name = "vcc_tp"; |
| 202 | regulator-state-mem { |
| 203 | regulator-off-in-suspend; |
| 204 | }; |
| 205 | }; |
| 206 | |
| 207 | vdd_10: LDO_REG3 { |
| 208 | regulator-always-on; |
| 209 | regulator-boot-on; |
| 210 | regulator-min-microvolt = <1000000>; |
| 211 | regulator-max-microvolt = <1000000>; |
| 212 | regulator-name = "vdd_10"; |
| 213 | regulator-state-mem { |
| 214 | regulator-on-in-suspend; |
| 215 | regulator-suspend-microvolt = <1000000>; |
| 216 | }; |
| 217 | }; |
| 218 | |
| 219 | vcc18_lcd: LDO_REG4 { |
| 220 | regulator-always-on; |
| 221 | regulator-boot-on; |
| 222 | regulator-min-microvolt = <1800000>; |
| 223 | regulator-max-microvolt = <1800000>; |
| 224 | regulator-name = "vcc18_lcd"; |
| 225 | regulator-state-mem { |
| 226 | regulator-on-in-suspend; |
| 227 | regulator-suspend-microvolt = <1800000>; |
| 228 | }; |
| 229 | }; |
| 230 | |
| 231 | vccio_sd: LDO_REG5 { |
| 232 | regulator-always-on; |
| 233 | regulator-boot-on; |
| 234 | regulator-min-microvolt = <1800000>; |
| 235 | regulator-max-microvolt = <3300000>; |
| 236 | regulator-name = "vccio_sd"; |
| 237 | regulator-state-mem { |
| 238 | regulator-on-in-suspend; |
| 239 | regulator-suspend-microvolt = <3300000>; |
| 240 | }; |
| 241 | }; |
| 242 | |
| 243 | vout5: LDO_REG6 { |
| 244 | regulator-always-on; |
| 245 | regulator-boot-on; |
| 246 | regulator-min-microvolt = <1800000>; |
| 247 | regulator-max-microvolt = <2500000>; |
| 248 | regulator-name = "vout5"; |
| 249 | regulator-state-mem { |
| 250 | regulator-on-in-suspend; |
| 251 | regulator-suspend-microvolt = <1800000>; |
| 252 | }; |
| 253 | }; |
| 254 | |
| 255 | vcc_18: LDO_REG7 { |
| 256 | regulator-always-on; |
| 257 | regulator-boot-on; |
| 258 | regulator-min-microvolt = <1800000>; |
| 259 | regulator-max-microvolt = <1800000>; |
| 260 | regulator-name = "vcc_18"; |
| 261 | regulator-state-mem { |
| 262 | regulator-on-in-suspend; |
| 263 | regulator-suspend-microvolt = <1800000>; |
| 264 | }; |
| 265 | }; |
| 266 | |
| 267 | vcca_codec: LDO_REG8 { |
| 268 | regulator-always-on; |
| 269 | regulator-boot-on; |
| 270 | regulator-min-microvolt = <1800000>; |
| 271 | regulator-max-microvolt = <1800000>; |
| 272 | regulator-name = "vcca_codec"; |
| 273 | regulator-state-mem { |
| 274 | regulator-on-in-suspend; |
| 275 | regulator-suspend-microvolt = <1800000>; |
| 276 | }; |
| 277 | }; |
| 278 | |
| 279 | vcc_wl: SWITCH_REG1 { |
| 280 | regulator-always-on; |
| 281 | regulator-boot-on; |
| 282 | regulator-name = "vcc_wl"; |
| 283 | regulator-state-mem { |
| 284 | regulator-on-in-suspend; |
| 285 | }; |
| 286 | }; |
| 287 | |
| 288 | vcc_lcd: SWITCH_REG2 { |
| 289 | regulator-always-on; |
| 290 | regulator-boot-on; |
| 291 | regulator-name = "vcc_lcd"; |
| 292 | regulator-state-mem { |
| 293 | regulator-on-in-suspend; |
| 294 | }; |
| 295 | }; |
| 296 | }; |
| 297 | }; |
| 298 | }; |
| 299 | |
| 300 | &i2c2 { |
| 301 | status = "okay"; |
Caesar Wang | 47bf3a5 | 2016-01-07 16:25:45 +0800 | [diff] [blame] | 302 | |
| 303 | rt5616: rt5616@1b { |
| 304 | compatible = "rt5616"; |
| 305 | reg = <0x1b>; |
Caesar Wang | 8f338ec | 2016-02-02 11:40:52 +0800 | [diff] [blame] | 306 | clocks = <&cru SCLK_I2S_OUT>; |
| 307 | clock-names = "mclk"; |
Caesar Wang | 47bf3a5 | 2016-01-07 16:25:45 +0800 | [diff] [blame] | 308 | #sound-dai-cells = <0>; |
| 309 | }; |
| 310 | }; |
| 311 | |
| 312 | &i2s { |
| 313 | #sound-dai-cells = <0>; |
| 314 | status = "okay"; |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 315 | }; |
| 316 | |
| 317 | &sdio { |
| 318 | status = "okay"; |
| 319 | |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 320 | bus-width = <4>; |
Caesar Wang | 99dc9fd | 2016-01-15 21:49:52 +0800 | [diff] [blame] | 321 | cap-sd-highspeed; |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 322 | cap-sdio-irq; |
| 323 | default-sample-phase = <90>; |
| 324 | keep-power-in-suspend; |
Caesar Wang | 4a9d0b0 | 2016-01-15 21:49:53 +0800 | [diff] [blame] | 325 | mmc-pwrseq = <&sdio_pwrseq>; |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 326 | non-removable; |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 327 | pinctrl-names = "default"; |
| 328 | pinctrl-0 = <&sdio_clk &sdio_cmd &sdio_bus4>; |
Caesar Wang | 99dc9fd | 2016-01-15 21:49:52 +0800 | [diff] [blame] | 329 | sd-uhs-sdr12; |
| 330 | sd-uhs-sdr25; |
| 331 | sd-uhs-sdr50; |
| 332 | sd-uhs-sdr104; |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 333 | }; |
| 334 | |
Caesar Wang | 6cff705 | 2016-01-15 21:49:54 +0800 | [diff] [blame] | 335 | &sdmmc { |
| 336 | bus-width = <4>; |
| 337 | cap-mmc-highspeed; |
| 338 | cap-sd-highspeed; |
| 339 | card-detect-delay = <200>; |
| 340 | disable-wp; |
Caesar Wang | 6cff705 | 2016-01-15 21:49:54 +0800 | [diff] [blame] | 341 | pinctrl-names = "default"; |
| 342 | pinctrl-0 = <&sdmmc_clk>, <&sdmmc_cmd>, <&sdmmc_cd>, <&sdmmc_bus4>; |
| 343 | }; |
| 344 | |
Caesar Wang | 5d69fa0 | 2016-01-15 21:49:51 +0800 | [diff] [blame] | 345 | &uart0 { |
| 346 | status = "okay"; |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 347 | }; |
| 348 | |
| 349 | &uart2 { |
| 350 | status = "okay"; |
| 351 | }; |
| 352 | |
| 353 | &usb_host { |
| 354 | status = "okay"; |
| 355 | }; |
| 356 | |
| 357 | &usb_otg { |
| 358 | status = "okay"; |
| 359 | }; |
| 360 | |
Caesar Wang | cef0abe | 2016-02-02 11:40:50 +0800 | [diff] [blame] | 361 | &vop { |
| 362 | status = "okay"; |
| 363 | }; |
| 364 | |
| 365 | &vop_mmu { |
| 366 | status = "okay"; |
| 367 | }; |
| 368 | |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 369 | &pinctrl { |
Caesar Wang | fe25313 | 2016-01-28 16:43:30 +0800 | [diff] [blame] | 370 | leds { |
| 371 | led_ctl: led-ctl { |
| 372 | rockchip,pins = <2 30 RK_FUNC_GPIO &pcfg_pull_none>; |
| 373 | }; |
| 374 | }; |
| 375 | |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 376 | pmic { |
| 377 | pmic_int: pmic-int { |
| 378 | rockchip,pins = <2 2 RK_FUNC_GPIO &pcfg_pull_default>; |
| 379 | }; |
| 380 | }; |
| 381 | |
Caesar Wang | 4a9d0b0 | 2016-01-15 21:49:53 +0800 | [diff] [blame] | 382 | sdio { |
| 383 | bt_wake_h: bt-wake-h { |
| 384 | rockchip,pins = <2 8 RK_FUNC_GPIO &pcfg_pull_default>; |
| 385 | }; |
| 386 | }; |
| 387 | |
Caesar Wang | 6cff705 | 2016-01-15 21:49:54 +0800 | [diff] [blame] | 388 | sdmmc { |
| 389 | sdmmc_pwr: sdmmc-pwr { |
| 390 | rockchip,pins = <2 28 RK_FUNC_GPIO &pcfg_pull_none>; |
| 391 | }; |
| 392 | }; |
| 393 | |
Caesar Wang | 94cf32b | 2015-12-17 22:21:50 +0800 | [diff] [blame] | 394 | sleep { |
| 395 | global_pwroff: global-pwroff { |
| 396 | rockchip,pins = <2 7 RK_FUNC_1 &pcfg_pull_none>; |
| 397 | }; |
| 398 | }; |
| 399 | }; |