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