1/* 2 * (C) Copyright 2016 Rockchip Electronics Co., Ltd 3 * 4 * SPDX-License-Identifier: GPL-2.0+ X11 5 */ 6 7#include "rk3288.dtsi" 8#include <dt-bindings/input/input.h> 9 10/ { 11 memory { 12 reg = <0 0x80000000>; 13 }; 14 15 adc-keys { 16 compatible = "adc-keys"; 17 io-channels = <&saradc 1>; 18 19 volup-key { 20 linux,code = <KEY_VOLUMEUP>; 21 label = "volume up"; 22 press-threshold-microvolt = <18000>; 23 }; 24 }; 25 26 ext_gmac: external-gmac-clock { 27 compatible = "fixed-clock"; 28 #clock-cells = <0>; 29 clock-frequency = <125000000>; 30 clock-output-names = "ext_gmac"; 31 }; 32 33 keys: gpio-keys { 34 compatible = "gpio-keys"; 35 #address-cells = <1>; 36 #size-cells = <0>; 37 38 button@0 { 39 gpio-key,wakeup = <1>; 40 gpios = <&gpio0 5 GPIO_ACTIVE_LOW>; 41 label = "GPIO Power"; 42 linux,code = <116>; 43 pinctrl-names = "default"; 44 pinctrl-0 = <&pwr_key>; 45 }; 46 }; 47 48 vcc_sys: vsys-regulator { 49 compatible = "regulator-fixed"; 50 regulator-name = "vcc_sys"; 51 regulator-min-microvolt = <5000000>; 52 regulator-max-microvolt = <5000000>; 53 regulator-always-on; 54 regulator-boot-on; 55 }; 56 57 vcc_flash: flash-regulator { 58 compatible = "regulator-fixed"; 59 regulator-name = "vcc_flash"; 60 regulator-min-microvolt = <1800000>; 61 regulator-max-microvolt = <1800000>; 62 vin-supply = <&vcc_io>; 63 }; 64 65 vcc_5v: usb-regulator { 66 compatible = "regulator-fixed"; 67 regulator-name = "vcc_5v"; 68 regulator-min-microvolt = <5000000>; 69 regulator-max-microvolt = <5000000>; 70 regulator-always-on; 71 regulator-boot-on; 72 vin-supply = <&vcc_sys>; 73 }; 74 75 vcc_host_5v: usb-host-regulator { 76 compatible = "regulator-fixed"; 77 enable-active-high; 78 gpio = <&gpio0 14 GPIO_ACTIVE_HIGH>; 79 pinctrl-names = "default"; 80 pinctrl-0 = <&host_vbus_drv>; 81 regulator-name = "vcc_host_5v"; 82 regulator-min-microvolt = <5000000>; 83 regulator-max-microvolt = <5000000>; 84 regulator-always-on; 85 vin-supply = <&vcc_5v>; 86 }; 87 88 vcc_otg_5v: usb-otg-regulator { 89 compatible = "regulator-fixed"; 90 enable-active-high; 91 gpio = <&gpio0 12 GPIO_ACTIVE_HIGH>; 92 pinctrl-names = "default"; 93 pinctrl-0 = <&otg_vbus_drv>; 94 regulator-name = "vcc_otg_5v"; 95 regulator-min-microvolt = <5000000>; 96 regulator-max-microvolt = <5000000>; 97 regulator-always-on; 98 vin-supply = <&vcc_5v>; 99 }; 100 101 backlight: backlight { 102 compatible = "pwm-backlight"; 103 power-supply = <&vcc_sys>; 104 enable-gpios = <&gpio7 2 GPIO_ACTIVE_HIGH>; 105 brightness-levels = < 106 0 1 2 3 4 5 6 7 107 8 9 10 11 12 13 14 15 108 16 17 18 19 20 21 22 23 109 24 25 26 27 28 29 30 31 110 32 33 34 35 36 37 38 39 111 40 41 42 43 44 45 46 47 112 48 49 50 51 52 53 54 55 113 56 57 58 59 60 61 62 63 114 64 65 66 67 68 69 70 71 115 72 73 74 75 76 77 78 79 116 80 81 82 83 84 85 86 87 117 88 89 90 91 92 93 94 95 118 96 97 98 99 100 101 102 103 119 104 105 106 107 108 109 110 111 120 112 113 114 115 116 117 118 119 121 120 121 122 123 124 125 126 127 122 128 129 130 131 132 133 134 135 123 136 137 138 139 140 141 142 143 124 144 145 146 147 148 149 150 151 125 152 153 154 155 156 157 158 159 126 160 161 162 163 164 165 166 167 127 168 169 170 171 172 173 174 175 128 176 177 178 179 180 181 182 183 129 184 185 186 187 188 189 190 191 130 192 193 194 195 196 197 198 199 131 200 201 202 203 204 205 206 207 132 208 209 210 211 212 213 214 215 133 216 217 218 219 220 221 222 223 134 224 225 226 227 228 229 230 231 135 232 233 234 235 236 237 238 239 136 240 241 242 243 244 245 246 247 137 248 249 250 251 252 253 254 255>; 138 default-brightness-level = <50>; 139 pwms = <&pwm0 0 25000 0>; 140 pinctrl-names = "default"; 141 pinctrl-0 = <&pwm0_pin>; 142 pwm-delay-us = <10000>; 143 status = "disabled"; 144 }; 145 146 panel: panel { 147 compatible = "simple-panel"; 148 power-supply = <&vcc_io>; 149 backlight = <&backlight>; 150 enable-gpios = <&gpio7 3 GPIO_ACTIVE_HIGH>; 151 status = "disabled"; 152 }; 153}; 154 155&cpu0 { 156 cpu0-supply = <&vdd_cpu>; 157}; 158 159&emmc { 160 broken-cd; 161 bus-width = <8>; 162 cap-mmc-highspeed; 163 disable-wp; 164 non-removable; 165 num-slots = <1>; 166 pinctrl-names = "default"; 167 pinctrl-0 = <&emmc_clk>, <&emmc_cmd>, <&emmc_pwr>, <&emmc_bus8>; 168 vmmc-supply = <&vcc_io>; 169 vqmmc-supply = <&vcc_flash>; 170 status = "okay"; 171}; 172 173&gmac { 174 phy-mode = "rgmii"; 175 clock_in_out = "input"; 176 snps,reset-gpio = <&gpio4 7 0>; 177 snps,reset-active-low; 178 snps,reset-delays-us = <0 10000 1000000>; 179 assigned-clocks = <&cru SCLK_MAC>; 180 assigned-clock-parents = <&ext_gmac>; 181 pinctrl-names = "default"; 182 pinctrl-0 = <&rgmii_pins>; 183 tx_delay = <0x30>; 184 rx_delay = <0x10>; 185 status = "okay"; 186}; 187 188&hdmi { 189 ddc-i2c-bus = <&i2c5>; 190 status = "okay"; 191}; 192 193&i2c0 { 194 clock-frequency = <400000>; 195 status = "okay"; 196 197 vdd_cpu: syr827@40 { 198 compatible = "silergy,syr827"; 199 fcs,suspend-voltage-selector = <1>; 200 reg = <0x40>; 201 regulator-name = "vdd_cpu"; 202 regulator-min-microvolt = <850000>; 203 regulator-max-microvolt = <1350000>; 204 regulator-always-on; 205 regulator-boot-on; 206 vin-supply = <&vcc_sys>; 207 }; 208 209 vdd_gpu: syr828@41 { 210 compatible = "silergy,syr828"; 211 fcs,suspend-voltage-selector = <1>; 212 reg = <0x41>; 213 regulator-name = "vdd_gpu"; 214 regulator-min-microvolt = <850000>; 215 regulator-max-microvolt = <1350000>; 216 regulator-always-on; 217 vin-supply = <&vcc_sys>; 218 }; 219 220 hym8563: hym8563@51 { 221 compatible = "haoyu,hym8563"; 222 reg = <0x51>; 223 #clock-cells = <0>; 224 clock-frequency = <32768>; 225 clock-output-names = "xin32k"; 226 interrupt-parent = <&gpio7>; 227 interrupts = <4 IRQ_TYPE_EDGE_FALLING>; 228 pinctrl-names = "default"; 229 pinctrl-0 = <&rtc_int>; 230 }; 231 232 act8846: act8846@5a { 233 compatible = "active-semi,act8846"; 234 reg = <0x5a>; 235 pinctrl-names = "default"; 236 pinctrl-0 = <&pwr_hold>; 237 system-power-controller; 238 239 regulators { 240 vcc_ddr: REG1 { 241 regulator-name = "vcc_ddr"; 242 regulator-min-microvolt = <1200000>; 243 regulator-max-microvolt = <1200000>; 244 regulator-always-on; 245 }; 246 247 vcc_io: REG2 { 248 regulator-name = "vcc_io"; 249 regulator-min-microvolt = <3300000>; 250 regulator-max-microvolt = <3300000>; 251 regulator-always-on; 252 }; 253 254 vdd_log: REG3 { 255 regulator-name = "vdd_log"; 256 regulator-min-microvolt = <1100000>; 257 regulator-max-microvolt = <1100000>; 258 regulator-always-on; 259 }; 260 261 vcc_20: REG4 { 262 regulator-name = "vcc_20"; 263 regulator-min-microvolt = <2000000>; 264 regulator-max-microvolt = <2000000>; 265 regulator-always-on; 266 }; 267 268 vccio_sd: REG5 { 269 regulator-name = "vccio_sd"; 270 regulator-min-microvolt = <3300000>; 271 regulator-max-microvolt = <3300000>; 272 regulator-always-on; 273 }; 274 275 vdd10_lcd: REG6 { 276 regulator-name = "vdd10_lcd"; 277 regulator-min-microvolt = <1000000>; 278 regulator-max-microvolt = <1000000>; 279 regulator-always-on; 280 }; 281 282 vcca_codec: REG7 { 283 regulator-name = "vcca_codec"; 284 regulator-min-microvolt = <3300000>; 285 regulator-max-microvolt = <3300000>; 286 }; 287 288 vcc_tp: REG8 { 289 regulator-name = "vcca_33"; 290 regulator-min-microvolt = <3300000>; 291 regulator-max-microvolt = <3300000>; 292 }; 293 294 vccio_pmu: REG9 { 295 regulator-name = "vccio_pmu"; 296 regulator-min-microvolt = <3300000>; 297 regulator-max-microvolt = <3300000>; 298 }; 299 300 vdd_10: REG10 { 301 regulator-name = "vdd_10"; 302 regulator-min-microvolt = <1000000>; 303 regulator-max-microvolt = <1000000>; 304 regulator-always-on; 305 }; 306 307 vcc_18: REG11 { 308 regulator-name = "vcc_18"; 309 regulator-min-microvolt = <1800000>; 310 regulator-max-microvolt = <1800000>; 311 regulator-always-on; 312 }; 313 314 vcc18_lcd: REG12 { 315 regulator-name = "vcc18_lcd"; 316 regulator-min-microvolt = <1800000>; 317 regulator-max-microvolt = <1800000>; 318 regulator-always-on; 319 }; 320 }; 321 }; 322}; 323 324&i2c1 { 325 status = "okay"; 326}; 327 328&i2c2 { 329 status = "okay"; 330}; 331 332&i2c4 { 333 status = "okay"; 334}; 335 336&i2c5 { 337 status = "okay"; 338}; 339 340&pinctrl { 341 pcfg_output_high: pcfg-output-high { 342 output-high; 343 }; 344 345 pcfg_output_low: pcfg-output-low { 346 output-low; 347 }; 348 349 act8846 { 350 pwr_hold: pwr-hold { 351 rockchip,pins = <0 9 RK_FUNC_GPIO &pcfg_output_high>; 352 }; 353 }; 354 355 hym8563 { 356 rtc_int: rtc-int { 357 rockchip,pins = <0 4 RK_FUNC_GPIO &pcfg_pull_up>; 358 }; 359 }; 360 361 keys { 362 pwr_key: pwr-key { 363 rockchip,pins = <0 5 RK_FUNC_GPIO &pcfg_pull_up>; 364 }; 365 }; 366 367 sdmmc { 368 sdmmc_pwr: sdmmc-pwr { 369 rockchip,pins = <7 11 RK_FUNC_GPIO &pcfg_pull_none>; 370 }; 371 }; 372 373 usb_host { 374 host_vbus_drv: host-vbus-drv { 375 rockchip,pins = <0 14 RK_FUNC_GPIO &pcfg_pull_none>; 376 }; 377 }; 378 379 usb_otg { 380 otg_vbus_drv: otg-vbus-drv { 381 rockchip,pins = <0 12 RK_FUNC_GPIO &pcfg_pull_none>; 382 }; 383 }; 384}; 385 386&pwm0 { 387 status = "okay"; 388}; 389 390&saradc { 391 vref-supply = <&vcc_18>; 392 status = "okay"; 393}; 394 395&sdio0 { 396 broken-cd; 397 bus-width = <4>; 398 disable-wp; 399 non-removable; 400 num-slots = <1>; 401 pinctrl-names = "default"; 402 pinctrl-0 = <&sdio0_bus4>, <&sdio0_cmd>, <&sdio0_clk>; 403 vmmc-supply = <&vcc_18>; 404 status = "disabled"; 405}; 406 407&sdmmc { 408 bus-width = <4>; 409 cap-mmc-highspeed; 410 cap-sd-highspeed; 411 card-detect-delay = <200>; 412 disable-wp; 413 num-slots = <1>; 414 pinctrl-names = "default"; 415 pinctrl-0 = <&sdmmc_clk>, <&sdmmc_cmd>, <&sdmmc_cd>, <&sdmmc_bus4>; 416 vmmc-supply = <&vccio_sd>; 417 status = "okay"; 418}; 419 420&spi0 { 421 pinctrl-names = "default"; 422 pinctrl-0 = <&spi0_clk>, <&spi0_cs0>, <&spi0_tx>, <&spi0_rx>, <&spi0_cs1>; 423 status = "okay"; 424}; 425 426&uart0 { 427 pinctrl-names = "default"; 428 pinctrl-0 = <&uart0_xfer>, <&uart0_cts>, <&uart0_rts>; 429 status = "okay"; 430}; 431 432&uart1 { 433 status = "okay"; 434}; 435 436&uart2 { 437 status = "okay"; 438}; 439 440&uart3 { 441 status = "okay"; 442}; 443 444&usb_host1 { 445 status = "okay"; 446}; 447 448&usb_otg { 449 status = "okay"; 450}; 451 452&vopb { 453 status = "okay"; 454}; 455 456&vopb_mmu { 457 status = "okay"; 458}; 459 460&vopl { 461 status = "okay"; 462}; 463 464&vopl_mmu { 465 status = "okay"; 466}; 467 468&mipi_dsi0 { 469 status = "disabled"; 470 rockchip,panel = <&panel>; 471 display-timings { 472 timing0 { 473 bits-per-pixel = <24>; 474 clock-frequency = <160000000>; 475 hfront-porch = <120>; 476 hsync-len = <20>; 477 hback-porch = <21>; 478 hactive = <1200>; 479 vfront-porch = <21>; 480 vsync-len = <3>; 481 vback-porch = <18>; 482 vactive = <1920>; 483 hsync-active = <0>; 484 vsync-active = <0>; 485 de-active = <1>; 486 pixelclk-active = <0>; 487 }; 488 }; 489}; 490 491&wdt { 492 status = "okay"; 493}; 494