1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2 3 /dts-v1/; 4 5 #include <dt-bindings/gpio/gpio.h> 6 #include <dt-bindings/leds/common.h> 7 #include <dt-bindings/pinctrl/rockchip.h> 8 #include <dt-bindings/usb/pd.h> 9 #include "rk3588s.dtsi" 10 11 / { 12 model = "Hardkernel ODROID-M2"; 13 compatible = "hardkernel,odroid-m2", " 14 15 aliases { 16 ethernet0 = &gmac1; 17 mmc0 = &sdhci; 18 mmc1 = &sdmmc; 19 }; 20 21 chosen { 22 stdout-path = "serial2:1500000 23 }; 24 25 leds { 26 compatible = "gpio-leds"; 27 pinctrl-names = "default"; 28 pinctrl-0 = <&pwr_led>, <&sys_ 29 30 led_pwr: led-0 { 31 color = <LED_COLOR_ID_ 32 default-state = "on"; 33 function = LED_FUNCTIO 34 gpios = <&gpio1 RK_PB5 35 linux,default-trigger 36 }; 37 38 led_sys: led-1 { 39 color = <LED_COLOR_ID_ 40 default-state = "on"; 41 function = LED_FUNCTIO 42 gpios = <&gpio1 RK_PB1 43 linux,default-trigger 44 }; 45 }; 46 47 fan: pwm-fan { 48 compatible = "pwm-fan"; 49 #cooling-cells = <2>; 50 cooling-levels = <0 192 224 25 51 fan-supply = <&vcc5v0_sys>; 52 pwms = <&pwm0 0 22222 0>; 53 }; 54 55 vcc_1v1_nldo_s3: regulator-1v1-vcc-nld 56 compatible = "regulator-fixed" 57 regulator-name = "vcc_1v1_nldo 58 regulator-always-on; 59 regulator-boot-on; 60 regulator-min-microvolt = <110 61 regulator-max-microvolt = <110 62 vin-supply = <&vcc4v0_sys>; 63 }; 64 65 vcc3v3_lcd: regulator-3v3-vcc-lcd { 66 compatible = "regulator-fixed" 67 enable-active-high; 68 gpios = <&gpio4 RK_PA3 GPIO_AC 69 pinctrl-names = "default"; 70 pinctrl-0 = <&lcd_pwren>; 71 regulator-name = "vcc3v3_lcd"; 72 regulator-min-microvolt = <330 73 regulator-max-microvolt = <330 74 vin-supply = <&vcc_3v3_s3>; 75 }; 76 77 vcc3v3_pcie: regulator-3v3-vcc-pcie { 78 compatible = "regulator-fixed" 79 enable-active-high; 80 gpios = <&gpio0 RK_PC6 GPIO_AC 81 pinctrl-names = "default"; 82 pinctrl-0 = <&pcie_pwren>; 83 regulator-name = "vcc3v3_pcie" 84 regulator-min-microvolt = <330 85 regulator-max-microvolt = <330 86 vin-supply = <&vcc_3v3_s3>; 87 }; 88 89 vcc_3v3_s0: regulator-3v3-vcc-s0 { 90 compatible = "regulator-fixed" 91 regulator-name = "vcc_3v3_s0"; 92 regulator-always-on; 93 regulator-boot-on; 94 regulator-min-microvolt = <330 95 regulator-max-microvolt = <330 96 vin-supply = <&vcc_3v3_s3>; 97 }; 98 99 vcc4v0_sys: regulator-4v0-vcc-sys { 100 compatible = "regulator-fixed" 101 regulator-name = "vcc4v0_sys"; 102 regulator-always-on; 103 regulator-boot-on; 104 regulator-min-microvolt = <480 105 regulator-max-microvolt = <480 106 vin-supply = <&vcc12v_dcin>; 107 }; 108 109 vcc5v0_sys: regulator-5v0-vcc-sys { 110 compatible = "regulator-fixed" 111 enable-active-high; 112 gpios = <&gpio0 RK_PD3 GPIO_AC 113 pinctrl-names = "default"; 114 pinctrl-0 = <&vcc5v0_pwren>; 115 regulator-name = "vcc5v0_sys"; 116 regulator-always-on; 117 regulator-boot-on; 118 regulator-min-microvolt = <500 119 regulator-max-microvolt = <500 120 vin-supply = <&vcc12v_dcin>; 121 }; 122 123 vcc5v0_usb2_host: regulator-5v0-vcc-us 124 compatible = "regulator-fixed" 125 enable-active-high; 126 gpios = <&gpio1 RK_PC6 GPIO_AC 127 pinctrl-names = "default"; 128 pinctrl-0 = <&usb2_host_pwren> 129 regulator-name = "vcc5v0_usb2_ 130 regulator-min-microvolt = <500 131 regulator-max-microvolt = <500 132 vin-supply = <&vcc5v0_sys>; 133 }; 134 135 vcc5v0_usb3_host: regulator-5v0-vcc-us 136 compatible = "regulator-fixed" 137 enable-active-high; 138 gpios = <&gpio1 RK_PA6 GPIO_AC 139 pinctrl-names = "default"; 140 pinctrl-0 = <&usb3_host_pwren> 141 regulator-name = "vcc5v0_usb3_ 142 regulator-min-microvolt = <500 143 regulator-max-microvolt = <500 144 vin-supply = <&vcc5v0_sys>; 145 }; 146 147 vcc5v0_usb3_typec: regulator-5v0-vcc-u 148 compatible = "regulator-fixed" 149 enable-active-high; 150 gpios = <&gpio0 RK_PA0 GPIO_AC 151 pinctrl-names = "default"; 152 pinctrl-0 = <&usb3_typec_pwren 153 regulator-name = "vcc5v0_usb3_ 154 regulator-min-microvolt = <500 155 regulator-max-microvolt = <500 156 vin-supply = <&vcc5v0_sys>; 157 }; 158 159 vcca: regulator-5v0-vcca { 160 compatible = "regulator-fixed" 161 regulator-name = "vcca"; 162 regulator-always-on; 163 regulator-boot-on; 164 regulator-min-microvolt = <500 165 regulator-max-microvolt = <500 166 vin-supply = <&vcc12v_dcin>; 167 }; 168 169 vcc12v_dcin: regulator-12v0-vcc-dcin { 170 compatible = "regulator-fixed" 171 regulator-name = "vcc12v_dcin" 172 regulator-always-on; 173 regulator-boot-on; 174 regulator-min-microvolt = <120 175 regulator-max-microvolt = <120 176 }; 177 }; 178 179 &combphy0_ps { 180 status = "okay"; 181 }; 182 183 &combphy2_psu { 184 status = "okay"; 185 }; 186 187 &cpu_b0 { 188 cpu-supply = <&vdd_cpu_big0_s0>; 189 }; 190 191 &cpu_b1 { 192 cpu-supply = <&vdd_cpu_big0_s0>; 193 }; 194 195 &cpu_b2 { 196 cpu-supply = <&vdd_cpu_big1_s0>; 197 }; 198 199 &cpu_b3 { 200 cpu-supply = <&vdd_cpu_big1_s0>; 201 }; 202 203 &cpu_l0 { 204 cpu-supply = <&vdd_cpu_lit_s0>; 205 }; 206 207 &cpu_l1 { 208 cpu-supply = <&vdd_cpu_lit_s0>; 209 }; 210 211 &cpu_l2 { 212 cpu-supply = <&vdd_cpu_lit_s0>; 213 }; 214 215 &cpu_l3 { 216 cpu-supply = <&vdd_cpu_lit_s0>; 217 }; 218 219 &gmac1 { 220 clock_in_out = "output"; 221 phy-handle = <&rgmii_phy1>; 222 phy-mode = "rgmii-id"; 223 phy-supply = <&vcc_3v3_s0>; 224 pinctrl-names = "default"; 225 pinctrl-0 = <&gmac1_miim 226 &gmac1_tx_bus2 227 &gmac1_rx_bus2 228 &gmac1_rgmii_clk 229 &gmac1_rgmii_bus 230 &gmac1_clkinout>; 231 status = "okay"; 232 }; 233 234 &gpu { 235 mali-supply = <&vdd_gpu_s0>; 236 status = "okay"; 237 }; 238 239 &i2c0 { 240 pinctrl-names = "default"; 241 pinctrl-0 = <&i2c0m2_xfer>; 242 status = "okay"; 243 244 vdd_cpu_big0_s0: regulator@42 { 245 compatible = "rockchip,rk8602" 246 reg = <0x42>; 247 fcs,suspend-voltage-selector = 248 regulator-name = "vdd_cpu_big0 249 regulator-always-on; 250 regulator-boot-on; 251 regulator-min-microvolt = <550 252 regulator-max-microvolt = <105 253 regulator-ramp-delay = <2300>; 254 vin-supply = <&vcc4v0_sys>; 255 256 regulator-state-mem { 257 regulator-off-in-suspe 258 }; 259 }; 260 261 vdd_cpu_big1_s0: regulator@43 { 262 compatible = "rockchip,rk8603" 263 reg = <0x43>; 264 fcs,suspend-voltage-selector = 265 regulator-name = "vdd_cpu_big1 266 regulator-always-on; 267 regulator-boot-on; 268 regulator-min-microvolt = <550 269 regulator-max-microvolt = <105 270 regulator-ramp-delay = <2300>; 271 vin-supply = <&vcc4v0_sys>; 272 273 regulator-state-mem { 274 regulator-off-in-suspe 275 }; 276 }; 277 }; 278 279 &i2c2 { 280 status = "okay"; 281 282 vdd_npu_s0: regulator@42 { 283 compatible = "rockchip,rk8602" 284 reg = <0x42>; 285 fcs,suspend-voltage-selector = 286 regulator-name = "vdd_npu_s0"; 287 regulator-always-on; 288 regulator-boot-on; 289 regulator-min-microvolt = <550 290 regulator-max-microvolt = <950 291 regulator-ramp-delay = <2300>; 292 vin-supply = <&vcc4v0_sys>; 293 294 regulator-state-mem { 295 regulator-off-in-suspe 296 }; 297 }; 298 }; 299 300 &i2c8 { 301 clock-frequency = <400000>; 302 pinctrl-names = "default"; 303 pinctrl-0 = <&i2c8m2_xfer>; 304 status = "okay"; 305 306 usbc0: usb-typec@22 { 307 compatible = "fcs,fusb302"; 308 reg = <0x22>; 309 interrupt-parent = <&gpio4>; 310 interrupts = <RK_PA5 IRQ_TYPE_ 311 pinctrl-names = "default"; 312 pinctrl-0 = <&usbc0_int>; 313 vbus-supply = <&vcc5v0_usb3_ty 314 315 connector { 316 compatible = "usb-c-co 317 data-role = "dual"; 318 label = "USB-C"; 319 op-sink-microwatt = <1 320 power-role = "dual"; 321 sink-pdos = <PDO_FIXED 322 source-pdos = <PDO_FIX 323 try-power-role = "sour 324 325 ports { 326 #address-cells 327 #size-cells = 328 329 port@0 { 330 reg = 331 332 usbc0_ 333 334 }; 335 }; 336 337 port@1 { 338 reg = 339 340 usbc0_ 341 342 }; 343 }; 344 345 port@2 { 346 reg = 347 348 usbc0_ 349 350 }; 351 }; 352 }; 353 }; 354 }; 355 356 pcf8563: rtc@51 { 357 compatible = "nxp,pcf8563"; 358 reg = <0x51>; 359 interrupt-parent = <&gpio0>; 360 interrupts = <RK_PB0 IRQ_TYPE_ 361 pinctrl-names = "default"; 362 pinctrl-0 = <&pcf8563_int>; 363 wakeup-source; 364 }; 365 }; 366 367 &mdio1 { 368 rgmii_phy1: ethernet-phy@1 { 369 compatible = "ethernet-phy-id0 370 reg = <1>; 371 reset-assert-us = <20000>; 372 reset-deassert-us = <100000>; 373 reset-gpios = <&gpio3 RK_PB7 G 374 }; 375 }; 376 377 &package_thermal { 378 polling-delay = <1000>; 379 380 trips { 381 package_fan0: package-fan0 { 382 hysteresis = <2000>; 383 temperature = <60000>; 384 type = "active"; 385 }; 386 }; 387 388 cooling-maps { 389 map0 { 390 cooling-device = <&fan 391 trip = <&package_fan0> 392 }; 393 }; 394 }; 395 396 &pcie2x1l2 { 397 pinctrl-names = "default"; 398 pinctrl-0 = <&pcie20x1_pins>; 399 reset-gpios = <&gpio1 RK_PA7 GPIO_ACTI 400 vpcie3v3-supply = <&vcc3v3_pcie>; 401 status = "okay"; 402 }; 403 404 &pinctrl { 405 lcd { 406 lcd_pwren: lcd-pwren { 407 rockchip,pins = <4 RK_ 408 }; 409 }; 410 411 leds { 412 pwr_led: pwr-led { 413 rockchip,pins = <1 RK_ 414 }; 415 416 sys_led: sys-led { 417 rockchip,pins = <1 RK_ 418 }; 419 }; 420 421 pcie { 422 pcie20x1_pins: pcie20x1-pins { 423 rockchip,pins = 424 <1 RK_PA0 4 &p 425 <1 RK_PA7 RK_F 426 <1 RK_PA1 4 &p 427 }; 428 429 pcie_pwren: pcie-pwren { 430 rockchip,pins = <0 RK_ 431 }; 432 }; 433 434 regulator { 435 vcc5v0_pwren: vcc5v0-pwren { 436 rockchip,pins = <0 RK_ 437 }; 438 }; 439 440 rtc { 441 pcf8563_int: pcf8563-int { 442 rockchip,pins = <0 RK_ 443 }; 444 }; 445 446 usb { 447 usb2_host_pwren: usb2-host-pwr 448 rockchip,pins = <1 RK_ 449 }; 450 451 usb3_host_pwren: usb3-host-pwr 452 rockchip,pins = <1 RK_ 453 }; 454 455 usb3_typec_pwren: usb3-typec-p 456 rockchip,pins = <0 RK_ 457 }; 458 459 usbc0_int: usbc0-int { 460 rockchip,pins = <4 RK_ 461 }; 462 }; 463 }; 464 465 &pwm0 { 466 pinctrl-names = "default"; 467 pinctrl-0 = <&pwm0m2_pins>; 468 status = "okay"; 469 }; 470 471 &saradc { 472 vref-supply = <&vcca_1v8_s0>; 473 status = "okay"; 474 }; 475 476 &sdhci { 477 bus-width = <8>; 478 mmc-hs400-1_8v; 479 mmc-hs400-enhanced-strobe; 480 no-sd; 481 no-sdio; 482 non-removable; 483 vmmc-supply = <&vcc_3v3_s0>; 484 vqmmc-supply = <&vcc_1v8_s0>; 485 status = "okay"; 486 }; 487 488 &sdmmc { 489 bus-width = <4>; 490 cap-sd-highspeed; 491 cd-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_ 492 disable-wp; 493 max-frequency = <150000000>; 494 no-mmc; 495 no-sdio; 496 sd-uhs-sdr104; 497 vmmc-supply = <&vcc_3v3_s3>; 498 vqmmc-supply = <&vccio_sd_s0>; 499 status = "okay"; 500 }; 501 502 &spi2 { 503 assigned-clocks = <&cru CLK_SPI2>; 504 assigned-clock-rates = <200000000>; 505 num-cs = <1>; 506 pinctrl-names = "default"; 507 pinctrl-0 = <&spi2m2_cs0>, <&spi2m2_pi 508 status = "okay"; 509 510 pmic@0 { 511 compatible = "rockchip,rk806"; 512 reg = <0x0>; 513 #gpio-cells = <2>; 514 gpio-controller; 515 interrupt-parent = <&gpio0>; 516 interrupts = <RK_PA7 IRQ_TYPE_ 517 pinctrl-names = "default"; 518 pinctrl-0 = <&pmic_pins>, <&rk 519 <&rk806_dvs2_null> 520 spi-max-frequency = <1000000>; 521 system-power-controller; 522 523 vcc1-supply = <&vcc4v0_sys>; 524 vcc2-supply = <&vcc4v0_sys>; 525 vcc3-supply = <&vcc4v0_sys>; 526 vcc4-supply = <&vcc4v0_sys>; 527 vcc5-supply = <&vcc4v0_sys>; 528 vcc6-supply = <&vcc4v0_sys>; 529 vcc7-supply = <&vcc4v0_sys>; 530 vcc8-supply = <&vcc4v0_sys>; 531 vcc9-supply = <&vcc4v0_sys>; 532 vcc10-supply = <&vcc4v0_sys>; 533 vcc11-supply = <&vcc_2v0_pldo_ 534 vcc12-supply = <&vcc4v0_sys>; 535 vcc13-supply = <&vcc_1v1_nldo_ 536 vcc14-supply = <&vcc_1v1_nldo_ 537 vcca-supply = <&vcca>; 538 539 rk806_dvs1_null: dvs1-null-pin 540 pins = "gpio_pwrctrl1" 541 function = "pin_fun0"; 542 }; 543 544 rk806_dvs2_null: dvs2-null-pin 545 pins = "gpio_pwrctrl2" 546 function = "pin_fun0"; 547 }; 548 549 rk806_dvs3_null: dvs3-null-pin 550 pins = "gpio_pwrctrl3" 551 function = "pin_fun0"; 552 }; 553 554 regulators { 555 vdd_gpu_s0: dcdc-reg1 556 regulator-name 557 regulator-boot 558 regulator-min- 559 regulator-max- 560 regulator-ramp 561 regulator-enab 562 563 regulator-stat 564 regula 565 }; 566 }; 567 568 vdd_cpu_lit_s0: dcdc-r 569 regulator-name 570 regulator-alwa 571 regulator-boot 572 regulator-min- 573 regulator-max- 574 regulator-ramp 575 576 regulator-stat 577 regula 578 }; 579 }; 580 581 vdd_logic_s0: dcdc-reg 582 regulator-name 583 regulator-alwa 584 regulator-boot 585 regulator-min- 586 regulator-max- 587 regulator-ramp 588 589 regulator-stat 590 regula 591 regula 592 }; 593 }; 594 595 vdd_vdenc_s0: dcdc-reg 596 regulator-name 597 regulator-alwa 598 regulator-boot 599 regulator-min- 600 regulator-max- 601 regulator-ramp 602 603 regulator-stat 604 regula 605 }; 606 }; 607 608 vdd_ddr_s0: dcdc-reg5 609 regulator-name 610 regulator-alwa 611 regulator-boot 612 regulator-min- 613 regulator-max- 614 regulator-ramp 615 616 regulator-stat 617 regula 618 regula 619 }; 620 }; 621 622 vdd2_ddr_s3: dcdc-reg6 623 regulator-name 624 regulator-alwa 625 regulator-boot 626 627 regulator-stat 628 regula 629 }; 630 }; 631 632 vcc_2v0_pldo_s3: dcdc- 633 regulator-name 634 regulator-alwa 635 regulator-boot 636 regulator-min- 637 regulator-max- 638 regulator-ramp 639 640 regulator-stat 641 regula 642 regula 643 }; 644 }; 645 646 vcc_3v3_s3: dcdc-reg8 647 regulator-name 648 regulator-alwa 649 regulator-boot 650 regulator-min- 651 regulator-max- 652 653 regulator-stat 654 regula 655 regula 656 }; 657 }; 658 659 vddq_ddr_s0: dcdc-reg9 660 regulator-name 661 regulator-alwa 662 regulator-boot 663 664 regulator-stat 665 regula 666 }; 667 }; 668 669 vcc_1v8_s3: dcdc-reg10 670 regulator-name 671 regulator-alwa 672 regulator-boot 673 regulator-min- 674 regulator-max- 675 676 regulator-stat 677 regula 678 regula 679 }; 680 }; 681 682 vcc_1v8_s0: pldo-reg1 683 regulator-name 684 regulator-alwa 685 regulator-boot 686 regulator-min- 687 regulator-max- 688 689 regulator-stat 690 regula 691 }; 692 }; 693 694 vcca_1v8_s0: pldo-reg2 695 regulator-name 696 regulator-alwa 697 regulator-boot 698 regulator-min- 699 regulator-max- 700 701 regulator-stat 702 regula 703 regula 704 }; 705 }; 706 707 vdda_1v2_s0: pldo-reg3 708 regulator-name 709 regulator-alwa 710 regulator-boot 711 regulator-min- 712 regulator-max- 713 714 regulator-stat 715 regula 716 }; 717 }; 718 719 vcca_3v3_s0: pldo-reg4 720 regulator-name 721 regulator-alwa 722 regulator-boot 723 regulator-min- 724 regulator-max- 725 regulator-ramp 726 727 regulator-stat 728 regula 729 }; 730 }; 731 732 vccio_sd_s0: pldo-reg5 733 regulator-name 734 regulator-alwa 735 regulator-boot 736 regulator-min- 737 regulator-max- 738 regulator-ramp 739 740 regulator-stat 741 regula 742 }; 743 }; 744 745 vcc_1v8_s3_pldo6: pldo 746 regulator-name 747 regulator-alwa 748 regulator-boot 749 regulator-min- 750 regulator-max- 751 752 regulator-stat 753 regula 754 regula 755 }; 756 }; 757 758 vdd_0v75_s3: nldo-reg1 759 regulator-name 760 regulator-alwa 761 regulator-boot 762 regulator-min- 763 regulator-max- 764 765 regulator-stat 766 regula 767 regula 768 }; 769 }; 770 771 vdda_ddr_pll_s0: nldo- 772 regulator-name 773 regulator-alwa 774 regulator-boot 775 regulator-min- 776 regulator-max- 777 778 regulator-stat 779 regula 780 regula 781 }; 782 }; 783 784 vdda_0v75_s0: nldo-reg 785 regulator-name 786 regulator-alwa 787 regulator-boot 788 regulator-min- 789 regulator-max- 790 791 regulator-stat 792 regula 793 }; 794 }; 795 796 vdda_0v85_s0: nldo-reg 797 regulator-name 798 regulator-alwa 799 regulator-boot 800 regulator-min- 801 regulator-max- 802 803 regulator-stat 804 regula 805 }; 806 }; 807 808 /* Schematics show not 809 nldo-reg5 { 810 }; 811 }; 812 }; 813 }; 814 815 &tsadc { 816 status = "okay"; 817 }; 818 819 &u2phy0 { 820 status = "okay"; 821 }; 822 823 &u2phy0_otg { 824 status = "okay"; 825 }; 826 827 &u2phy2 { 828 status = "okay"; 829 }; 830 831 &u2phy2_host { 832 phy-supply = <&vcc5v0_usb2_host>; 833 status = "okay"; 834 }; 835 836 &u2phy3 { 837 status = "okay"; 838 }; 839 840 &u2phy3_host { 841 phy-supply = <&vcc5v0_usb3_host>; 842 status = "okay"; 843 }; 844 845 &uart2 { 846 pinctrl-names = "default"; 847 pinctrl-0 = <&uart2m0_xfer>; 848 status = "okay"; 849 }; 850 851 &usb_host0_ehci { 852 status = "okay"; 853 }; 854 855 &usb_host0_ohci { 856 status = "okay"; 857 }; 858 859 &usb_host0_xhci { 860 usb-role-switch; 861 status = "okay"; 862 863 port { 864 usb_host0_xhci_role_switch: en 865 remote-endpoint = <&us 866 }; 867 }; 868 }; 869 870 &usb_host1_ehci { 871 status = "okay"; 872 }; 873 874 &usb_host1_ohci { 875 status = "okay"; 876 }; 877 878 &usb_host2_xhci { 879 status = "okay"; 880 }; 881 882 &usbdp_phy0 { 883 mode-switch; 884 orientation-switch; 885 sbu1-dc-gpios = <&gpio4 RK_PA0 GPIO_AC 886 sbu2-dc-gpios = <&gpio4 RK_PA1 GPIO_AC 887 status = "okay"; 888 889 port { 890 #address-cells = <1>; 891 #size-cells = <0>; 892 893 usbdp_phy0_orientation_switch: 894 reg = <0>; 895 remote-endpoint = <&us 896 }; 897 898 usbdp_phy0_dp_altmode_mux: end 899 reg = <1>; 900 remote-endpoint = <&us 901 }; 902 }; 903 };
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.