1// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2/* 3 * Copyright (c) 2017 Fuzhou Rockchip Electronics Co., Ltd. 4 * Copyright (c) 2018 Akash Gajjar <Akash_Gajjar@mentor.com> 5 * Copyright (c) 2020 Tobias Schramm <t.schramm@manjaro.org> 6 */ 7 8/dts-v1/; 9#include <dt-bindings/input/gpio-keys.h> 10#include <dt-bindings/input/linux-event-codes.h> 11#include <dt-bindings/pwm/pwm.h> 12#include <dt-bindings/usb/pd.h> 13#include <dt-bindings/leds/common.h> 14#include "rk3399.dtsi" 15#include "rk3399-opp.dtsi" 16 17/ { 18 model = "Pine64 Pinebook Pro"; 19 compatible = "pine64,pinebook-pro", "rockchip,rk3399"; 20 21 chosen { 22 stdout-path = "serial2:1500000n8"; 23 }; 24 25 backlight: edp-backlight { 26 compatible = "pwm-backlight"; 27 power-supply = <&vcc_12v>; 28 pwms = <&pwm0 0 740740 0>; 29 }; 30 31 edp_panel: edp-panel { 32 compatible = "boe,nv140fhmn49"; 33 backlight = <&backlight>; 34 enable-gpios = <&gpio1 RK_PA0 GPIO_ACTIVE_HIGH>; 35 pinctrl-names = "default"; 36 pinctrl-0 = <&panel_en_gpio>; 37 power-supply = <&vcc3v3_panel>; 38 39 ports { 40 #address-cells = <1>; 41 #size-cells = <0>; 42 43 port@0 { 44 reg = <0>; 45 #address-cells = <1>; 46 #size-cells = <0>; 47 48 panel_in_edp: endpoint@0 { 49 reg = <0>; 50 remote-endpoint = <&edp_out_panel>; 51 }; 52 }; 53 }; 54 }; 55 56 /* 57 * Use separate nodes for gpio-keys to allow for selective deactivation 58 * of wakeup sources via sysfs without disabling the whole key 59 */ 60 gpio-key-lid { 61 compatible = "gpio-keys"; 62 pinctrl-names = "default"; 63 pinctrl-0 = <&lidbtn_gpio>; 64 65 lid { 66 debounce-interval = <20>; 67 gpios = <&gpio1 RK_PA1 GPIO_ACTIVE_LOW>; 68 label = "Lid"; 69 linux,code = <SW_LID>; 70 linux,input-type = <EV_SW>; 71 wakeup-event-action = <EV_ACT_DEASSERTED>; 72 wakeup-source; 73 }; 74 }; 75 76 gpio-key-power { 77 compatible = "gpio-keys"; 78 pinctrl-names = "default"; 79 pinctrl-0 = <&pwrbtn_gpio>; 80 81 power { 82 debounce-interval = <20>; 83 gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_LOW>; 84 label = "Power"; 85 linux,code = <KEY_POWER>; 86 wakeup-source; 87 }; 88 }; 89 90 leds { 91 compatible = "gpio-leds"; 92 pinctrl-names = "default"; 93 pinctrl-0 = <&pwrled_gpio &slpled_gpio>; 94 95 green-led { 96 color = <LED_COLOR_ID_GREEN>; 97 default-state = "on"; 98 function = LED_FUNCTION_POWER; 99 gpios = <&gpio0 RK_PB3 GPIO_ACTIVE_HIGH>; 100 label = "green:power"; 101 }; 102 103 red-led { 104 color = <LED_COLOR_ID_RED>; 105 default-state = "off"; 106 function = LED_FUNCTION_STANDBY; 107 gpios = <&gpio0 RK_PA2 GPIO_ACTIVE_HIGH>; 108 label = "red:standby"; 109 panic-indicator; 110 retain-state-suspended; 111 }; 112 }; 113 114 /* Power sequence for SDIO WiFi module */ 115 sdio_pwrseq: sdio-pwrseq { 116 compatible = "mmc-pwrseq-simple"; 117 clocks = <&rk808 1>; 118 clock-names = "ext_clock"; 119 pinctrl-names = "default"; 120 pinctrl-0 = <&wifi_enable_h_gpio>; 121 post-power-on-delay-ms = <100>; 122 power-off-delay-us = <500000>; 123 124 /* WL_REG_ON on module */ 125 reset-gpios = <&gpio0 RK_PB2 GPIO_ACTIVE_LOW>; 126 }; 127 128 /* Audio components */ 129 es8316-sound { 130 compatible = "simple-audio-card"; 131 pinctrl-names = "default"; 132 pinctrl-0 = <&hp_det_gpio>; 133 simple-audio-card,name = "rockchip,es8316-codec"; 134 simple-audio-card,format = "i2s"; 135 simple-audio-card,mclk-fs = <256>; 136 137 simple-audio-card,widgets = 138 "Microphone", "Mic Jack", 139 "Headphone", "Headphones", 140 "Speaker", "Speaker"; 141 simple-audio-card,routing = 142 "MIC1", "Mic Jack", 143 "Headphones", "HPOL", 144 "Headphones", "HPOR", 145 "Speaker Amplifier INL", "HPOL", 146 "Speaker Amplifier INR", "HPOR", 147 "Speaker", "Speaker Amplifier OUTL", 148 "Speaker", "Speaker Amplifier OUTR"; 149 150 simple-audio-card,hp-det-gpio = <&gpio0 RK_PB0 GPIO_ACTIVE_LOW>; 151 simple-audio-card,aux-devs = <&speaker_amp>; 152 simple-audio-card,pin-switches = "Speaker"; 153 154 simple-audio-card,cpu { 155 sound-dai = <&i2s1>; 156 }; 157 158 simple-audio-card,codec { 159 sound-dai = <&es8316>; 160 }; 161 }; 162 163 speaker_amp: speaker-amplifier { 164 compatible = "simple-audio-amplifier"; 165 enable-gpios = <&gpio4 RK_PD3 GPIO_ACTIVE_HIGH>; 166 sound-name-prefix = "Speaker Amplifier"; 167 VCC-supply = <&pa_5v>; 168 }; 169 170 /* Power tree */ 171 /* Root power source */ 172 vcc_sysin: vcc-sysin { 173 compatible = "regulator-fixed"; 174 regulator-name = "vcc_sysin"; 175 regulator-always-on; 176 regulator-boot-on; 177 }; 178 179 /* Regulators supplied by vcc_sysin */ 180 /* LCD backlight supply */ 181 vcc_12v: vcc-12v { 182 compatible = "regulator-fixed"; 183 regulator-name = "vcc_12v"; 184 regulator-always-on; 185 regulator-boot-on; 186 regulator-min-microvolt = <12000000>; 187 regulator-max-microvolt = <12000000>; 188 vin-supply = <&vcc_sysin>; 189 190 regulator-state-mem { 191 regulator-off-in-suspend; 192 }; 193 }; 194 195 /* Main 3.3 V supply */ 196 vcc3v3_sys: wifi_bat: vcc3v3-sys { 197 compatible = "regulator-fixed"; 198 regulator-name = "vcc3v3_sys"; 199 regulator-always-on; 200 regulator-boot-on; 201 regulator-min-microvolt = <3300000>; 202 regulator-max-microvolt = <3300000>; 203 vin-supply = <&vcc_sysin>; 204 205 regulator-state-mem { 206 regulator-on-in-suspend; 207 }; 208 }; 209 210 /* 5 V USB power supply */ 211 vcc5v0_usb: pa_5v: vcc5v0-usb-regulator { 212 compatible = "regulator-fixed"; 213 enable-active-high; 214 gpio = <&gpio1 RK_PB5 GPIO_ACTIVE_HIGH>; 215 pinctrl-names = "default"; 216 pinctrl-0 = <&pwr_5v_gpio>; 217 regulator-name = "vcc5v0_usb"; 218 regulator-always-on; 219 regulator-min-microvolt = <5000000>; 220 regulator-max-microvolt = <5000000>; 221 vin-supply = <&vcc_sysin>; 222 223 regulator-state-mem { 224 regulator-off-in-suspend; 225 }; 226 }; 227 228 /* RK3399 logic supply */ 229 vdd_log: vdd-log { 230 compatible = "pwm-regulator"; 231 pwms = <&pwm2 0 25000 1>; 232 regulator-name = "vdd_log"; 233 regulator-always-on; 234 regulator-boot-on; 235 regulator-min-microvolt = <800000>; 236 regulator-max-microvolt = <1400000>; 237 vin-supply = <&vcc_sysin>; 238 239 regulator-state-mem { 240 regulator-on-in-suspend; 241 }; 242 }; 243 244 /* Regulators supplied by vcc3v3_sys */ 245 /* 0.9 V supply, always on */ 246 vcc_0v9: vcc-0v9 { 247 compatible = "regulator-fixed"; 248 regulator-name = "vcc_0v9"; 249 regulator-always-on; 250 regulator-boot-on; 251 regulator-min-microvolt = <900000>; 252 regulator-max-microvolt = <900000>; 253 vin-supply = <&vcc3v3_sys>; 254 }; 255 256 /* S3 1.8 V supply, switched by vcc1v8_s3 */ 257 vcca1v8_s3: vcc1v8-s3 { 258 compatible = "regulator-fixed"; 259 regulator-name = "vcca1v8_s3"; 260 regulator-always-on; 261 regulator-boot-on; 262 regulator-min-microvolt = <1800000>; 263 regulator-max-microvolt = <1800000>; 264 vin-supply = <&vcc3v3_sys>; 265 }; 266 267 /* micro SD card power */ 268 vcc3v0_sd: vcc3v0-sd { 269 compatible = "regulator-fixed"; 270 enable-active-high; 271 gpio = <&gpio0 RK_PA1 GPIO_ACTIVE_HIGH>; 272 pinctrl-names = "default"; 273 pinctrl-0 = <&sdmmc0_pwr_h_gpio>; 274 regulator-name = "vcc3v0_sd"; 275 regulator-always-on; 276 regulator-min-microvolt = <3000000>; 277 regulator-max-microvolt = <3000000>; 278 vin-supply = <&vcc3v3_sys>; 279 280 regulator-state-mem { 281 regulator-off-in-suspend; 282 }; 283 }; 284 285 /* LCD panel power, called VCC3V3_S0 in schematic */ 286 vcc3v3_panel: vcc3v3-panel { 287 compatible = "regulator-fixed"; 288 enable-active-high; 289 gpio = <&gpio1 RK_PC6 GPIO_ACTIVE_HIGH>; 290 pinctrl-names = "default"; 291 pinctrl-0 = <&lcdvcc_en_gpio>; 292 regulator-name = "vcc3v3_panel"; 293 regulator-always-on; 294 regulator-min-microvolt = <3300000>; 295 regulator-max-microvolt = <3300000>; 296 regulator-enable-ramp-delay = <100000>; 297 vin-supply = <&vcc3v3_sys>; 298 299 regulator-state-mem { 300 regulator-off-in-suspend; 301 }; 302 }; 303 304 /* M.2 adapter power, switched by vcc1v8_s3 */ 305 vcc3v3_ssd: vcc3v3-ssd { 306 compatible = "regulator-fixed"; 307 regulator-name = "vcc3v3_ssd"; 308 regulator-min-microvolt = <3300000>; 309 regulator-max-microvolt = <3300000>; 310 vin-supply = <&vcc3v3_sys>; 311 }; 312 313 /* Regulators supplied by vcc5v0_usb */ 314 /* USB 3 port power supply regulator */ 315 vcc5v0_otg: vcc5v0-otg { 316 compatible = "regulator-fixed"; 317 enable-active-high; 318 gpio = <&gpio4 RK_PD2 GPIO_ACTIVE_HIGH>; 319 pinctrl-names = "default"; 320 pinctrl-0 = <&vcc5v0_host_en_gpio>; 321 regulator-name = "vcc5v0_otg"; 322 regulator-always-on; 323 regulator-min-microvolt = <5000000>; 324 regulator-max-microvolt = <5000000>; 325 vin-supply = <&vcc5v0_usb>; 326 327 regulator-state-mem { 328 regulator-off-in-suspend; 329 }; 330 }; 331 332 /* Regulators supplied by vcc5v0_usb */ 333 /* Type C port power supply regulator */ 334 vbus_5vout: vbus_typec: vbus-5vout { 335 compatible = "regulator-fixed"; 336 enable-active-high; 337 gpio = <&gpio1 RK_PA3 GPIO_ACTIVE_HIGH>; 338 pinctrl-names = "default"; 339 pinctrl-0 = <&vcc5v0_typec0_en_gpio>; 340 regulator-name = "vbus_5vout"; 341 regulator-min-microvolt = <5000000>; 342 regulator-max-microvolt = <5000000>; 343 vin-supply = <&vcc5v0_usb>; 344 345 regulator-state-mem { 346 regulator-off-in-suspend; 347 }; 348 }; 349 350 /* Regulators supplied by vcc_1v8 */ 351 /* Primary 0.9 V LDO */ 352 vcca0v9_s3: vcca0v9-s3 { 353 compatible = "regulator-fixed"; 354 regulator-name = "vcc0v9_s3"; 355 regulator-min-microvolt = <5000000>; 356 regulator-max-microvolt = <5000000>; 357 vin-supply = <&vcc_1v8>; 358 359 regulator-state-mem { 360 regulator-on-in-suspend; 361 }; 362 }; 363 364 mains_charger: dc-charger { 365 compatible = "gpio-charger"; 366 charger-type = "mains"; 367 gpios = <&gpio4 RK_PD0 GPIO_ACTIVE_LOW>; 368 369 /* Also triggered by USB charger */ 370 pinctrl-names = "default"; 371 pinctrl-0 = <&dc_det_gpio>; 372 }; 373}; 374 375&cdn_dp { 376 status = "okay"; 377}; 378 379&cpu_b0 { 380 cpu-supply = <&vdd_cpu_b>; 381}; 382 383&cpu_b1 { 384 cpu-supply = <&vdd_cpu_b>; 385}; 386 387&cpu_l0 { 388 cpu-supply = <&vdd_cpu_l>; 389}; 390 391&cpu_l1 { 392 cpu-supply = <&vdd_cpu_l>; 393}; 394 395&cpu_l2 { 396 cpu-supply = <&vdd_cpu_l>; 397}; 398 399&cpu_l3 { 400 cpu-supply = <&vdd_cpu_l>; 401}; 402 403&edp { 404 force-hpd; 405 pinctrl-names = "default"; 406 pinctrl-0 = <&edp_hpd>; 407 status = "okay"; 408 409 ports { 410 edp_out: port@1 { 411 reg = <1>; 412 #address-cells = <1>; 413 #size-cells = <0>; 414 415 edp_out_panel: endpoint@0 { 416 reg = <0>; 417 remote-endpoint = <&panel_in_edp>; 418 }; 419 }; 420 }; 421}; 422 423&emmc_phy { 424 status = "okay"; 425}; 426 427&gpu { 428 mali-supply = <&vdd_gpu>; 429 status = "okay"; 430}; 431 432&hdmi_sound { 433 status = "okay"; 434}; 435 436&i2c0 { 437 clock-frequency = <400000>; 438 i2c-scl-falling-time-ns = <4>; 439 i2c-scl-rising-time-ns = <168>; 440 status = "okay"; 441 442 rk808: pmic@1b { 443 compatible = "rockchip,rk808"; 444 reg = <0x1b>; 445 #clock-cells = <1>; 446 clock-output-names = "xin32k", "rk808-clkout2"; 447 interrupt-parent = <&gpio3>; 448 interrupts = <10 IRQ_TYPE_LEVEL_LOW>; 449 pinctrl-names = "default"; 450 pinctrl-0 = <&pmic_int_l_gpio>; 451 rockchip,system-power-controller; 452 wakeup-source; 453 454 vcc1-supply = <&vcc_sysin>; 455 vcc2-supply = <&vcc_sysin>; 456 vcc3-supply = <&vcc_sysin>; 457 vcc4-supply = <&vcc_sysin>; 458 vcc6-supply = <&vcc_sysin>; 459 vcc7-supply = <&vcc_sysin>; 460 vcc8-supply = <&vcc3v3_sys>; 461 vcc9-supply = <&vcc_sysin>; 462 vcc10-supply = <&vcc_sysin>; 463 vcc11-supply = <&vcc_sysin>; 464 vcc12-supply = <&vcc3v3_sys>; 465 vcc13-supply = <&vcc_sysin>; 466 vcc14-supply = <&vcc_sysin>; 467 468 regulators { 469 /* rk3399 center logic supply */ 470 vdd_center: DCDC_REG1 { 471 regulator-name = "vdd_center"; 472 regulator-always-on; 473 regulator-boot-on; 474 regulator-min-microvolt = <750000>; 475 regulator-max-microvolt = <1350000>; 476 regulator-ramp-delay = <6001>; 477 478 regulator-state-mem { 479 regulator-off-in-suspend; 480 }; 481 }; 482 483 vdd_cpu_l: DCDC_REG2 { 484 regulator-name = "vdd_cpu_l"; 485 regulator-always-on; 486 regulator-boot-on; 487 regulator-min-microvolt = <750000>; 488 regulator-max-microvolt = <1350000>; 489 regulator-ramp-delay = <6001>; 490 491 regulator-state-mem { 492 regulator-off-in-suspend; 493 }; 494 }; 495 496 vcc_ddr: DCDC_REG3 { 497 regulator-name = "vcc_ddr"; 498 regulator-always-on; 499 regulator-boot-on; 500 501 regulator-state-mem { 502 regulator-on-in-suspend; 503 }; 504 }; 505 506 vcc_1v8: vcc_wl: DCDC_REG4 { 507 regulator-name = "vcc_1v8"; 508 regulator-always-on; 509 regulator-boot-on; 510 regulator-min-microvolt = <1800000>; 511 regulator-max-microvolt = <1800000>; 512 513 regulator-state-mem { 514 regulator-on-in-suspend; 515 regulator-suspend-microvolt = <1800000>; 516 }; 517 }; 518 519 /* not used */ 520 LDO_REG1 { 521 }; 522 523 /* not used */ 524 LDO_REG2 { 525 }; 526 527 vcc1v8_pmupll: LDO_REG3 { 528 regulator-name = "vcc1v8_pmupll"; 529 regulator-always-on; 530 regulator-boot-on; 531 regulator-min-microvolt = <1800000>; 532 regulator-max-microvolt = <1800000>; 533 534 regulator-state-mem { 535 regulator-on-in-suspend; 536 regulator-suspend-microvolt = <1800000>; 537 }; 538 }; 539 540 vcc_sdio: LDO_REG4 { 541 regulator-name = "vcc_sdio"; 542 regulator-always-on; 543 regulator-boot-on; 544 regulator-min-microvolt = <1800000>; 545 regulator-max-microvolt = <3000000>; 546 547 regulator-state-mem { 548 regulator-on-in-suspend; 549 regulator-suspend-microvolt = <3000000>; 550 }; 551 }; 552 553 vcca3v0_codec: LDO_REG5 { 554 regulator-name = "vcca3v0_codec"; 555 regulator-always-on; 556 regulator-boot-on; 557 regulator-min-microvolt = <3000000>; 558 regulator-max-microvolt = <3000000>; 559 560 regulator-state-mem { 561 regulator-off-in-suspend; 562 }; 563 }; 564 565 vcc_1v5: LDO_REG6 { 566 regulator-name = "vcc_1v5"; 567 regulator-always-on; 568 regulator-boot-on; 569 regulator-min-microvolt = <1500000>; 570 regulator-max-microvolt = <1500000>; 571 572 regulator-state-mem { 573 regulator-on-in-suspend; 574 regulator-suspend-microvolt = <1500000>; 575 }; 576 }; 577 578 vcca1v8_codec: LDO_REG7 { 579 regulator-name = "vcca1v8_codec"; 580 regulator-always-on; 581 regulator-boot-on; 582 regulator-min-microvolt = <1800000>; 583 regulator-max-microvolt = <1800000>; 584 585 regulator-state-mem { 586 regulator-off-in-suspend; 587 }; 588 }; 589 590 vcc_3v0: LDO_REG8 { 591 regulator-name = "vcc_3v0"; 592 regulator-always-on; 593 regulator-boot-on; 594 regulator-min-microvolt = <3000000>; 595 regulator-max-microvolt = <3000000>; 596 597 regulator-state-mem { 598 regulator-on-in-suspend; 599 regulator-suspend-microvolt = <3000000>; 600 }; 601 }; 602 603 vcc3v3_s3: SWITCH_REG1 { 604 regulator-name = "vcc3v3_s3"; 605 regulator-always-on; 606 regulator-boot-on; 607 608 regulator-state-mem { 609 regulator-off-in-suspend; 610 }; 611 }; 612 613 vcc3v3_s0: SWITCH_REG2 { 614 regulator-name = "vcc3v3_s0"; 615 regulator-always-on; 616 regulator-boot-on; 617 618 regulator-state-mem { 619 regulator-off-in-suspend; 620 }; 621 }; 622 }; 623 }; 624 625 vdd_cpu_b: regulator@40 { 626 compatible = "silergy,syr827"; 627 reg = <0x40>; 628 fcs,suspend-voltage-selector = <1>; 629 pinctrl-names = "default"; 630 pinctrl-0 = <&vsel1_gpio>; 631 regulator-name = "vdd_cpu_b"; 632 regulator-always-on; 633 regulator-boot-on; 634 regulator-min-microvolt = <712500>; 635 regulator-max-microvolt = <1500000>; 636 regulator-ramp-delay = <1000>; 637 vin-supply = <&vcc_1v8>; 638 639 regulator-state-mem { 640 regulator-off-in-suspend; 641 }; 642 }; 643 644 vdd_gpu: regulator@41 { 645 compatible = "silergy,syr828"; 646 reg = <0x41>; 647 fcs,suspend-voltage-selector = <1>; 648 pinctrl-names = "default"; 649 pinctrl-0 = <&vsel2_gpio>; 650 regulator-name = "vdd_gpu"; 651 regulator-always-on; 652 regulator-boot-on; 653 regulator-min-microvolt = <712500>; 654 regulator-max-microvolt = <1500000>; 655 regulator-ramp-delay = <1000>; 656 vin-supply = <&vcc_1v8>; 657 658 regulator-state-mem { 659 regulator-off-in-suspend; 660 }; 661 }; 662}; 663 664&i2c1 { 665 clock-frequency = <100000>; 666 i2c-scl-falling-time-ns = <4>; 667 i2c-scl-rising-time-ns = <168>; 668 status = "okay"; 669 670 es8316: es8316@11 { 671 compatible = "everest,es8316"; 672 reg = <0x11>; 673 clocks = <&cru SCLK_I2S_8CH_OUT>; 674 clock-names = "mclk"; 675 #sound-dai-cells = <0>; 676 }; 677}; 678 679&i2c3 { 680 i2c-scl-falling-time-ns = <15>; 681 i2c-scl-rising-time-ns = <450>; 682 status = "okay"; 683}; 684 685&i2c4 { 686 i2c-scl-falling-time-ns = <20>; 687 i2c-scl-rising-time-ns = <600>; 688 status = "okay"; 689 690 fusb0: fusb30x@22 { 691 compatible = "fcs,fusb302"; 692 reg = <0x22>; 693 fcs,int_n = <&gpio1 RK_PA2 GPIO_ACTIVE_HIGH>; 694 pinctrl-names = "default"; 695 pinctrl-0 = <&fusb0_int_gpio>; 696 vbus-supply = <&vbus_typec>; 697 698 connector { 699 compatible = "usb-c-connector"; 700 data-role = "host"; 701 label = "USB-C"; 702 op-sink-microwatt = <1000000>; 703 power-role = "dual"; 704 sink-pdos = 705 <PDO_FIXED(5000, 2500, PDO_FIXED_USB_COMM)>; 706 source-pdos = 707 <PDO_FIXED(5000, 1400, PDO_FIXED_USB_COMM)>; 708 try-power-role = "sink"; 709 710 ports { 711 #address-cells = <1>; 712 #size-cells = <0>; 713 714 port@0 { 715 reg = <0>; 716 717 usbc_hs: endpoint { 718 remote-endpoint = 719 <&u2phy0_typec_hs>; 720 }; 721 }; 722 723 port@1 { 724 reg = <1>; 725 726 usbc_ss: endpoint { 727 remote-endpoint = 728 <&tcphy0_typec_ss>; 729 }; 730 }; 731 732 port@2 { 733 reg = <2>; 734 735 usbc_dp: endpoint { 736 remote-endpoint = 737 <&tcphy0_typec_dp>; 738 }; 739 }; 740 }; 741 }; 742 }; 743}; 744 745&i2s1 { 746 #sound-dai-cells = <0>; 747 pinctrl-names = "default"; 748 pinctrl-0 = <&i2s_8ch_mclk_gpio>, <&i2s1_2ch_bus>; 749 rockchip,capture-channels = <8>; 750 rockchip,playback-channels = <8>; 751 status = "okay"; 752}; 753 754&io_domains { 755 audio-supply = <&vcc_3v0>; 756 gpio1830-supply = <&vcc_3v0>; 757 sdmmc-supply = <&vcc_sdio>; 758 status = "okay"; 759}; 760 761&pcie_phy { 762 status = "okay"; 763}; 764 765&pcie0 { 766 bus-scan-delay-ms = <1000>; 767 ep-gpios = <&gpio2 RK_PD4 GPIO_ACTIVE_HIGH>; 768 max-link-speed = <2>; 769 num-lanes = <4>; 770 pinctrl-names = "default"; 771 pinctrl-0 = <&pcie_clkreqn_cpm>; 772 vpcie0v9-supply = <&vcca0v9_s3>; 773 vpcie1v8-supply = <&vcca1v8_s3>; 774 vpcie3v3-supply = <&vcc3v3_ssd>; 775 status = "okay"; 776}; 777 778&pinctrl { 779 buttons { 780 pwrbtn_gpio: pwrbtn-gpio { 781 rockchip,pins = <0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_up>; 782 }; 783 784 lidbtn_gpio: lidbtn-gpio { 785 rockchip,pins = <1 RK_PA1 RK_FUNC_GPIO &pcfg_pull_up>; 786 }; 787 }; 788 789 dc-charger { 790 dc_det_gpio: dc-det-gpio { 791 rockchip,pins = <4 RK_PD0 RK_FUNC_GPIO &pcfg_pull_none>; 792 }; 793 }; 794 795 es8316 { 796 hp_det_gpio: hp-det-gpio { 797 rockchip,pins = <0 RK_PB0 RK_FUNC_GPIO &pcfg_pull_down>; 798 }; 799 }; 800 801 fusb302x { 802 fusb0_int_gpio: fusb0-int-gpio { 803 rockchip,pins = <1 RK_PA2 RK_FUNC_GPIO &pcfg_pull_up>; 804 }; 805 }; 806 807 i2s1 { 808 i2s_8ch_mclk_gpio: i2s-8ch-mclk-gpio { 809 rockchip,pins = <4 RK_PA0 1 &pcfg_pull_none>; 810 }; 811 }; 812 813 lcd-panel { 814 lcdvcc_en_gpio: lcdvcc-en-gpio { 815 rockchip,pins = <1 RK_PC6 RK_FUNC_GPIO &pcfg_pull_none>; 816 }; 817 818 panel_en_gpio: panel-en-gpio { 819 rockchip,pins = <1 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>; 820 }; 821 822 lcd_panel_reset_gpio: lcd-panel-reset-gpio { 823 rockchip,pins = <4 RK_PD6 RK_FUNC_GPIO &pcfg_pull_up>; 824 }; 825 }; 826 827 leds { 828 pwrled_gpio: pwrled_gpio { 829 rockchip,pins = <0 RK_PB3 RK_FUNC_GPIO &pcfg_pull_none>; 830 }; 831 832 slpled_gpio: slpled_gpio { 833 rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>; 834 }; 835 }; 836 837 pmic { 838 pmic_int_l_gpio: pmic-int-l-gpio { 839 rockchip,pins = <3 RK_PB2 RK_FUNC_GPIO &pcfg_pull_up>; 840 }; 841 842 vsel1_gpio: vsel1-gpio { 843 rockchip,pins = <1 RK_PC1 RK_FUNC_GPIO &pcfg_pull_down>; 844 }; 845 846 vsel2_gpio: vsel2-gpio { 847 rockchip,pins = <1 RK_PB6 RK_FUNC_GPIO &pcfg_pull_down>; 848 }; 849 }; 850 851 sdcard { 852 sdmmc0_pwr_h_gpio: sdmmc0-pwr-h-gpio { 853 rockchip,pins = <0 RK_PA1 RK_FUNC_GPIO &pcfg_pull_none>; 854 }; 855 856 }; 857 858 sdio-pwrseq { 859 wifi_enable_h_gpio: wifi-enable-h-gpio { 860 rockchip,pins = <0 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>; 861 }; 862 }; 863 864 usb-typec { 865 vcc5v0_typec0_en_gpio: vcc5v0-typec0-en-gpio { 866 rockchip,pins = <1 RK_PA3 RK_FUNC_GPIO &pcfg_pull_up>; 867 }; 868 }; 869 870 usb2 { 871 pwr_5v_gpio: pwr-5v-gpio { 872 rockchip,pins = <1 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>; 873 }; 874 875 vcc5v0_host_en_gpio: vcc5v0-host-en-gpio { 876 rockchip,pins = <4 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>; 877 }; 878 }; 879 880 wireless-bluetooth { 881 bt_wake_gpio: bt-wake-gpio { 882 rockchip,pins = <2 RK_PD3 RK_FUNC_GPIO &pcfg_pull_none>; 883 }; 884 885 bt_host_wake_gpio: bt-host-wake-gpio { 886 rockchip,pins = <0 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>; 887 }; 888 889 bt_reset_gpio: bt-reset-gpio { 890 rockchip,pins = <0 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>; 891 }; 892 }; 893}; 894 895&pmu_io_domains { 896 pmu1830-supply = <&vcc_3v0>; 897 status = "okay"; 898}; 899 900&pwm0 { 901 status = "okay"; 902}; 903 904&pwm2 { 905 status = "okay"; 906}; 907 908&saradc { 909 vref-supply = <&vcca1v8_s3>; 910 status = "okay"; 911}; 912 913&sdmmc { 914 bus-width = <4>; 915 cap-mmc-highspeed; 916 cap-sd-highspeed; 917 cd-gpios = <&gpio0 RK_PA7 GPIO_ACTIVE_LOW>; 918 disable-wp; 919 pinctrl-names = "default"; 920 pinctrl-0 = <&sdmmc_clk &sdmmc_cmd &sdmmc_bus4>; 921 sd-uhs-sdr104; 922 vmmc-supply = <&vcc3v0_sd>; 923 vqmmc-supply = <&vcc_sdio>; 924 status = "okay"; 925}; 926 927&sdio0 { 928 bus-width = <4>; 929 cap-sd-highspeed; 930 cap-sdio-irq; 931 keep-power-in-suspend; 932 mmc-pwrseq = <&sdio_pwrseq>; 933 non-removable; 934 pinctrl-names = "default"; 935 pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &sdio0_clk>; 936 sd-uhs-sdr104; 937 status = "okay"; 938}; 939 940&sdhci { 941 bus-width = <8>; 942 mmc-hs200-1_8v; 943 non-removable; 944 status = "okay"; 945}; 946 947&spi1 { 948 max-freq = <10000000>; 949 status = "okay"; 950 951 spiflash: flash@0 { 952 compatible = "jedec,spi-nor"; 953 reg = <0>; 954 m25p,fast-read; 955 spi-max-frequency = <10000000>; 956 }; 957}; 958 959&tcphy0 { 960 status = "okay"; 961}; 962 963&tcphy0_dp { 964 port { 965 tcphy0_typec_dp: endpoint { 966 remote-endpoint = <&usbc_dp>; 967 }; 968 }; 969}; 970 971&tcphy0_usb3 { 972 port { 973 tcphy0_typec_ss: endpoint { 974 remote-endpoint = <&usbc_ss>; 975 }; 976 }; 977}; 978 979&tcphy1 { 980 status = "okay"; 981}; 982 983&tsadc { 984 /* tshut mode 0:CRU 1:GPIO */ 985 rockchip,hw-tshut-mode = <1>; 986 /* tshut polarity 0:LOW 1:HIGH */ 987 rockchip,hw-tshut-polarity = <1>; 988 status = "okay"; 989}; 990 991&u2phy0 { 992 status = "okay"; 993 994 u2phy0_otg: otg-port { 995 status = "okay"; 996 }; 997 998 u2phy0_host: host-port { 999 phy-supply = <&vcc5v0_otg>; 1000 status = "okay"; 1001 }; 1002 1003 port { 1004 u2phy0_typec_hs: endpoint { 1005 remote-endpoint = <&usbc_hs>; 1006 }; 1007 }; 1008}; 1009 1010&u2phy1 { 1011 status = "okay"; 1012 1013 u2phy1_otg: otg-port { 1014 status = "okay"; 1015 }; 1016 1017 u2phy1_host: host-port { 1018 phy-supply = <&vcc5v0_otg>; 1019 status = "okay"; 1020 }; 1021}; 1022 1023&uart0 { 1024 pinctrl-names = "default"; 1025 pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>; 1026 uart-has-rtscts; 1027 status = "okay"; 1028 1029 bluetooth { 1030 compatible = "brcm,bcm4345c5"; 1031 clocks = <&rk808 1>; 1032 clock-names = "lpo"; 1033 device-wakeup-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_HIGH>; 1034 host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>; 1035 max-speed = <1500000>; 1036 pinctrl-names = "default"; 1037 pinctrl-0 = <&bt_host_wake_gpio &bt_wake_gpio &bt_reset_gpio>; 1038 shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>; 1039 vbat-supply = <&wifi_bat>; 1040 vddio-supply = <&vcc_wl>; 1041 }; 1042}; 1043 1044&uart2 { 1045 status = "okay"; 1046}; 1047 1048&usb_host0_ehci { 1049 status = "okay"; 1050}; 1051 1052&usb_host0_ohci { 1053 status = "okay"; 1054}; 1055 1056&usb_host1_ehci { 1057 status = "okay"; 1058}; 1059 1060&usb_host1_ohci { 1061 status = "okay"; 1062}; 1063 1064&usbdrd3_0 { 1065 status = "okay"; 1066}; 1067 1068&usbdrd_dwc3_0 { 1069 dr_mode = "host"; 1070 status = "okay"; 1071}; 1072 1073&usbdrd3_1 { 1074 status = "okay"; 1075}; 1076 1077&usbdrd_dwc3_1 { 1078 dr_mode = "host"; 1079 status = "okay"; 1080}; 1081 1082&vopb { 1083 status = "okay"; 1084}; 1085 1086&vopb_mmu { 1087 status = "okay"; 1088}; 1089 1090&vopl { 1091 status = "okay"; 1092}; 1093 1094&vopl_mmu { 1095 status = "okay"; 1096}; 1097