1// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2// Copyright (c) 2018 Fuzhou Rockchip Electronics Co., Ltd 3 4/dts-v1/; 5#include <dt-bindings/gpio/gpio.h> 6#include <dt-bindings/pinctrl/rockchip.h> 7#include <dt-bindings/input/input.h> 8#include <dt-bindings/display/drm_mipi_dsi.h> 9#include <dt-bindings/sensor-dev.h> 10#include <dt-bindings/pwm/pwm.h> 11#include "rk3399pro.dtsi" 12#include "rk3399-android.dtsi" 13#include "rk3399-opp.dtsi" 14#include "rk3399-vop-clk-set.dtsi" 15 16/ { 17 compatible = "rockchip,rk3399pro-evb-v10", "rockchip,rk3399pro"; 18 19 adc-keys { 20 compatible = "adc-keys"; 21 io-channels = <&saradc 2>; 22 io-channel-names = "buttons"; 23 poll-interval = <100>; 24 keyup-threshold-microvolt = <1800000>; 25 26 esc-key { 27 linux,code = <KEY_ESC>; 28 label = "esc"; 29 press-threshold-microvolt = <1310000>; 30 }; 31 32 menu-key { 33 linux,code = <KEY_MENU>; 34 label = "menu"; 35 press-threshold-microvolt = <987000>; 36 }; 37 38 home-key { 39 linux,code = <KEY_HOME>; 40 label = "home"; 41 press-threshold-microvolt = <624000>; 42 }; 43 44 vol-down-key { 45 linux,code = <KEY_VOLUMEDOWN>; 46 label = "volume down"; 47 press-threshold-microvolt = <300000>; 48 }; 49 50 vol-up-key { 51 linux,code = <KEY_VOLUMEUP>; 52 label = "volume up"; 53 press-threshold-microvolt = <17000>; 54 }; 55 }; 56 57 backlight: backlight { 58 compatible = "pwm-backlight"; 59 pwms = <&pwm0 0 25000 0>; 60 brightness-levels = < 61 0 20 20 21 21 22 22 23 62 23 24 24 25 25 26 26 27 63 27 28 28 29 29 30 30 31 64 31 32 32 33 33 34 34 35 65 35 36 36 37 37 38 38 39 66 40 41 42 43 44 45 46 47 67 48 49 50 51 52 53 54 55 68 56 57 58 59 60 61 62 63 69 64 65 66 67 68 69 70 71 70 72 73 74 75 76 77 78 79 71 80 81 82 83 84 85 86 87 72 88 89 90 91 92 93 94 95 73 96 97 98 99 100 101 102 103 74 104 105 106 107 108 109 110 111 75 112 113 114 115 116 117 118 119 76 120 121 122 123 124 125 126 127 77 128 129 130 131 132 133 134 135 78 136 137 138 139 140 141 142 143 79 144 145 146 147 148 149 150 151 80 152 153 154 155 156 157 158 159 81 160 161 162 163 164 165 166 167 82 168 169 170 171 172 173 174 175 83 176 177 178 179 180 181 182 183 84 184 185 186 187 188 189 190 191 85 192 193 194 195 196 197 198 199 86 200 201 202 203 204 205 206 207 87 208 209 210 211 212 213 214 215 88 216 217 218 219 220 221 222 223 89 224 225 226 227 228 229 230 231 90 232 233 234 235 236 237 238 239 91 240 241 242 243 244 245 246 247 92 248 249 250 251 252 253 254 255 93 >; 94 default-brightness-level = <200>; 95 enable-gpios = <&gpio1 RK_PB5 GPIO_ACTIVE_HIGH>; 96 }; 97 98 clkin_gmac: external-gmac-clock { 99 compatible = "fixed-clock"; 100 clock-frequency = <125000000>; 101 clock-output-names = "clkin_gmac"; 102 #clock-cells = <0>; 103 }; 104 105 hdmi_sound: hdmi-sound { 106 status = "okay"; 107 compatible = "simple-audio-card"; 108 simple-audio-card,format = "i2s"; 109 simple-audio-card,mclk-fs = <256>; 110 simple-audio-card,name = "rockchip,hdmi"; 111 112 simple-audio-card,cpu { 113 sound-dai = <&i2s2>; 114 }; 115 simple-audio-card,codec { 116 sound-dai = <&hdmi>; 117 }; 118 }; 119 120 panel: panel { 121 compatible = "simple-panel"; 122 backlight = <&backlight>; 123 enable-gpios = <&gpio4 RK_PD6 GPIO_ACTIVE_HIGH>; 124 prepare-delay-ms = <20>; 125 enable-delay-ms = <20>; 126 reset-delay-ms = <20>; 127 128 display-timings { 129 native-mode = <&timing0>; 130 131 timing0: timing0 { 132 clock-frequency = <200000000>; 133 hactive = <1536>; 134 vactive = <2048>; 135 hfront-porch = <12>; 136 hsync-len = <16>; 137 hback-porch = <48>; 138 vfront-porch = <8>; 139 vsync-len = <4>; 140 vback-porch = <8>; 141 hsync-active = <0>; 142 vsync-active = <0>; 143 de-active = <0>; 144 pixelclk-active = <0>; 145 }; 146 }; 147 148 ports { 149 panel_in: endpoint { 150 remote-endpoint = <&edp_out>; 151 }; 152 }; 153 }; 154 155 rk809-sound { 156 compatible = "simple-audio-card"; 157 simple-audio-card,format = "i2s"; 158 simple-audio-card,name = "rockchip,rk809-codec"; 159 simple-audio-card,mclk-fs = <256>; 160 simple-audio-card,widgets = 161 "Microphone", "Mic Jack", 162 "Headphone", "Headphone Jack"; 163 simple-audio-card,routing = 164 "Mic Jack", "MICBIAS1", 165 "IN1P", "Mic Jack", 166 "Headphone Jack", "HPOL", 167 "Headphone Jack", "HPOR"; 168 simple-audio-card,cpu { 169 sound-dai = <&i2s1>; 170 }; 171 simple-audio-card,codec { 172 sound-dai = <&rk809_codec>; 173 }; 174 }; 175 176 rk_headset: rk-headset { 177 compatible = "rockchip_headset"; 178 headset_gpio = <&gpio0 RK_PB5 GPIO_ACTIVE_HIGH>; 179 pinctrl-names = "default"; 180 pinctrl-0 = <&hp_det>; 181 io-channels = <&saradc 3>; 182 }; 183 184 sdio_pwrseq: sdio-pwrseq { 185 compatible = "mmc-pwrseq-simple"; 186 clocks = <&rk809 1>; 187 clock-names = "ext_clock"; 188 pinctrl-names = "default"; 189 pinctrl-0 = <&wifi_enable_h>; 190 191 /* 192 * On the module itself this is one of these (depending 193 * on the actual card populated): 194 * - SDIO_RESET_L_WL_REG_ON 195 * - PDN (power down when low) 196 */ 197 reset-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_LOW>; 198 }; 199 200 vbus_typec: vbus-typec-regulator { 201 compatible = "regulator-fixed"; 202 enable-active-high; 203 gpio = <&gpio1 18 GPIO_ACTIVE_HIGH>; 204 pinctrl-names = "default"; 205 pinctrl-0 = <&vcc5v0_typec0_en>; 206 regulator-name = "vbus_typec"; 207 vin-supply = <&vcc5v0_sys>; 208 }; 209 210 vcc_phy: vcc-phy-regulator { 211 compatible = "regulator-fixed"; 212 regulator-name = "vcc_phy"; 213 regulator-always-on; 214 regulator-boot-on; 215 }; 216 217 vcc5v0_sys: vccsys { 218 compatible = "regulator-fixed"; 219 regulator-name = "vcc5v0_sys"; 220 regulator-always-on; 221 regulator-boot-on; 222 regulator-min-microvolt = <5000000>; 223 regulator-max-microvolt = <5000000>; 224 }; 225 226 wireless-wlan { 227 compatible = "wlan-platdata"; 228 rockchip,grf = <&grf>; 229 wifi_chip_type = "ap6398s"; 230 sdio_vref = <1800>; 231 WIFI,host_wake_irq = <&gpio0 RK_PA3 GPIO_ACTIVE_HIGH>; 232 status = "okay"; 233 }; 234 235 wireless-bluetooth { 236 compatible = "bluetooth-platdata"; 237 clocks = <&rk809 1>; 238 clock-names = "ext_clock"; 239 uart_rts_gpios = <&gpio2 RK_PC3 GPIO_ACTIVE_LOW>; 240 pinctrl-names = "default", "rts_gpio"; 241 pinctrl-0 = <&uart0_rts>, <&bt_irq_gpio>; 242 pinctrl-1 = <&uart0_gpios>; 243 BT,reset_gpio = <&gpio2 RK_PD4 GPIO_ACTIVE_HIGH>; 244 BT,wake_gpio = <&gpio2 RK_PD2 GPIO_ACTIVE_HIGH>; 245 BT,wake_host_irq = <&gpio0 RK_PA5 GPIO_ACTIVE_HIGH>; 246 status = "okay"; 247 }; 248}; 249 250&cdn_dp { 251 status = "okay"; 252 phys = <&tcphy0_dp>; 253}; 254 255&cpu_l0 { 256 cpu-supply = <&vdd_cpu_l>; 257}; 258 259&cpu_l1 { 260 cpu-supply = <&vdd_cpu_l>; 261}; 262 263&cpu_l2 { 264 cpu-supply = <&vdd_cpu_l>; 265}; 266 267&cpu_l3 { 268 cpu-supply = <&vdd_cpu_l>; 269}; 270 271&cpu_b0 { 272 cpu-supply = <&vdd_cpu_b>; 273}; 274 275&cpu_b1 { 276 cpu-supply = <&vdd_cpu_b>; 277}; 278 279&dp_in_vopb { 280 status = "disabled"; 281}; 282 283&edp { 284 status = "okay"; 285 force-hpd; 286 287 ports { 288 port@1 { 289 reg = <1>; 290 291 edp_out: endpoint { 292 remote-endpoint = <&panel_in>; 293 }; 294 }; 295 }; 296}; 297 298&edp_in_vopl { 299 status = "disabled"; 300}; 301 302&emmc_phy { 303 status = "okay"; 304}; 305 306&fiq_debugger { 307 pinctrl-0 = <&uart2a_xfer>; 308}; 309 310&firmware_android { 311 compatible = "android,firmware"; 312 fstab { 313 compatible = "android,fstab"; 314 system { 315 compatible = "android,system"; 316 dev = "/dev/block/by-name/system"; 317 type = "ext4"; 318 mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; 319 fsmgr_flags = "wait,verify"; 320 }; 321 vendor { 322 compatible = "android,vendor"; 323 dev = "/dev/block/by-name/vendor"; 324 type = "ext4"; 325 mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; 326 fsmgr_flags = "wait,verify"; 327 }; 328 }; 329}; 330 331&gmac { 332 phy-supply = <&vcc_phy>; 333 phy-mode = "rgmii"; 334 clock_in_out = "input"; 335 snps,reset-gpio = <&gpio3 RK_PB7 GPIO_ACTIVE_LOW>; 336 snps,reset-active-low; 337 snps,reset-delays-us = <0 10000 50000>; 338 assigned-clocks = <&cru SCLK_RMII_SRC>; 339 assigned-clock-parents = <&clkin_gmac>; 340 pinctrl-names = "default"; 341 pinctrl-0 = <&rgmii_pins>; 342 tx_delay = <0x28>; 343 rx_delay = <0x11>; 344 status = "okay"; 345}; 346 347&gpu { 348 status = "okay"; 349 mali-supply = <&vdd_gpu>; 350}; 351 352&hdmi { 353 status = "okay"; 354 #sound-dai-cells = <0>; 355 rockchip,phy-table = 356 <74250000 0x8009 0x0004 0x0272>, 357 <165000000 0x802b 0x0004 0x0209>, 358 <297000000 0x8039 0x0005 0x028d>, 359 <594000000 0x8039 0x0000 0x00f6>, 360 <000000000 0x0000 0x0000 0x0000>; 361}; 362 363&hdmi_dp_sound { 364 status = "okay"; 365}; 366 367&hdmi_in_vopb { 368 status = "disabled"; 369}; 370 371&i2s2 { 372 #sound-dai-cells = <0>; 373 status = "okay"; 374}; 375 376&i2c0 { 377 status = "okay"; 378 i2c-scl-rising-time-ns = <180>; 379 i2c-scl-falling-time-ns = <30>; 380 clock-frequency = <400000>; 381 382 rk809: pmic@20 { 383 compatible = "rockchip,rk809"; 384 reg = <0x20>; 385 interrupt-parent = <&gpio1>; 386 interrupts = <RK_PC2 IRQ_TYPE_LEVEL_LOW>; 387 pinctrl-names = "default", "pmic-sleep", 388 "pmic-power-off", "pmic-reset"; 389 pinctrl-0 = <&pmic_int_l>; 390 pinctrl-1 = <&soc_slppin_slp>, <&rk809_slppin_slp>; 391 pinctrl-2 = <&soc_slppin_gpio>, <&rk809_slppin_pwrdn>; 392 pinctrl-3 = <&soc_slppin_gpio>,<&rk809_slppin_rst>; 393 rockchip,system-power-controller; 394 pmic-reset-func = <0>; 395 wakeup-source; 396 #clock-cells = <1>; 397 clock-output-names = "rk808-clkout1", "rk808-clkout2"; 398 399 vcc1-supply = <&vcc5v0_sys>; 400 vcc2-supply = <&vcc5v0_sys>; 401 vcc3-supply = <&vcc5v0_sys>; 402 vcc4-supply = <&vcc5v0_sys>; 403 vcc5-supply = <&vcc_buck5>; 404 vcc6-supply = <&vcc_buck5>; 405 vcc7-supply = <&vcc3v3_sys>; 406 vcc8-supply = <&vcc3v3_sys>; 407 vcc9-supply = <&vcc5v0_sys>; 408 409 pwrkey { 410 status = "okay"; 411 }; 412 413 rtc { 414 status = "okay"; 415 }; 416 417 pinctrl_rk8xx: pinctrl_rk8xx { 418 gpio-controller; 419 #gpio-cells = <2>; 420 421 rk809_slppin_null: rk809_slppin_null { 422 pins = "gpio_slp"; 423 function = "pin_fun0"; 424 }; 425 426 rk809_slppin_slp: rk809_slppin_slp { 427 pins = "gpio_slp"; 428 function = "pin_fun1"; 429 }; 430 431 rk809_slppin_pwrdn: rk809_slppin_pwrdn { 432 pins = "gpio_slp"; 433 function = "pin_fun2"; 434 }; 435 436 rk809_slppin_rst: rk809_slppin_rst { 437 pins = "gpio_slp"; 438 function = "pin_fun3"; 439 }; 440 }; 441 442 regulators { 443 vdd_log: DCDC_REG1 { 444 regulator-always-on; 445 regulator-boot-on; 446 regulator-min-microvolt = <750000>; 447 regulator-max-microvolt = <1350000>; 448 regulator-initial-mode = <0x2>; 449 regulator-name = "vdd_log"; 450 regulator-state-mem { 451 regulator-on-in-suspend; 452 regulator-suspend-microvolt = <900000>; 453 }; 454 }; 455 456 vdd_cpu_l: DCDC_REG2 { 457 regulator-always-on; 458 regulator-boot-on; 459 regulator-min-microvolt = <750000>; 460 regulator-max-microvolt = <1350000>; 461 regulator-ramp-delay = <6001>; 462 regulator-initial-mode = <0x2>; 463 regulator-name = "vdd_cpu_l"; 464 regulator-state-mem { 465 regulator-off-in-suspend; 466 }; 467 }; 468 469 vcc_ddr: DCDC_REG3 { 470 regulator-always-on; 471 regulator-boot-on; 472 regulator-name = "vcc_ddr"; 473 regulator-initial-mode = <0x2>; 474 regulator-state-mem { 475 regulator-on-in-suspend; 476 }; 477 }; 478 479 vcc3v3_sys: DCDC_REG4 { 480 regulator-always-on; 481 regulator-boot-on; 482 regulator-min-microvolt = <3300000>; 483 regulator-max-microvolt = <3300000>; 484 regulator-initial-mode = <0x2>; 485 regulator-name = "vcc3v3_sys"; 486 regulator-state-mem { 487 regulator-on-in-suspend; 488 regulator-suspend-microvolt = <3300000>; 489 }; 490 }; 491 492 vcc_buck5: DCDC_REG5 { 493 regulator-always-on; 494 regulator-boot-on; 495 regulator-min-microvolt = <2200000>; 496 regulator-max-microvolt = <2200000>; 497 regulator-name = "vcc_buck5"; 498 regulator-state-mem { 499 regulator-on-in-suspend; 500 regulator-suspend-microvolt = <2200000>; 501 }; 502 }; 503 504 vcca_0v9: LDO_REG1 { 505 regulator-always-on; 506 regulator-boot-on; 507 regulator-min-microvolt = <900000>; 508 regulator-max-microvolt = <900000>; 509 regulator-name = "vcca_0v9"; 510 regulator-state-mem { 511 regulator-off-in-suspend; 512 }; 513 }; 514 515 vcc_1v8: LDO_REG2 { 516 regulator-always-on; 517 regulator-boot-on; 518 regulator-min-microvolt = <1800000>; 519 regulator-max-microvolt = <1800000>; 520 521 regulator-name = "vcc_1v8"; 522 regulator-state-mem { 523 regulator-on-in-suspend; 524 regulator-suspend-microvolt = <1800000>; 525 }; 526 }; 527 528 vcc0v9_soc: LDO_REG3 { 529 regulator-always-on; 530 regulator-boot-on; 531 regulator-min-microvolt = <900000>; 532 regulator-max-microvolt = <900000>; 533 534 regulator-name = "vcc0v9_soc"; 535 regulator-state-mem { 536 regulator-on-in-suspend; 537 regulator-suspend-microvolt = <900000>; 538 }; 539 }; 540 541 vcca_1v8: LDO_REG4 { 542 regulator-always-on; 543 regulator-boot-on; 544 regulator-min-microvolt = <1800000>; 545 regulator-max-microvolt = <1800000>; 546 547 regulator-name = "vcca_1v8"; 548 regulator-state-mem { 549 regulator-off-in-suspend; 550 }; 551 }; 552 553 vdd1v5_dvp: LDO_REG5 { 554 regulator-always-on; 555 regulator-boot-on; 556 regulator-min-microvolt = <1500000>; 557 regulator-max-microvolt = <1500000>; 558 559 regulator-name = "vdd1v5_dvp"; 560 regulator-state-mem { 561 regulator-off-in-suspend; 562 }; 563 }; 564 565 vcc_1v5: LDO_REG6 { 566 regulator-always-on; 567 regulator-boot-on; 568 regulator-min-microvolt = <1500000>; 569 regulator-max-microvolt = <1500000>; 570 571 regulator-name = "vcc_1v5"; 572 regulator-state-mem { 573 regulator-off-in-suspend; 574 }; 575 }; 576 577 vcc_3v0: LDO_REG7 { 578 regulator-always-on; 579 regulator-boot-on; 580 regulator-min-microvolt = <3000000>; 581 regulator-max-microvolt = <3000000>; 582 583 regulator-name = "vcc_3v0"; 584 regulator-state-mem { 585 regulator-off-in-suspend; 586 }; 587 }; 588 589 vccio_sd: LDO_REG8 { 590 regulator-always-on; 591 regulator-boot-on; 592 regulator-min-microvolt = <1800000>; 593 regulator-max-microvolt = <3300000>; 594 595 regulator-name = "vccio_sd"; 596 regulator-state-mem { 597 regulator-off-in-suspend; 598 }; 599 }; 600 601 vcc_sd: LDO_REG9 { 602 regulator-always-on; 603 regulator-boot-on; 604 regulator-min-microvolt = <3300000>; 605 regulator-max-microvolt = <3300000>; 606 607 regulator-name = "vcc_sd"; 608 regulator-state-mem { 609 regulator-off-in-suspend; 610 }; 611 }; 612 613 vcc5v0_usb: SWITCH_REG1 { 614 regulator-always-on; 615 regulator-boot-on; 616 regulator-name = "vcc5v0_usb"; 617 regulator-state-mem { 618 regulator-on-in-suspend; 619 }; 620 }; 621 622 vccio_3v3: SWITCH_REG2 { 623 regulator-always-on; 624 regulator-boot-on; 625 regulator-name = "vccio_3v3"; 626 regulator-state-mem { 627 regulator-off-in-suspend; 628 }; 629 }; 630 }; 631 632 rk809_codec: codec { 633 #sound-dai-cells = <0>; 634 compatible = "rockchip,rk809-codec", "rockchip,rk817-codec"; 635 clocks = <&cru SCLK_I2S_8CH_OUT>; 636 clock-names = "mclk"; 637 pinctrl-names = "default"; 638 pinctrl-0 = <&i2s_8ch_mclk>; 639 hp-volume = <20>; 640 spk-volume = <3>; 641 status = "okay"; 642 }; 643 }; 644 645 vdd_cpu_b: syr837@40 { 646 compatible = "silergy,syr827"; 647 reg = <0x40>; 648 vin-supply = <&vcc5v0_sys>; 649 regulator-compatible = "fan53555-reg"; 650 pinctrl-0 = <&vsel1_gpio>; 651 vsel-gpios = <&gpio1 RK_PC1 GPIO_ACTIVE_HIGH>; 652 regulator-name = "vdd_cpu_b"; 653 regulator-min-microvolt = <712500>; 654 regulator-max-microvolt = <1500000>; 655 regulator-ramp-delay = <1000>; 656 fcs,suspend-voltage-selector = <1>; 657 regulator-always-on; 658 regulator-boot-on; 659 regulator-initial-state = <3>; 660 regulator-state-mem { 661 regulator-off-in-suspend; 662 }; 663 }; 664 665 vdd_gpu: syr828@41 { 666 compatible = "silergy,syr828"; 667 status = "okay"; 668 reg = <0x41>; 669 vin-supply = <&vcc5v0_sys>; 670 regulator-compatible = "fan53555-reg"; 671 pinctrl-0 = <&vsel2_gpio>; 672 vsel-gpios = <&gpio1 RK_PB6 GPIO_ACTIVE_HIGH>; 673 regulator-name = "vdd_gpu"; 674 regulator-min-microvolt = <735000>; 675 regulator-max-microvolt = <1400000>; 676 regulator-ramp-delay = <1000>; 677 fcs,suspend-voltage-selector = <1>; 678 regulator-always-on; 679 regulator-boot-on; 680 regulator-state-mem { 681 regulator-off-in-suspend; 682 }; 683 }; 684 685 bq25700: bq25700@6b { 686 compatible = "ti,bq25703"; 687 reg = <0x6b>; 688 interrupt-parent = <&gpio1>; 689 interrupts = <RK_PA1 IRQ_TYPE_LEVEL_LOW>; 690 pinctrl-names = "default"; 691 pinctrl-0 = <&charger_ok_int>; 692 ti,charge-current = <1500000>; 693 ti,max-charge-voltage = <8704000>; 694 ti,max-input-voltage = <20000000>; 695 ti,max-input-current = <6000000>; 696 ti,input-current-sdp = <500000>; 697 ti,input-current-dcp = <2000000>; 698 ti,input-current-cdp = <2000000>; 699 ti,input-current-dc = <2000000>; 700 ti,minimum-sys-voltage = <6700000>; 701 ti,otg-voltage = <5000000>; 702 ti,otg-current = <500000>; 703 ti,input-current = <500000>; 704 pd-charge-only = <0>; 705 status = "disabled"; 706 }; 707}; 708 709&i2c1 { 710 status = "okay"; 711 i2c-scl-rising-time-ns = <140>; 712 i2c-scl-falling-time-ns = <30>; 713 714 mpu6500@68 { 715 status = "okay"; 716 compatible = "invensense,mpu6500"; 717 reg = <0x68>; 718 irq-gpio = <&gpio3 RK_PD2 IRQ_TYPE_EDGE_RISING>; 719 mpu-int_config = <0x10>; 720 mpu-level_shifter = <0>; 721 mpu-orientation = <0 1 0 1 0 0 0 0 1>; 722 orientation-x= <0>; 723 orientation-y= <0>; 724 orientation-z= <1>; 725 mpu-debug = <1>; 726 }; 727 728 sensor@d { 729 status = "okay"; 730 compatible = "ak8963"; 731 reg = <0x0d>; 732 type = <SENSOR_TYPE_COMPASS>; 733 irq-gpio = <&gpio3 RK_PD7 IRQ_TYPE_EDGE_RISING>; 734 irq_enable = <0>; 735 poll_delay_ms = <30>; 736 layout = <3>; 737 }; 738}; 739 740&i2c4 { 741 status = "okay"; 742 i2c-scl-rising-time-ns = <345>; 743 i2c-scl-falling-time-ns = <11>; 744 745 gsl3673: gsl3673@40 { 746 compatible = "GSL,GSL3673"; 747 reg = <0x40>; 748 screen_max_x = <1536>; 749 screen_max_y = <2048>; 750 irq_gpio_number = <&gpio4 RK_PC3 IRQ_TYPE_LEVEL_LOW>; 751 rst_gpio_number = <&gpio4 RK_PC6 GPIO_ACTIVE_HIGH>; 752 }; 753}; 754 755&i2c8 { 756 status = "okay"; 757 i2c-scl-rising-time-ns = <345>; 758 i2c-scl-falling-time-ns = <11>; 759 clock-frequency = <100000>; 760 761 usbc0: fusb302@22 { 762 compatible = "fcs,fusb302"; 763 reg = <0x22>; 764 interrupt-parent = <&gpio1>; 765 interrupts = <RK_PA2 IRQ_TYPE_LEVEL_LOW>; 766 pinctrl-names = "default"; 767 pinctrl-0 = <&usbc0_int>; 768 vbus-supply = <&vbus_typec>; 769 status = "okay"; 770 771 ports { 772 #address-cells = <1>; 773 #size-cells = <0>; 774 775 port@0 { 776 reg = <0>; 777 usbc0_role_sw: endpoint@0 { 778 remote-endpoint = <&dwc3_0_role_switch>; 779 }; 780 }; 781 }; 782 783 usb_con: connector { 784 compatible = "usb-c-connector"; 785 label = "USB-C"; 786 data-role = "dual"; 787 power-role = "dual"; 788 try-power-role = "sink"; 789 op-sink-microwatt = <1000000>; 790 sink-pdos = 791 <PDO_FIXED(5000, 2500, PDO_FIXED_USB_COMM)>; 792 source-pdos = 793 <PDO_FIXED(5000, 1500, PDO_FIXED_USB_COMM)>; 794 795 ports { 796 #address-cells = <1>; 797 #size-cells = <0>; 798 799 port@0 { 800 reg = <0>; 801 usbc0_orien_sw: endpoint { 802 remote-endpoint = <&tcphy0_orientation_switch>; 803 }; 804 }; 805 }; 806 }; 807 }; 808}; 809 810&i2s1 { 811 status = "okay"; 812 #sound-dai-cells = <0>; 813}; 814 815&io_domains { 816 status = "okay"; 817 bt656-supply = <&vcca_1v8>; 818 audio-supply = <&vcca_1v8>; 819 sdmmc-supply = <&vccio_sd>; 820 gpio1830-supply = <&vcc_3v0>; 821}; 822 823&isp0_mmu { 824 status = "okay"; 825}; 826 827&isp1_mmu { 828 status = "okay"; 829}; 830 831&pcie_phy { 832 status = "disabled"; 833}; 834 835&pcie0 { 836 status = "disabled"; 837}; 838 839&pmu_io_domains { 840 status = "okay"; 841 pmu1830-supply = <&vcc_1v8>; 842}; 843 844&pwm0 { 845 status = "okay"; 846}; 847 848&pwm2 { 849 status = "okay"; 850}; 851 852&rk_key { 853 status = "disabled"; 854}; 855 856&rockchip_suspend { 857 status = "okay"; 858 rockchip,sleep-debug-en = <1>; 859 rockchip,sleep-mode-config = < 860 (0 861 | RKPM_SLP_ARMPD 862 | RKPM_SLP_PERILPPD 863 | RKPM_SLP_DDR_RET 864 | RKPM_SLP_PLLPD 865 | RKPM_SLP_CENTER_PD 866 | RKPM_SLP_OSC_DIS 867 | RKPM_SLP_AP_PWROFF 868 ) 869 >; 870 rockchip,wakeup-config = <RKPM_GPIO_WKUP_EN>; 871 rockchip,pwm-regulator-config = <PWM2_REGULATOR_EN>; 872 rockchip,power-ctrl = 873 <&gpio1 RK_PC1 GPIO_ACTIVE_HIGH>, 874 <&gpio1 RK_PB6 GPIO_ACTIVE_HIGH>; 875}; 876 877&route_edp { 878 status = "okay"; 879}; 880 881&saradc { 882 status = "okay"; 883 vref-supply = <&vcc_1v8>; 884}; 885 886&sdmmc { 887 sd-uhs-sdr12; 888 sd-uhs-sdr25; 889 sd-uhs-sdr50; 890 sd-uhs-sdr104; 891}; 892 893&spi1 { 894 status = "okay"; 895 max-freq = <48000000>; /* spi internal clk, don't modify */ 896 spi_dev@0 { 897 compatible = "rockchip,spidev"; 898 reg = <0>; 899 spi-max-frequency = <12000000>; 900 spi-lsb-first; 901 }; 902}; 903 904&tcphy0 { 905 status = "okay"; 906 orientation-switch; 907 port { 908 #address-cells = <1>; 909 #size-cells = <0>; 910 tcphy0_orientation_switch: endpoint@0 { 911 reg = <0>; 912 remote-endpoint = <&usbc0_orien_sw>; 913 }; 914 }; 915}; 916 917&tcphy1 { 918 status = "okay"; 919}; 920 921&tsadc { 922 rockchip,hw-tshut-mode = <1>; /* tshut mode 0:CRU 1:GPIO */ 923 rockchip,hw-tshut-polarity = <1>; /* tshut polarity 0:LOW 1:HIGH */ 924 status = "okay"; 925}; 926 927&u2phy0 { 928 status = "okay"; 929 930 u2phy0_otg: otg-port { 931 status = "okay"; 932 }; 933 934 u2phy0_host: host-port { 935 phy-supply = <&vcc5v0_usb>; 936 status = "okay"; 937 }; 938}; 939 940&u2phy1 { 941 status = "okay"; 942 943 u2phy1_otg: otg-port { 944 status = "okay"; 945 }; 946 947 u2phy1_host: host-port { 948 phy-supply = <&vcc5v0_usb>; 949 status = "okay"; 950 }; 951}; 952 953&uart0 { 954 pinctrl-names = "default"; 955 pinctrl-0 = <&uart0_xfer &uart0_cts>; 956 status = "okay"; 957}; 958 959&usb_host0_ehci { 960 status = "okay"; 961}; 962 963&usb_host1_ehci { 964 status = "okay"; 965}; 966&usb_host0_ohci { 967 status = "okay"; 968}; 969 970&usb_host1_ohci { 971 status = "okay"; 972}; 973 974&usbdrd3_0 { 975 status = "okay"; 976}; 977 978&usbdrd3_1 { 979 status = "okay"; 980}; 981 982&usbdrd_dwc3_0 { 983 status = "okay"; 984 usb-role-switch; 985 port { 986 #address-cells = <1>; 987 #size-cells = <0>; 988 dwc3_0_role_switch: endpoint@0 { 989 reg = <0>; 990 remote-endpoint = <&usbc0_role_sw>; 991 }; 992 }; 993}; 994 995&usbdrd_dwc3_1 { 996 status = "okay"; 997}; 998 999&vopb { 1000 assigned-clocks = <&cru DCLK_VOP0_DIV>; 1001 assigned-clock-parents = <&cru PLL_CPLL>; 1002}; 1003 1004&vopl { 1005 assigned-clocks = <&cru DCLK_VOP1_DIV>; 1006 assigned-clock-parents = <&cru PLL_VPLL>; 1007}; 1008 1009&pinctrl { 1010 pinctrl-names = "default"; 1011 pinctrl-0 = <&npu_ref_clk>; 1012 1013 bq2570 { 1014 charger_ok_int: charger-ok-int { 1015 rockchip,pins = 1016 <1 RK_PA1 RK_FUNC_GPIO &pcfg_pull_up>; 1017 }; 1018 }; 1019 1020 headphone { 1021 hp_det: hp-det { 1022 rockchip,pins = 1023 <0 RK_PB5 RK_FUNC_GPIO &pcfg_pull_up>; 1024 }; 1025 }; 1026 1027 lcd_rst { 1028 lcd_rst_gpio: lcd-rst-gpio { 1029 rockchip,pins = 1030 <3 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>; 1031 }; 1032 }; 1033 1034 npu_clk { 1035 npu_ref_clk: npu-ref-clk { 1036 rockchip,pins = 1037 <0 RK_PA2 1 &pcfg_pull_none>; 1038 }; 1039 }; 1040 1041 pmic { 1042 pmic_int_l: pmic-int-l { 1043 rockchip,pins = 1044 <1 RK_PC2 RK_FUNC_GPIO &pcfg_pull_up>; 1045 }; 1046 vsel1_gpio: vsel1-gpio { 1047 rockchip,pins = 1048 <1 RK_PC1 RK_FUNC_GPIO &pcfg_pull_down>; 1049 }; 1050 vsel2_gpio: vsel2-gpio { 1051 rockchip,pins = 1052 <1 RK_PB6 RK_FUNC_GPIO &pcfg_pull_down>; 1053 }; 1054 1055 soc_slppin_gpio: soc-slppin-gpio { 1056 rockchip,pins = 1057 <1 RK_PA5 RK_FUNC_GPIO &pcfg_output_low>; 1058 }; 1059 1060 soc_slppin_slp: soc-slppin-slp { 1061 rockchip,pins = 1062 <1 RK_PA5 1 &pcfg_pull_none>; 1063 }; 1064 }; 1065 1066 sdio-pwrseq { 1067 wifi_enable_h: wifi-enable-h { 1068 rockchip,pins = 1069 <2 RK_PD3 RK_FUNC_GPIO &pcfg_pull_none>; 1070 }; 1071 }; 1072 1073 sdmmc { 1074 sdmmc_bus1: sdmmc-bus1 { 1075 rockchip,pins = 1076 <4 RK_PB0 1 &pcfg_pull_up_10ma>; 1077 }; 1078 1079 sdmmc_bus4: sdmmc-bus4 { 1080 rockchip,pins = 1081 <4 RK_PB0 1 &pcfg_pull_up_10ma>, 1082 <4 RK_PB1 1 &pcfg_pull_up_10ma>, 1083 <4 RK_PB2 1 &pcfg_pull_up_10ma>, 1084 <4 RK_PB3 1 &pcfg_pull_up_10ma>; 1085 }; 1086 1087 sdmmc_clk: sdmmc-clk { 1088 rockchip,pins = 1089 <4 RK_PB4 1 &pcfg_pull_none_10ma>; 1090 }; 1091 1092 sdmmc_cmd: sdmmc-cmd { 1093 rockchip,pins = 1094 <4 RK_PB5 1 &pcfg_pull_up_10ma>; 1095 }; 1096 }; 1097 1098 tp_irq { 1099 tp_irq_gpio: tp-irq-gpio { 1100 rockchip,pins = 1101 <3 RK_PB0 RK_FUNC_GPIO &pcfg_pull_up>; 1102 }; 1103 }; 1104 1105 usb-typec { 1106 usbc0_int: usbc0-int { 1107 rockchip,pins = <1 RK_PA2 RK_FUNC_GPIO &pcfg_pull_up>; 1108 }; 1109 1110 vcc5v0_typec0_en: vcc5v0-typec0-en { 1111 rockchip,pins = <1 RK_PC2 RK_FUNC_GPIO &pcfg_pull_none>; 1112 }; 1113 }; 1114 1115 wireless-bluetooth { 1116 uart0_gpios: uart0-gpios { 1117 rockchip,pins = 1118 <2 RK_PC3 RK_FUNC_GPIO &pcfg_pull_none>; 1119 }; 1120 bt_irq_gpio: bt-irq-gpio { 1121 rockchip,pins = 1122 <0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_down>; 1123 }; 1124 }; 1125}; 1126