1// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2/* 3 * Google Trogdor device tree source (common between revisions) 4 * 5 * Copyright 2019 Google LLC. 6 */ 7 8#include <dt-bindings/gpio/gpio.h> 9#include <dt-bindings/input/gpio-keys.h> 10#include <dt-bindings/input/input.h> 11#include <dt-bindings/regulator/qcom,rpmh-regulator.h> 12#include <dt-bindings/sound/sc7180-lpass.h> 13 14/* PMICs depend on spmi_bus label and so must come after SoC */ 15#include "pm6150.dtsi" 16#include "pm6150l.dtsi" 17 18/ { 19 thermal-zones { 20 charger_thermal: charger-thermal { 21 polling-delay-passive = <0>; 22 polling-delay = <0>; 23 24 thermal-sensors = <&pm6150_adc_tm 0>; 25 26 trips { 27 charger-crit { 28 temperature = <125000>; 29 hysteresis = <1000>; 30 type = "critical"; 31 }; 32 }; 33 }; 34 }; 35}; 36 37/* 38 * Reserved memory changes 39 * 40 * Delete all unused memory nodes and define the peripheral memory regions 41 * required by the board dts. 42 */ 43 44/delete-node/ &hyp_mem; 45/delete-node/ &xbl_mem; 46/delete-node/ &aop_mem; 47/delete-node/ &sec_apps_mem; 48/delete-node/ &tz_mem; 49 50/* Increase the size from 2MB to 8MB */ 51&rmtfs_mem { 52 reg = <0x0 0x94600000 0x0 0x800000>; 53}; 54 55/ { 56 reserved-memory { 57 atf_mem: memory@80b00000 { 58 reg = <0x0 0x80b00000 0x0 0x100000>; 59 no-map; 60 }; 61 62 mpss_mem: memory@86000000 { 63 reg = <0x0 0x86000000 0x0 0x2000000>; 64 no-map; 65 }; 66 67 venus_mem: memory@8f600000 { 68 reg = <0 0x8f600000 0 0x500000>; 69 no-map; 70 }; 71 72 wlan_mem: memory@94100000 { 73 reg = <0x0 0x94100000 0x0 0x200000>; 74 no-map; 75 }; 76 77 mba_mem: memory@94400000 { 78 reg = <0x0 0x94400000 0x0 0x200000>; 79 no-map; 80 }; 81 }; 82 83 aliases { 84 bluetooth0 = &bluetooth; 85 hsuart0 = &uart3; 86 serial0 = &uart8; 87 wifi0 = &wifi; 88 }; 89 90 chosen { 91 stdout-path = "serial0:115200n8"; 92 }; 93 94 /* FIXED REGULATORS - parents above children */ 95 96 /* This is the top level supply and variable voltage */ 97 ppvar_sys: ppvar-sys-regulator { 98 compatible = "regulator-fixed"; 99 regulator-name = "ppvar_sys"; 100 regulator-always-on; 101 regulator-boot-on; 102 }; 103 104 /* This divides ppvar_sys by 2, so voltage is variable */ 105 src_vph_pwr: src-vph-pwr-regulator { 106 compatible = "regulator-fixed"; 107 regulator-name = "src_vph_pwr"; 108 109 /* EC turns on with switchcap_on; always on for AP */ 110 regulator-always-on; 111 regulator-boot-on; 112 113 vin-supply = <&ppvar_sys>; 114 }; 115 116 pp5000_a: pp5000-a-regulator { 117 compatible = "regulator-fixed"; 118 regulator-name = "pp5000_a"; 119 120 /* EC turns on with en_pp5000_a; always on for AP */ 121 regulator-always-on; 122 regulator-boot-on; 123 regulator-min-microvolt = <5000000>; 124 regulator-max-microvolt = <5000000>; 125 126 vin-supply = <&ppvar_sys>; 127 }; 128 129 pp3300_a: pp3300-a-regulator { 130 compatible = "regulator-fixed"; 131 regulator-name = "pp3300_a"; 132 133 /* EC turns on with en_pp3300_a; always on for AP */ 134 regulator-always-on; 135 regulator-boot-on; 136 regulator-min-microvolt = <3300000>; 137 regulator-max-microvolt = <3300000>; 138 139 /* 140 * Actually should be pp3300 but that's practically an alias for 141 * pp3300_a so we use pp3300's vin-supply here to avoid one more 142 * node. 143 */ 144 vin-supply = <&ppvar_sys>; 145 }; 146 147 pp3300_audio: 148 pp3300_codec: pp3300-codec-regulator { 149 compatible = "regulator-fixed"; 150 regulator-name = "pp3300_codec"; 151 152 regulator-min-microvolt = <3300000>; 153 regulator-max-microvolt = <3300000>; 154 155 gpio = <&tlmm 83 GPIO_ACTIVE_HIGH>; 156 enable-active-high; 157 pinctrl-names = "default"; 158 pinctrl-0 = <&en_pp3300_codec>; 159 160 vin-supply = <&pp3300_a>; 161 }; 162 163 pp3300_dx_edp: 164 pp3300_ts: pp3300-dx-edp-regulator { 165 compatible = "regulator-fixed"; 166 regulator-name = "pp3300_dx_edp"; 167 168 regulator-min-microvolt = <3300000>; 169 regulator-max-microvolt = <3300000>; 170 171 gpio = <&tlmm 30 GPIO_ACTIVE_HIGH>; 172 enable-active-high; 173 pinctrl-names = "default"; 174 pinctrl-0 = <&en_pp3300_dx_edp>; 175 176 vin-supply = <&pp3300_a>; 177 }; 178 179 pp3300_fp_tp: pp3300-fp-tp-regulator { 180 compatible = "regulator-fixed"; 181 regulator-name = "pp3300_fp_tp"; 182 183 regulator-min-microvolt = <3300000>; 184 regulator-max-microvolt = <3300000>; 185 186 /* AP turns on with PP1800_VIO_OUT; always on for AP */ 187 regulator-always-on; 188 regulator-boot-on; 189 190 vin-supply = <&pp3300_a>; 191 }; 192 193 pp3300_hub: pp3300-hub { 194 compatible = "regulator-fixed"; 195 regulator-name = "pp3300_hub"; 196 197 regulator-min-microvolt = <3300000>; 198 regulator-max-microvolt = <3300000>; 199 200 gpio = <&tlmm 84 GPIO_ACTIVE_HIGH>; 201 enable-active-high; 202 pinctrl-names = "default"; 203 pinctrl-0 = <&en_pp3300_hub>; 204 205 regulator-always-on; 206 regulator-boot-on; 207 208 vin-supply = <&pp3300_a>; 209 }; 210 211 /* BOARD-SPECIFIC TOP LEVEL NODES */ 212 213 backlight: backlight { 214 compatible = "pwm-backlight"; 215 216 /* The panels don't seem to like anything below ~ 5% */ 217 brightness-levels = < 218 196 256 324 400 484 576 676 784 900 1024 1156 1296 219 1444 1600 1764 1936 2116 2304 2500 2704 2916 3136 220 3364 3600 3844 4096 221 >; 222 num-interpolated-steps = <64>; 223 default-brightness-level = <951>; 224 225 pwms = <&cros_ec_pwm 1>; 226 enable-gpios = <&tlmm 12 GPIO_ACTIVE_HIGH>; 227 power-supply = <&ppvar_sys>; 228 pinctrl-names = "default"; 229 pinctrl-0 = <&ap_edp_bklten>; 230 }; 231 232 gpio_keys: gpio-keys { 233 compatible = "gpio-keys"; 234 status = "disabled"; 235 pinctrl-names = "default"; 236 pinctrl-0 = <&pen_pdct_l>; 237 238 pen_insert: pen-insert { 239 label = "Pen Insert"; 240 241 /* Insert = low, eject = high */ 242 gpios = <&tlmm 52 GPIO_ACTIVE_LOW>; 243 linux,code = <SW_PEN_INSERTED>; 244 linux,input-type = <EV_SW>; 245 wakeup-event-action = <EV_ACT_DEASSERTED>; 246 wakeup-source; 247 }; 248 }; 249 250 max98360a: audio-codec-0 { 251 compatible = "maxim,max98360a"; 252 pinctrl-names = "default"; 253 pinctrl-0 = <&_en>; 254 sdmode-gpios = <&tlmm 23 GPIO_ACTIVE_HIGH>; 255 #sound-dai-cells = <0>; 256 }; 257 258 pwmleds { 259 compatible = "pwm-leds"; 260 keyboard_backlight: keyboard-backlight { 261 status = "disabled"; 262 label = "cros_ec::kbd_backlight"; 263 pwms = <&cros_ec_pwm 0>; 264 max-brightness = <1023>; 265 }; 266 }; 267 268 sound: sound { 269 compatible = "google,sc7180-trogdor"; 270 model = "sc7180-rt5682-max98357a-1mic"; 271 272 audio-routing = 273 "Headphone Jack", "HPOL", 274 "Headphone Jack", "HPOR"; 275 276 #address-cells = <1>; 277 #size-cells = <0>; 278 279 dai-link@0 { 280 link-name = "MultiMedia0"; 281 reg = <MI2S_PRIMARY>; 282 cpu { 283 sound-dai = <&lpass_cpu MI2S_PRIMARY>; 284 }; 285 286 sound_multimedia0_codec: codec { 287 sound-dai = <&alc5682 0 /* aif1 */>; 288 }; 289 }; 290 291 dai-link@1 { 292 link-name = "MultiMedia1"; 293 reg = <MI2S_SECONDARY>; 294 cpu { 295 sound-dai = <&lpass_cpu MI2S_SECONDARY>; 296 }; 297 298 sound_multimedia1_codec: codec { 299 sound-dai = <&max98360a>; 300 }; 301 }; 302 303 dai-link@5 { 304 link-name = "MultiMedia2"; 305 reg = <LPASS_DP_RX>; 306 cpu { 307 sound-dai = <&lpass_cpu LPASS_DP_RX>; 308 }; 309 310 codec { 311 sound-dai = <&mdss_dp>; 312 }; 313 }; 314 }; 315}; 316 317&qfprom { 318 vcc-supply = <&pp1800_l11a>; 319}; 320 321&qspi { 322 status = "okay"; 323 pinctrl-names = "default"; 324 pinctrl-0 = <&qspi_clk>, <&qspi_cs0>, <&qspi_data01>; 325 326 flash@0 { 327 compatible = "jedec,spi-nor"; 328 reg = <0>; 329 330 spi-max-frequency = <37500000>; 331 spi-tx-bus-width = <2>; 332 spi-rx-bus-width = <2>; 333 }; 334}; 335 336&apps_rsc { 337 pm6150-rpmh-regulators { 338 compatible = "qcom,pm6150-rpmh-regulators"; 339 qcom,pmic-id = "a"; 340 341 vddpx_1: 342 vdd2: 343 pp1125_s1a: smps1 { 344 regulator-min-microvolt = <1128000>; 345 regulator-max-microvolt = <1128000>; 346 }; 347 348 vdd_qlink_lv: 349 vdd_qlink_lv_ck: 350 vdd_qusb_hs0_core: 351 vdd_ufs1_core: 352 vdda_mipi_csi0_0p9: 353 vdda_mipi_csi1_0p9: 354 vdda_mipi_csi2_0p9: 355 vdda_mipi_csi3_0p9: 356 vdda_mipi_dsi0_pll: 357 vdda_pll_cc_ebi01: 358 vdda_qrefs_0p9: 359 vdda_usb_ss_dp_core: 360 pp900_l4a: ldo4 { 361 regulator-min-microvolt = <824000>; 362 regulator-max-microvolt = <928000>; 363 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 364 }; 365 366 vdd_cx_wlan: 367 pp800_l9a: ldo9 { 368 regulator-min-microvolt = <488000>; 369 regulator-max-microvolt = <800000>; 370 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 371 }; 372 373 vdd1: 374 vddpx_3: 375 vddpx_7: 376 vio_in: 377 pp1800_l10a: ldo10 { 378 regulator-min-microvolt = <1800000>; 379 regulator-max-microvolt = <1800000>; 380 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 381 }; 382 383 vdd_qfprom: 384 vdda_apc1_cs_1p8: 385 vdda_qrefs_1p8: 386 vdda_qusb_hs0_1p8: 387 vddpx_11: 388 vreg_bb_clk: 389 pp1800_l11a: ldo11 { 390 regulator-min-microvolt = <1800000>; 391 regulator-max-microvolt = <1800000>; 392 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 393 }; 394 395 mcp_vccq: 396 pp1800_l12a_r: ldo12 { 397 regulator-min-microvolt = <1800000>; 398 regulator-max-microvolt = <1800000>; 399 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 400 }; 401 402 /* 403 * On trogdor this needs to match l10a since we use it to 404 * give power to things like SPI flash which communicate back 405 * on lines powered by l10a. Thus we force to 1.8V. 406 */ 407 pp1800_l13a: ldo13 { 408 regulator-min-microvolt = <1800000>; 409 regulator-max-microvolt = <1800000>; 410 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 411 }; 412 413 pp1800_prox: 414 pp1800_l14a: ldo14 { 415 regulator-min-microvolt = <1800000>; 416 regulator-max-microvolt = <1800000>; 417 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 418 }; 419 420 pp1800_alc5682: 421 pp1800_l15a: ldo15 { 422 regulator-min-microvolt = <1800000>; 423 regulator-max-microvolt = <1800000>; 424 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 425 }; 426 427 vdda_qusb_hs0_3p1: 428 vdd_pdphy: 429 pp3100_l17a: ldo17 { 430 regulator-min-microvolt = <2920000>; 431 regulator-max-microvolt = <3232000>; 432 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 433 }; 434 435 pp1800_pen: 436 pp1800_l18a: ldo18 { 437 regulator-min-microvolt = <1800000>; 438 regulator-max-microvolt = <1800000>; 439 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 440 }; 441 442 mcp_vcc: 443 pp2850_l19a: ldo19 { 444 regulator-min-microvolt = <2960000>; 445 regulator-max-microvolt = <2960000>; 446 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 447 }; 448 }; 449 450 pm6150l-rpmh-regulators { 451 compatible = "qcom,pm6150l-rpmh-regulators"; 452 qcom,pmic-id = "c"; 453 454 pp1300_s8c: smps8 { 455 regulator-min-microvolt = <1120000>; 456 regulator-max-microvolt = <1408000>; 457 }; 458 459 pp1800_l1c: ldo1 { 460 regulator-min-microvolt = <1616000>; 461 regulator-max-microvolt = <1984000>; 462 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 463 }; 464 465 vdd_wcss_adc_dac: 466 pp1300_l2c: ldo2 { 467 regulator-min-microvolt = <1168000>; 468 regulator-max-microvolt = <1304000>; 469 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 470 }; 471 472 pp1200_brij: 473 vdd_ufs1_1p2: 474 vdda_csi0_1p25: 475 vdda_csi1_1p25: 476 vdda_csi2_1p25: 477 vdda_csi3_1p25: 478 vdda_hv_ebi0: 479 vdda_mipi_dsi0_1p2: 480 vdda_usb_ss_dp_1p2: 481 vddpx_10: 482 pp1200_l3c: ldo3 { 483 regulator-min-microvolt = <1200000>; 484 regulator-max-microvolt = <1200000>; 485 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 486 }; 487 488 vddpx_2: 489 ppvar_l6c: ldo6 { 490 regulator-min-microvolt = <1800000>; 491 regulator-max-microvolt = <2952000>; 492 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 493 }; 494 495 pp3300_l7c: ldo7 { 496 regulator-min-microvolt = <3304000>; 497 regulator-max-microvolt = <3304000>; 498 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 499 }; 500 501 pp1800_brij_vccio: 502 pp1800_edp_vpll: 503 pp1800_l8c: ldo8 { 504 regulator-min-microvolt = <1800000>; 505 regulator-max-microvolt = <1800000>; 506 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 507 }; 508 509 pp2950_l9c: ldo9 { 510 regulator-min-microvolt = <2952000>; 511 regulator-max-microvolt = <2952000>; 512 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 513 }; 514 515 pp3300_l10c: ldo10 { 516 regulator-min-microvolt = <3000000>; 517 regulator-max-microvolt = <3400000>; 518 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 519 }; 520 521 pp3300_l11c: ldo11 { 522 regulator-min-microvolt = <3000000>; 523 regulator-max-microvolt = <3400000>; 524 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; 525 }; 526 527 src_vreg_bob: bob { 528 regulator-min-microvolt = <3008000>; 529 regulator-max-microvolt = <3960000>; 530 regulator-initial-mode = <RPMH_REGULATOR_MODE_AUTO>; 531 }; 532 }; 533}; 534 535&ap_ec_spi { 536 status = "okay"; 537 cros_ec: ec@0 { 538 compatible = "google,cros-ec-spi"; 539 reg = <0>; 540 interrupt-parent = <&tlmm>; 541 interrupts = <94 IRQ_TYPE_LEVEL_LOW>; 542 pinctrl-names = "default"; 543 pinctrl-0 = <&ap_ec_int_l>; 544 spi-max-frequency = <3000000>; 545 546 cros_ec_pwm: ec-pwm { 547 compatible = "google,cros-ec-pwm"; 548 #pwm-cells = <1>; 549 }; 550 551 i2c_tunnel: i2c-tunnel { 552 compatible = "google,cros-ec-i2c-tunnel"; 553 google,remote-bus = <0>; 554 #address-cells = <1>; 555 #size-cells = <0>; 556 }; 557 558 typec { 559 compatible = "google,cros-ec-typec"; 560 #address-cells = <1>; 561 #size-cells = <0>; 562 563 usb_c0: connector@0 { 564 compatible = "usb-c-connector"; 565 reg = <0>; 566 label = "left"; 567 power-role = "dual"; 568 data-role = "host"; 569 try-power-role = "source"; 570 }; 571 572 usb_c1: connector@1 { 573 compatible = "usb-c-connector"; 574 reg = <1>; 575 label = "right"; 576 power-role = "dual"; 577 data-role = "host"; 578 try-power-role = "source"; 579 }; 580 }; 581 }; 582}; 583 584&ap_h1_spi { 585 status = "okay"; 586 cr50: tpm@0 { 587 compatible = "google,cr50"; 588 reg = <0>; 589 pinctrl-names = "default"; 590 pinctrl-0 = <&h1_ap_int_odl>; 591 spi-max-frequency = <800000>; 592 interrupt-parent = <&tlmm>; 593 interrupts = <42 IRQ_TYPE_EDGE_RISING>; 594 }; 595}; 596 597&camcc { 598 status = "disabled"; 599}; 600 601&dsi0 { 602 status = "okay"; 603 vdda-supply = <&vdda_mipi_dsi0_1p2>; 604 605 ports { 606 port@1 { 607 endpoint { 608 remote-endpoint = <&sn65dsi86_in>; 609 data-lanes = <0 1 2 3>; 610 }; 611 }; 612 }; 613}; 614 615&dsi_phy { 616 status = "okay"; 617 vdds-supply = <&vdda_mipi_dsi0_pll>; 618}; 619 620edp_brij_i2c: &i2c2 { 621 status = "okay"; 622 clock-frequency = <400000>; 623 624 sn65dsi86_bridge: bridge@2d { 625 compatible = "ti,sn65dsi86"; 626 reg = <0x2d>; 627 pinctrl-names = "default"; 628 pinctrl-0 = <&edp_brij_en>, <&edp_brij_irq>; 629 gpio-controller; 630 #gpio-cells = <2>; 631 632 interrupt-parent = <&tlmm>; 633 interrupts = <11 IRQ_TYPE_LEVEL_HIGH>; 634 635 enable-gpios = <&tlmm 104 GPIO_ACTIVE_HIGH>; 636 637 vpll-supply = <&pp1800_edp_vpll>; 638 vccio-supply = <&pp1800_brij_vccio>; 639 vcca-supply = <&pp1200_brij>; 640 vcc-supply = <&pp1200_brij>; 641 642 clocks = <&rpmhcc RPMH_LN_BB_CLK3>; 643 clock-names = "refclk"; 644 645 no-hpd; 646 647 ports { 648 #address-cells = <1>; 649 #size-cells = <0>; 650 651 port@0 { 652 reg = <0>; 653 sn65dsi86_in: endpoint { 654 remote-endpoint = <&dsi0_out>; 655 }; 656 }; 657 658 port@1 { 659 reg = <1>; 660 sn65dsi86_out: endpoint { 661 data-lanes = <0 1>; 662 remote-endpoint = <&panel_in_edp>; 663 }; 664 }; 665 }; 666 667 aux-bus { 668 panel: panel { 669 /* Compatible will be filled in per-board */ 670 power-supply = <&pp3300_dx_edp>; 671 backlight = <&backlight>; 672 hpd-gpios = <&sn65dsi86_bridge 2 GPIO_ACTIVE_HIGH>; 673 674 port { 675 panel_in_edp: endpoint { 676 remote-endpoint = <&sn65dsi86_out>; 677 }; 678 }; 679 }; 680 }; 681 }; 682}; 683 684ap_sar_sensor_i2c: &i2c5 { 685 clock-frequency = <400000>; 686 687 ap_sar_sensor: proximity@28 { 688 compatible = "semtech,sx9310"; 689 reg = <0x28>; 690 #io-channel-cells = <1>; 691 pinctrl-names = "default"; 692 pinctrl-0 = <&p_sensor_int_l>; 693 694 interrupt-parent = <&tlmm>; 695 interrupts = <24 IRQ_TYPE_LEVEL_LOW>; 696 697 vdd-supply = <&pp3300_a>; 698 svdd-supply = <&pp1800_prox>; 699 700 status = "disabled"; 701 label = "proximity-wifi"; 702 }; 703}; 704 705ap_tp_i2c: &i2c7 { 706 status = "okay"; 707 clock-frequency = <400000>; 708 709 trackpad: trackpad@15 { 710 compatible = "elan,ekth3000"; 711 reg = <0x15>; 712 pinctrl-names = "default"; 713 pinctrl-0 = <&tp_int_odl>; 714 715 interrupt-parent = <&tlmm>; 716 interrupts = <0 IRQ_TYPE_EDGE_FALLING>; 717 718 vcc-supply = <&pp3300_fp_tp>; 719 720 wakeup-source; 721 }; 722}; 723 724hp_i2c: &i2c9 { 725 status = "okay"; 726 clock-frequency = <400000>; 727 728 alc5682: codec@1a { 729 compatible = "realtek,rt5682i"; 730 reg = <0x1a>; 731 pinctrl-names = "default"; 732 pinctrl-0 = <&hp_irq>; 733 734 #sound-dai-cells = <1>; 735 736 interrupt-parent = <&tlmm>; 737 /* 738 * This will get ignored because the interrupt type 739 * is set in rt5682.c. 740 */ 741 interrupts = <28 IRQ_TYPE_EDGE_BOTH>; 742 743 AVDD-supply = <&pp1800_alc5682>; 744 MICVDD-supply = <&pp3300_codec>; 745 VBAT-supply = <&pp3300_audio>; 746 747 realtek,dmic1-data-pin = <1>; 748 realtek,dmic1-clk-pin = <1>; 749 realtek,jd-src = <1>; 750 }; 751}; 752 753&ipa { 754 status = "okay"; 755 756 /* 757 * Trogdor doesn't have QHEE (Qualcomm's EL2 blob), so the 758 * modem needs to cover certain init steps (GSI init), and 759 * the AP needs to wait for it. 760 */ 761 modem-init; 762}; 763 764&lpass_cpu { 765 status = "okay"; 766 767 pinctrl-names = "default"; 768 pinctrl-0 = <&sec_mi2s_active>, <&pri_mi2s_active>, <&pri_mi2s_mclk_active>; 769 770 #address-cells = <1>; 771 #size-cells = <0>; 772 773 mi2s@0 { 774 reg = <MI2S_PRIMARY>; 775 qcom,playback-sd-lines = <1>; 776 qcom,capture-sd-lines = <0>; 777 }; 778 779 secondary_mi2s: mi2s@1 { 780 reg = <MI2S_SECONDARY>; 781 qcom,playback-sd-lines = <0>; 782 }; 783 784 hdmi@5 { 785 reg = <LPASS_DP_RX>; 786 }; 787}; 788 789&mdp { 790 status = "okay"; 791}; 792 793&mdss { 794 status = "okay"; 795}; 796 797&mdss_dp { 798 status = "okay"; 799 pinctrl-names = "default"; 800 pinctrl-0 = <&dp_hot_plug_det>; 801 data-lanes = <0 1>; 802 vdda-1p2-supply = <&vdda_usb_ss_dp_1p2>; 803 vdda-0p9-supply = <&vdda_usb_ss_dp_core>; 804}; 805 806&pm6150_adc { 807 charger-thermistor@4f { 808 reg = <ADC5_AMUX_THM3_100K_PU>; 809 qcom,ratiometric; 810 qcom,hw-settle-time = <200>; 811 }; 812}; 813 814&pm6150_adc_tm { 815 status = "okay"; 816 817 charger-thermistor@0 { 818 reg = <0>; 819 io-channels = <&pm6150_adc ADC5_AMUX_THM3_100K_PU>; 820 qcom,ratiometric; 821 qcom,hw-settle-time-us = <200>; 822 }; 823}; 824 825&pm6150_pon { 826 status = "disabled"; 827}; 828 829&qupv3_id_0 { 830 status = "okay"; 831}; 832 833&qupv3_id_1 { 834 status = "okay"; 835}; 836 837&remoteproc_mpss { 838 status = "okay"; 839 compatible = "qcom,sc7180-mss-pil"; 840 iommus = <&apps_smmu 0x461 0x0>, <&apps_smmu 0x444 0x3>; 841 memory-region = <&mba_mem &mpss_mem>; 842 843 /* This gets overridden for SKUs with LTE support. */ 844 firmware-name = "qcom/sc7180-trogdor/modem-nolte/mba.mbn", 845 "qcom/sc7180-trogdor/modem-nolte/qdsp6sw.mbn"; 846}; 847 848&sdhc_1 { 849 status = "okay"; 850 851 pinctrl-names = "default", "sleep"; 852 pinctrl-0 = <&sdc1_on>; 853 pinctrl-1 = <&sdc1_off>; 854 vmmc-supply = <&mcp_vcc>; 855 vqmmc-supply = <&mcp_vccq>; 856}; 857 858&sdhc_2 { 859 pinctrl-names = "default", "sleep"; 860 pinctrl-0 = <&sdc2_on>; 861 pinctrl-1 = <&sdc2_off>; 862 vmmc-supply = <&pp2950_l9c>; 863 vqmmc-supply = <&ppvar_l6c>; 864 865 cd-gpios = <&tlmm 69 GPIO_ACTIVE_LOW>; 866}; 867 868&spi0 { 869 pinctrl-0 = <&qup_spi0_cs_gpio_init_high>, <&qup_spi0_cs_gpio>; 870 cs-gpios = <&tlmm 37 GPIO_ACTIVE_LOW>; 871}; 872 873&spi6 { 874 pinctrl-0 = <&qup_spi6_cs_gpio_init_high>, <&qup_spi6_cs_gpio>; 875 cs-gpios = <&tlmm 62 GPIO_ACTIVE_LOW>; 876}; 877 878ap_spi_fp: &spi10 { 879 pinctrl-0 = <&qup_spi10_cs_gpio_init_high>, <&qup_spi10_cs_gpio>; 880 cs-gpios = <&tlmm 89 GPIO_ACTIVE_LOW>; 881 882 cros_ec_fp: ec@0 { 883 compatible = "google,cros-ec-spi"; 884 reg = <0>; 885 interrupt-parent = <&tlmm>; 886 interrupts = <4 IRQ_TYPE_LEVEL_LOW>; 887 pinctrl-names = "default"; 888 pinctrl-0 = <&fp_to_ap_irq_l>; 889 spi-max-frequency = <3000000>; 890 }; 891}; 892 893#include <arm/cros-ec-keyboard.dtsi> 894#include <arm/cros-ec-sbs.dtsi> 895 896&uart3 { 897 status = "okay"; 898 899 /delete-property/interrupts; 900 interrupts-extended = <&intc GIC_SPI 604 IRQ_TYPE_LEVEL_HIGH>, 901 <&tlmm 41 IRQ_TYPE_EDGE_FALLING>; 902 903 pinctrl-names = "default", "sleep"; 904 pinctrl-1 = <&qup_uart3_sleep>; 905 906 bluetooth: bluetooth { 907 compatible = "qcom,wcn3991-bt"; 908 vddio-supply = <&pp1800_l10a>; 909 vddxo-supply = <&pp1800_l1c>; 910 vddrf-supply = <&pp1300_l2c>; 911 vddch0-supply = <&pp3300_l10c>; 912 max-speed = <3200000>; 913 }; 914}; 915 916&uart8 { 917 status = "okay"; 918}; 919 920&usb_1 { 921 status = "okay"; 922}; 923 924&usb_1_dwc3 { 925 dr_mode = "host"; 926}; 927 928&usb_1_hsphy { 929 status = "okay"; 930 vdd-supply = <&vdd_qusb_hs0_core>; 931 vdda-pll-supply = <&vdda_qusb_hs0_1p8>; 932 vdda-phy-dpdm-supply = <&vdda_qusb_hs0_3p1>; 933 qcom,imp-res-offset-value = <8>; 934 qcom,preemphasis-level = <QUSB2_V2_PREEMPHASIS_15_PERCENT>; 935 qcom,preemphasis-width = <QUSB2_V2_PREEMPHASIS_WIDTH_HALF_BIT>; 936 qcom,bias-ctrl-value = <0x22>; 937 qcom,charge-ctrl-value = <3>; 938 qcom,hsdisc-trim-value = <0>; 939}; 940 941&usb_1_qmpphy { 942 status = "okay"; 943 vdda-phy-supply = <&vdda_usb_ss_dp_1p2>; 944 vdda-pll-supply = <&vdda_usb_ss_dp_core>; 945}; 946 947&venus { 948 video-firmware { 949 iommus = <&apps_smmu 0x0c42 0x0>; 950 }; 951}; 952 953&wifi { 954 status = "okay"; 955 vdd-0.8-cx-mx-supply = <&vdd_cx_wlan>; 956 vdd-1.8-xo-supply = <&pp1800_l1c>; 957 vdd-1.3-rfa-supply = <&pp1300_l2c>; 958 vdd-3.3-ch0-supply = <&pp3300_l10c>; 959 vdd-3.3-ch1-supply = <&pp3300_l11c>; 960 961 wifi-firmware { 962 iommus = <&apps_smmu 0xc2 0x1>; 963 }; 964}; 965 966/* PINCTRL - additions to nodes defined in sc7180.dtsi */ 967 968&dp_hot_plug_det { 969 pinconf { 970 pins = "gpio117"; 971 bias-disable; 972 }; 973}; 974 975&pri_mi2s_active { 976 pinconf { 977 pins = "gpio53", "gpio54", "gpio55", "gpio56"; 978 drive-strength = <2>; 979 bias-pull-down; 980 }; 981}; 982 983&pri_mi2s_mclk_active { 984 pinconf { 985 pins = "gpio57"; 986 drive-strength = <2>; 987 bias-pull-down; 988 }; 989}; 990 991&qspi_cs0 { 992 pinconf { 993 pins = "gpio68"; 994 bias-disable; 995 }; 996}; 997 998&qspi_clk { 999 pinconf { 1000 pins = "gpio63"; 1001 drive-strength = <8>; 1002 bias-disable; 1003 }; 1004}; 1005 1006&qspi_data01 { 1007 pinconf { 1008 pins = "gpio64", "gpio65"; 1009 1010 /* High-Z when no transfers; nice to park the lines */ 1011 bias-pull-up; 1012 }; 1013}; 1014 1015&qup_i2c2_default { 1016 pinconf { 1017 pins = "gpio15", "gpio16"; 1018 drive-strength = <2>; 1019 1020 /* Has external pullup */ 1021 bias-disable; 1022 }; 1023}; 1024 1025&qup_i2c4_default { 1026 pinconf { 1027 pins = "gpio115", "gpio116"; 1028 drive-strength = <2>; 1029 1030 /* Has external pullup */ 1031 bias-disable; 1032 }; 1033}; 1034 1035&qup_i2c5_default { 1036 pinconf { 1037 pins = "gpio25", "gpio26"; 1038 drive-strength = <2>; 1039 1040 /* Has external pullup */ 1041 bias-disable; 1042 }; 1043}; 1044 1045&qup_i2c7_default { 1046 pinconf { 1047 pins = "gpio6", "gpio7"; 1048 drive-strength = <2>; 1049 1050 /* Has external pullup */ 1051 bias-disable; 1052 }; 1053}; 1054 1055&qup_i2c9_default { 1056 pinconf { 1057 pins = "gpio46", "gpio47"; 1058 drive-strength = <2>; 1059 1060 /* Has external pullup */ 1061 bias-disable; 1062 }; 1063}; 1064 1065&qup_spi0_cs_gpio { 1066 pinconf { 1067 pins = "gpio34", "gpio35", "gpio36", "gpio37"; 1068 drive-strength = <2>; 1069 bias-disable; 1070 }; 1071}; 1072 1073&qup_spi6_cs_gpio { 1074 pinconf { 1075 pins = "gpio59", "gpio60", "gpio61", "gpio62"; 1076 drive-strength = <2>; 1077 bias-disable; 1078 }; 1079}; 1080 1081&qup_spi10_cs_gpio { 1082 pinconf { 1083 pins = "gpio86", "gpio87", "gpio88", "gpio89"; 1084 drive-strength = <2>; 1085 bias-disable; 1086 }; 1087}; 1088 1089&qup_uart3_default { 1090 pinconf-cts { 1091 /* 1092 * Configure a pull-down on CTS to match the pull of 1093 * the Bluetooth module. 1094 */ 1095 pins = "gpio38"; 1096 bias-pull-down; 1097 }; 1098 1099 pinconf-rts-tx { 1100 /* We'll drive RTS and TX, so no pull */ 1101 pins = "gpio39", "gpio40"; 1102 drive-strength = <2>; 1103 bias-disable; 1104 }; 1105 1106 pinconf-rx { 1107 /* 1108 * Configure a pull-up on RX. This is needed to avoid 1109 * garbage data when the TX pin of the Bluetooth module is 1110 * in tri-state (module powered off or not driving the 1111 * signal yet). 1112 */ 1113 pins = "gpio41"; 1114 bias-pull-up; 1115 }; 1116}; 1117 1118&qup_uart8_default { 1119 pinconf-tx { 1120 pins = "gpio44"; 1121 drive-strength = <2>; 1122 bias-disable; 1123 }; 1124 1125 pinconf-rx { 1126 pins = "gpio45"; 1127 drive-strength = <2>; 1128 bias-pull-up; 1129 }; 1130}; 1131 1132&sec_mi2s_active { 1133 pinconf { 1134 pins = "gpio49", "gpio50", "gpio51"; 1135 drive-strength = <2>; 1136 bias-pull-down; 1137 }; 1138}; 1139 1140/* PINCTRL - board-specific pinctrl */ 1141 1142&pm6150_gpio { 1143 status = "disabled"; /* No GPIOs are connected */ 1144}; 1145 1146&pm6150l_gpio { 1147 gpio-line-names = "AP_SUSPEND", 1148 "", 1149 "", 1150 "", 1151 "", 1152 "", 1153 "", 1154 "", 1155 "", 1156 "", 1157 "", 1158 ""; 1159}; 1160 1161&tlmm { 1162 /* 1163 * pinctrl settings for pins that have no real owners. 1164 */ 1165 pinctrl-names = "default"; 1166 pinctrl-0 = <&bios_flash_wp_l>, <&ap_suspend_l_neuter>; 1167 1168 amp_en: amp-en { 1169 pinmux { 1170 pins = "gpio23"; 1171 function = "gpio"; 1172 }; 1173 1174 pinconf { 1175 pins = "gpio23"; 1176 bias-pull-down; 1177 }; 1178 }; 1179 1180 ap_ec_int_l: ap-ec-int-l { 1181 pinmux { 1182 pins = "gpio94"; 1183 function = "gpio"; 1184 input-enable; 1185 }; 1186 1187 pinconf { 1188 pins = "gpio94"; 1189 bias-pull-up; 1190 }; 1191 }; 1192 1193 ap_edp_bklten: ap-edp-bklten { 1194 pinmux { 1195 pins = "gpio12"; 1196 function = "gpio"; 1197 }; 1198 1199 pinconf { 1200 pins = "gpio12"; 1201 drive-strength = <2>; 1202 bias-disable; 1203 1204 /* Force backlight to be disabled to match state at boot. */ 1205 output-low; 1206 }; 1207 }; 1208 1209 ap_suspend_l_neuter: ap-suspend-l-neuter { 1210 pinmux { 1211 pins = "gpio27"; 1212 function = "gpio"; 1213 }; 1214 1215 pinconf { 1216 pins = "gpio27"; 1217 bias-disable; 1218 }; 1219 }; 1220 1221 bios_flash_wp_l: bios-flash-wp-l { 1222 pinmux { 1223 pins = "gpio66"; 1224 function = "gpio"; 1225 input-enable; 1226 }; 1227 1228 pinconf { 1229 pins = "gpio66"; 1230 bias-disable; 1231 }; 1232 }; 1233 1234 edp_brij_en: edp-brij-en { 1235 pinmux { 1236 pins = "gpio104"; 1237 function = "gpio"; 1238 }; 1239 1240 pinconf { 1241 pins = "gpio104"; 1242 drive-strength = <2>; 1243 bias-disable; 1244 }; 1245 }; 1246 1247 edp_brij_irq: edp-brij-irq { 1248 pinmux { 1249 pins = "gpio11"; 1250 function = "gpio"; 1251 }; 1252 1253 pinconf { 1254 pins = "gpio11"; 1255 drive-strength = <2>; 1256 bias-pull-down; 1257 }; 1258 }; 1259 1260 en_pp3300_codec: en-pp3300-codec { 1261 pinmux { 1262 pins = "gpio83"; 1263 function = "gpio"; 1264 }; 1265 1266 pinconf { 1267 pins = "gpio83"; 1268 drive-strength = <2>; 1269 bias-disable; 1270 }; 1271 }; 1272 1273 en_pp3300_dx_edp: en-pp3300-dx-edp { 1274 pinmux { 1275 pins = "gpio30"; 1276 function = "gpio"; 1277 }; 1278 1279 pinconf { 1280 pins = "gpio30"; 1281 drive-strength = <2>; 1282 bias-disable; 1283 }; 1284 }; 1285 1286 en_pp3300_hub: en-pp3300-hub { 1287 pinmux { 1288 pins = "gpio84"; 1289 function = "gpio"; 1290 }; 1291 1292 pinconf { 1293 pins = "gpio84"; 1294 drive-strength = <2>; 1295 bias-disable; 1296 }; 1297 }; 1298 1299 fp_to_ap_irq_l: fp-to-ap-irq-l { 1300 pinmux { 1301 pins = "gpio4"; 1302 function = "gpio"; 1303 input-enable; 1304 }; 1305 1306 pinconf { 1307 pins = "gpio4"; 1308 1309 /* Has external pullup */ 1310 bias-disable; 1311 }; 1312 }; 1313 1314 h1_ap_int_odl: h1-ap-int-odl { 1315 pinmux { 1316 pins = "gpio42"; 1317 function = "gpio"; 1318 input-enable; 1319 }; 1320 1321 pinconf { 1322 pins = "gpio42"; 1323 bias-pull-up; 1324 }; 1325 }; 1326 1327 hp_irq: hp-irq { 1328 pinmux { 1329 pins = "gpio28"; 1330 function = "gpio"; 1331 }; 1332 1333 pinconf { 1334 pins = "gpio28"; 1335 bias-pull-up; 1336 }; 1337 }; 1338 1339 pen_irq_l: pen-irq-l { 1340 pinmux { 1341 pins = "gpio21"; 1342 function = "gpio"; 1343 }; 1344 1345 pinconf { 1346 pins = "gpio21"; 1347 1348 /* Has external pullup */ 1349 bias-disable; 1350 }; 1351 }; 1352 1353 pen_pdct_l: pen-pdct-l { 1354 pinmux { 1355 pins = "gpio52"; 1356 function = "gpio"; 1357 }; 1358 1359 pinconf { 1360 pins = "gpio52"; 1361 1362 /* Has external pullup */ 1363 bias-disable; 1364 }; 1365 }; 1366 1367 pen_rst_odl: pen-rst-odl { 1368 pinmux { 1369 pins = "gpio18"; 1370 function = "gpio"; 1371 }; 1372 1373 pinconf { 1374 pins = "gpio18"; 1375 bias-disable; 1376 drive-strength = <2>; 1377 1378 /* 1379 * The pen driver doesn't currently support 1380 * driving this reset line. By specifying 1381 * output-high here we're relying on the fact 1382 * that this pin has a default pulldown at boot 1383 * (which makes sure the pen was in reset if it 1384 * was powered) and then we set it high here to 1385 * take it out of reset. Better would be if the 1386 * pen driver could control this and we could 1387 * remove "output-high" here. 1388 */ 1389 output-high; /* TODO: Remove this? */ 1390 }; 1391 }; 1392 1393 p_sensor_int_l: p-sensor-int-l { 1394 pinmux { 1395 pins = "gpio24"; 1396 function = "gpio"; 1397 input-enable; 1398 }; 1399 1400 pinconf { 1401 pins = "gpio24"; 1402 /* Has external pullup */ 1403 bias-disable; 1404 }; 1405 }; 1406 1407 qup_spi0_cs_gpio_init_high: qup-spi0-cs-gpio-init-high { 1408 pinconf { 1409 pins = "gpio37"; 1410 output-high; 1411 }; 1412 }; 1413 1414 qup_spi6_cs_gpio_init_high: qup-spi6-cs-gpio-init-high { 1415 pinconf { 1416 pins = "gpio62"; 1417 output-high; 1418 }; 1419 }; 1420 1421 qup_spi10_cs_gpio_init_high: qup-spi10-cs-gpio-init-high { 1422 pinconf { 1423 pins = "gpio89"; 1424 output-high; 1425 }; 1426 }; 1427 1428 qup_uart3_sleep: qup-uart3-sleep { 1429 pinmux { 1430 pins = "gpio38", "gpio39", 1431 "gpio40", "gpio41"; 1432 function = "gpio"; 1433 }; 1434 1435 pinconf-cts { 1436 /* 1437 * Configure a pull-down on CTS to match the pull of 1438 * the Bluetooth module. 1439 */ 1440 pins = "gpio38"; 1441 bias-pull-down; 1442 }; 1443 1444 pinconf-rts { 1445 /* 1446 * Configure pull-down on RTS. As RTS is active low 1447 * signal, pull it low to indicate the BT SoC that it 1448 * can wakeup the system anytime from suspend state by 1449 * pulling RX low (by sending wakeup bytes). 1450 */ 1451 pins = "gpio39"; 1452 bias-pull-down; 1453 }; 1454 1455 pinconf-tx { 1456 /* 1457 * Configure pull-up on TX when it isn't actively driven 1458 * to prevent BT SoC from receiving garbage during sleep. 1459 */ 1460 pins = "gpio40"; 1461 bias-pull-up; 1462 }; 1463 1464 pinconf-rx { 1465 /* 1466 * Configure a pull-up on RX. This is needed to avoid 1467 * garbage data when the TX pin of the Bluetooth module 1468 * is floating which may cause spurious wakeups. 1469 */ 1470 pins = "gpio41"; 1471 bias-pull-up; 1472 }; 1473 }; 1474 1475 /* Named trackpad_int_1v8_odl on earlier revision schematics */ 1476 trackpad_int_1v8_odl: 1477 tp_int_odl: tp-int-odl { 1478 pinmux { 1479 pins = "gpio0"; 1480 function = "gpio"; 1481 }; 1482 1483 pinconf { 1484 pins = "gpio0"; 1485 1486 /* Has external pullup */ 1487 bias-disable; 1488 }; 1489 }; 1490 1491 ts_int_l: ts-int-l { 1492 pinmux { 1493 pins = "gpio9"; 1494 function = "gpio"; 1495 }; 1496 1497 pinconf { 1498 pins = "gpio9"; 1499 bias-pull-up; 1500 }; 1501 }; 1502 1503 ts_reset_l: ts-reset-l { 1504 pinmux { 1505 pins = "gpio8"; 1506 function = "gpio"; 1507 }; 1508 1509 pinconf { 1510 pins = "gpio8"; 1511 bias-disable; 1512 drive-strength = <2>; 1513 }; 1514 }; 1515 1516 sdc1_on: sdc1-on { 1517 pinconf-clk { 1518 pins = "sdc1_clk"; 1519 bias-disable; 1520 drive-strength = <16>; 1521 }; 1522 1523 pinconf-cmd { 1524 pins = "sdc1_cmd"; 1525 bias-pull-up; 1526 drive-strength = <10>; 1527 }; 1528 1529 pinconf-data { 1530 pins = "sdc1_data"; 1531 bias-pull-up; 1532 drive-strength = <10>; 1533 }; 1534 1535 pinconf-rclk { 1536 pins = "sdc1_rclk"; 1537 bias-pull-down; 1538 }; 1539 }; 1540 1541 sdc1_off: sdc1-off { 1542 pinconf-clk { 1543 pins = "sdc1_clk"; 1544 bias-disable; 1545 drive-strength = <2>; 1546 }; 1547 1548 pinconf-cmd { 1549 pins = "sdc1_cmd"; 1550 bias-pull-up; 1551 drive-strength = <2>; 1552 }; 1553 1554 pinconf-data { 1555 pins = "sdc1_data"; 1556 bias-pull-up; 1557 drive-strength = <2>; 1558 }; 1559 1560 pinconf-rclk { 1561 pins = "sdc1_rclk"; 1562 bias-pull-down; 1563 }; 1564 }; 1565 1566 sdc2_on: sdc2-on { 1567 pinconf-clk { 1568 pins = "sdc2_clk"; 1569 bias-disable; 1570 drive-strength = <16>; 1571 }; 1572 1573 pinconf-cmd { 1574 pins = "sdc2_cmd"; 1575 bias-pull-up; 1576 drive-strength = <10>; 1577 }; 1578 1579 pinconf-data { 1580 pins = "sdc2_data"; 1581 bias-pull-up; 1582 drive-strength = <10>; 1583 }; 1584 1585 pinconf-sd-cd { 1586 pins = "gpio69"; 1587 bias-pull-up; 1588 drive-strength = <2>; 1589 }; 1590 }; 1591 1592 sdc2_off: sdc2-off { 1593 pinconf-clk { 1594 pins = "sdc2_clk"; 1595 bias-disable; 1596 drive-strength = <2>; 1597 }; 1598 1599 pinconf-cmd { 1600 pins = "sdc2_cmd"; 1601 bias-pull-up; 1602 drive-strength = <2>; 1603 }; 1604 1605 pinconf-data { 1606 pins = "sdc2_data"; 1607 bias-pull-up; 1608 drive-strength = <2>; 1609 }; 1610 1611 pinconf-sd-cd { 1612 pins = "gpio69"; 1613 bias-pull-up; 1614 drive-strength = <2>; 1615 }; 1616 }; 1617}; 1618