1/* 2 * Google Snow board device tree source 3 * 4 * Copyright (c) 2012 Google, Inc 5 * 6 * This program is free software; you can redistribute it and/or modify 7 * it under the terms of the GNU General Public License version 2 as 8 * published by the Free Software Foundation. 9 */ 10 11#include <dt-bindings/gpio/gpio.h> 12#include <dt-bindings/clock/maxim,max77686.h> 13#include <dt-bindings/interrupt-controller/irq.h> 14#include <dt-bindings/input/input.h> 15#include "exynos5250.dtsi" 16 17/ { 18 aliases { 19 i2c104 = &i2c_104; 20 }; 21 22 memory@40000000 { 23 device_type = "memory"; 24 reg = <0x40000000 0x80000000>; 25 }; 26 27 chosen { 28 bootargs = "console=tty1"; 29 stdout-path = "serial3:115200n8"; 30 }; 31 32 gpio-keys { 33 compatible = "gpio-keys"; 34 pinctrl-names = "default"; 35 pinctrl-0 = <&power_key_irq &lid_irq>; 36 37 power { 38 label = "Power"; 39 gpios = <&gpx1 3 GPIO_ACTIVE_LOW>; 40 linux,code = <KEY_POWER>; 41 wakeup-source; 42 }; 43 44 lid-switch { 45 label = "Lid"; 46 gpios = <&gpx3 5 GPIO_ACTIVE_LOW>; 47 linux,input-type = <5>; /* EV_SW */ 48 linux,code = <0>; /* SW_LID */ 49 debounce-interval = <1>; 50 wakeup-source; 51 }; 52 }; 53 54 vbat: vbat-fixed-regulator { 55 compatible = "regulator-fixed"; 56 regulator-name = "vbat-supply"; 57 regulator-boot-on; 58 }; 59 60 i2c-arbitrator { 61 compatible = "i2c-arb-gpio-challenge"; 62 #address-cells = <1>; 63 #size-cells = <0>; 64 65 i2c-parent = <&i2c_4>; 66 67 our-claim-gpio = <&gpf0 3 GPIO_ACTIVE_LOW>; 68 their-claim-gpios = <&gpe0 4 GPIO_ACTIVE_LOW>; 69 slew-delay-us = <10>; 70 wait-retry-us = <3000>; 71 wait-free-us = <50000>; 72 73 pinctrl-names = "default"; 74 pinctrl-0 = <&arb_our_claim &arb_their_claim>; 75 76 /* Use ID 104 as a hint that we're on physical bus 4 */ 77 i2c_104: i2c@0 { 78 reg = <0>; 79 #address-cells = <1>; 80 #size-cells = <0>; 81 82 battery: sbs-battery@b { 83 compatible = "sbs,sbs-battery"; 84 reg = <0xb>; 85 sbs,poll-retry-count = <1>; 86 }; 87 88 cros_ec: embedded-controller@1e { 89 compatible = "google,cros-ec-i2c"; 90 reg = <0x1e>; 91 interrupts = <6 IRQ_TYPE_NONE>; 92 interrupt-parent = <&gpx1>; 93 pinctrl-names = "default"; 94 pinctrl-0 = <&ec_irq>; 95 wakeup-source; 96 }; 97 98 power-regulator@48 { 99 compatible = "ti,tps65090"; 100 reg = <0x48>; 101 102 /* 103 * Config irq to disable internal pulls 104 * even though we run in polling mode. 105 */ 106 pinctrl-names = "default"; 107 pinctrl-0 = <&tps65090_irq>; 108 109 vsys1-supply = <&vbat>; 110 vsys2-supply = <&vbat>; 111 vsys3-supply = <&vbat>; 112 infet1-supply = <&vbat>; 113 infet2-supply = <&vbat>; 114 infet3-supply = <&vbat>; 115 infet4-supply = <&vbat>; 116 infet5-supply = <&vbat>; 117 infet6-supply = <&vbat>; 118 infet7-supply = <&vbat>; 119 vsys-l1-supply = <&vbat>; 120 vsys-l2-supply = <&vbat>; 121 122 regulators { 123 dcdc1 { 124 ti,enable-ext-control; 125 }; 126 dcdc2 { 127 ti,enable-ext-control; 128 }; 129 dcdc3 { 130 ti,enable-ext-control; 131 }; 132 fet1: fet1 { 133 regulator-name = "vcd_led"; 134 ti,overcurrent-wait = <3>; 135 }; 136 tps65090_fet2: fet2 { 137 regulator-name = "video_mid"; 138 regulator-always-on; 139 ti,overcurrent-wait = <3>; 140 }; 141 fet3 { 142 regulator-name = "wwan_r"; 143 regulator-always-on; 144 ti,overcurrent-wait = <3>; 145 }; 146 fet4 { 147 regulator-name = "sdcard"; 148 ti,overcurrent-wait = <3>; 149 }; 150 fet5 { 151 regulator-name = "camout"; 152 regulator-always-on; 153 ti,overcurrent-wait = <3>; 154 }; 155 fet6: fet6 { 156 regulator-name = "lcd_vdd"; 157 ti,overcurrent-wait = <3>; 158 }; 159 tps65090_fet7: fet7 { 160 regulator-name = "video_mid_1a"; 161 regulator-always-on; 162 ti,overcurrent-wait = <3>; 163 }; 164 ldo1 { 165 }; 166 ldo2 { 167 }; 168 }; 169 170 charger { 171 compatible = "ti,tps65090-charger"; 172 }; 173 }; 174 }; 175 }; 176 177 sound { 178 samsung,i2s-controller = <&i2s0>; 179 }; 180 181 usb3_vbus_reg: regulator-usb3 { 182 compatible = "regulator-fixed"; 183 regulator-name = "P5.0V_USB3CON"; 184 regulator-min-microvolt = <5000000>; 185 regulator-max-microvolt = <5000000>; 186 gpio = <&gpx2 7 GPIO_ACTIVE_HIGH>; 187 pinctrl-names = "default"; 188 pinctrl-0 = <&usb3_vbus_en>; 189 enable-active-high; 190 }; 191 192 fixed-rate-clocks { 193 xxti { 194 compatible = "samsung,clock-xxti"; 195 clock-frequency = <24000000>; 196 }; 197 }; 198 199 backlight: backlight { 200 compatible = "pwm-backlight"; 201 pwms = <&pwm 0 1000000 0>; 202 brightness-levels = <0 100 500 1000 1500 2000 2500 2800>; 203 default-brightness-level = <7>; 204 enable-gpios = <&gpx3 0 GPIO_ACTIVE_HIGH>; 205 power-supply = <&fet1>; 206 pinctrl-0 = <&pwm0_out>; 207 pinctrl-names = "default"; 208 }; 209 210 panel: panel { 211 compatible = "auo,b116xw03"; 212 power-supply = <&fet6>; 213 backlight = <&backlight>; 214 215 port { 216 panel_in: endpoint { 217 remote-endpoint = <&bridge_out>; 218 }; 219 }; 220 }; 221 222 mmc3_pwrseq: mmc3_pwrseq { 223 compatible = "mmc-pwrseq-simple"; 224 reset-gpios = <&gpx0 2 GPIO_ACTIVE_LOW>, /* WIFI_RSTn */ 225 <&gpx0 1 GPIO_ACTIVE_LOW>; /* WIFI_EN */ 226 clocks = <&max77686 MAX77686_CLK_PMIC>; 227 clock-names = "ext_clock"; 228 }; 229}; 230 231&cpu0 { 232 cpu0-supply = <&buck2_reg>; 233}; 234 235&dp { 236 status = "okay"; 237 pinctrl-names = "default"; 238 pinctrl-0 = <&dp_hpd>; 239 samsung,color-space = <0>; 240 samsung,color-depth = <1>; 241 samsung,link-rate = <0x0a>; 242 samsung,lane-count = <2>; 243 hpd-gpios = <&gpx0 7 GPIO_ACTIVE_HIGH>; 244 245 ports { 246 port { 247 dp_out: endpoint { 248 remote-endpoint = <&bridge_in>; 249 }; 250 }; 251 }; 252}; 253 254&ehci { 255 samsung,vbus-gpio = <&gpx1 1 GPIO_ACTIVE_HIGH>; 256}; 257 258&fimd { 259 status = "okay"; 260 samsung,invert-vclk; 261}; 262 263&hdmi { 264 hpd-gpios = <&gpx3 7 GPIO_ACTIVE_HIGH>; 265 pinctrl-names = "default"; 266 pinctrl-0 = <&hdmi_hpd_irq>; 267 phy = <&hdmiphy>; 268 ddc = <&i2c_2>; 269 hdmi-en-supply = <&tps65090_fet7>; 270 vdd-supply = <&ldo8_reg>; 271 vdd_osc-supply = <&ldo10_reg>; 272 vdd_pll-supply = <&ldo8_reg>; 273}; 274 275&hdmicec { 276 status = "okay"; 277}; 278 279&i2c_0 { 280 status = "okay"; 281 samsung,i2c-sda-delay = <100>; 282 samsung,i2c-max-bus-freq = <378000>; 283 284 max77686: max77686@09 { 285 compatible = "maxim,max77686"; 286 interrupt-parent = <&gpx3>; 287 interrupts = <2 IRQ_TYPE_NONE>; 288 pinctrl-names = "default"; 289 pinctrl-0 = <&max77686_irq>; 290 wakeup-source; 291 reg = <0x09>; 292 #clock-cells = <1>; 293 294 voltage-regulators { 295 ldo1_reg: LDO1 { 296 regulator-name = "P1.0V_LDO_OUT1"; 297 regulator-min-microvolt = <1000000>; 298 regulator-max-microvolt = <1000000>; 299 regulator-always-on; 300 }; 301 302 ldo2_reg: LDO2 { 303 regulator-name = "P1.8V_LDO_OUT2"; 304 regulator-min-microvolt = <1800000>; 305 regulator-max-microvolt = <1800000>; 306 regulator-always-on; 307 }; 308 309 ldo3_reg: LDO3 { 310 regulator-name = "P1.8V_LDO_OUT3"; 311 regulator-min-microvolt = <1800000>; 312 regulator-max-microvolt = <1800000>; 313 regulator-always-on; 314 }; 315 316 ldo7_reg: LDO7 { 317 regulator-name = "P1.1V_LDO_OUT7"; 318 regulator-min-microvolt = <1100000>; 319 regulator-max-microvolt = <1100000>; 320 regulator-always-on; 321 }; 322 323 ldo8_reg: LDO8 { 324 regulator-name = "P1.0V_LDO_OUT8"; 325 regulator-min-microvolt = <1000000>; 326 regulator-max-microvolt = <1000000>; 327 regulator-always-on; 328 }; 329 330 ldo10_reg: LDO10 { 331 regulator-name = "P1.8V_LDO_OUT10"; 332 regulator-min-microvolt = <1800000>; 333 regulator-max-microvolt = <1800000>; 334 regulator-always-on; 335 }; 336 337 ldo12_reg: LDO12 { 338 regulator-name = "P3.0V_LDO_OUT12"; 339 regulator-min-microvolt = <3000000>; 340 regulator-max-microvolt = <3000000>; 341 regulator-always-on; 342 }; 343 344 ldo14_reg: LDO14 { 345 regulator-name = "P1.8V_LDO_OUT14"; 346 regulator-min-microvolt = <1800000>; 347 regulator-max-microvolt = <1800000>; 348 regulator-always-on; 349 }; 350 351 ldo15_reg: LDO15 { 352 regulator-name = "P1.0V_LDO_OUT15"; 353 regulator-min-microvolt = <1000000>; 354 regulator-max-microvolt = <1000000>; 355 regulator-always-on; 356 }; 357 358 ldo16_reg: LDO16 { 359 regulator-name = "P1.8V_LDO_OUT16"; 360 regulator-min-microvolt = <1800000>; 361 regulator-max-microvolt = <1800000>; 362 regulator-always-on; 363 }; 364 365 buck1_reg: BUCK1 { 366 regulator-name = "vdd_mif"; 367 regulator-min-microvolt = <950000>; 368 regulator-max-microvolt = <1300000>; 369 regulator-always-on; 370 regulator-boot-on; 371 }; 372 373 buck2_reg: BUCK2 { 374 regulator-name = "vdd_arm"; 375 regulator-min-microvolt = <850000>; 376 regulator-max-microvolt = <1350000>; 377 regulator-always-on; 378 regulator-boot-on; 379 }; 380 381 buck3_reg: BUCK3 { 382 regulator-name = "vdd_int"; 383 regulator-min-microvolt = <900000>; 384 regulator-max-microvolt = <1200000>; 385 regulator-always-on; 386 regulator-boot-on; 387 }; 388 389 buck4_reg: BUCK4 { 390 regulator-name = "vdd_g3d"; 391 regulator-min-microvolt = <850000>; 392 regulator-max-microvolt = <1300000>; 393 regulator-always-on; 394 regulator-boot-on; 395 }; 396 397 buck5_reg: BUCK5 { 398 regulator-name = "P1.8V_BUCK_OUT5"; 399 regulator-min-microvolt = <1800000>; 400 regulator-max-microvolt = <1800000>; 401 regulator-always-on; 402 regulator-boot-on; 403 }; 404 405 buck6_reg: BUCK6 { 406 regulator-name = "P1.35V_BUCK_OUT6"; 407 regulator-min-microvolt = <1350000>; 408 regulator-max-microvolt = <1350000>; 409 regulator-always-on; 410 }; 411 412 buck7_reg: BUCK7 { 413 regulator-name = "P2.0V_BUCK_OUT7"; 414 regulator-min-microvolt = <2000000>; 415 regulator-max-microvolt = <2000000>; 416 regulator-always-on; 417 }; 418 419 buck8_reg: BUCK8 { 420 regulator-name = "P2.85V_BUCK_OUT8"; 421 regulator-min-microvolt = <2850000>; 422 regulator-max-microvolt = <2850000>; 423 regulator-always-on; 424 }; 425 }; 426 }; 427}; 428 429&i2c_1 { 430 status = "okay"; 431 samsung,i2c-sda-delay = <100>; 432 samsung,i2c-max-bus-freq = <378000>; 433 434 trackpad@67 { 435 reg = <0x67>; 436 compatible = "cypress,cyapa"; 437 interrupts = <2 IRQ_TYPE_NONE>; 438 interrupt-parent = <&gpx1>; 439 wakeup-source; 440 }; 441}; 442 443/* 444 * Disabled pullups since external part has its own pullups and 445 * double-pulling gets us out of spec in some cases. 446 */ 447&i2c2_bus { 448 samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; 449}; 450 451&i2c_2 { 452 status = "okay"; 453 samsung,i2c-sda-delay = <100>; 454 samsung,i2c-max-bus-freq = <66000>; 455 456 hdmiddc@50 { 457 compatible = "samsung,exynos4210-hdmiddc"; 458 reg = <0x50>; 459 }; 460}; 461 462&i2c_3 { 463 status = "okay"; 464 samsung,i2c-sda-delay = <100>; 465 samsung,i2c-max-bus-freq = <66000>; 466}; 467 468&i2c_4 { 469 status = "okay"; 470 samsung,i2c-sda-delay = <100>; 471 samsung,i2c-max-bus-freq = <66000>; 472}; 473 474&i2c_5 { 475 status = "okay"; 476 samsung,i2c-sda-delay = <100>; 477 samsung,i2c-max-bus-freq = <66000>; 478}; 479 480&i2c_7 { 481 status = "okay"; 482 samsung,i2c-sda-delay = <100>; 483 samsung,i2c-max-bus-freq = <66000>; 484 485 ptn3460: lvds-bridge@20 { 486 compatible = "nxp,ptn3460"; 487 reg = <0x20>; 488 powerdown-gpios = <&gpy2 5 GPIO_ACTIVE_HIGH>; 489 reset-gpios = <&gpx1 5 GPIO_ACTIVE_HIGH>; 490 edid-emulation = <5>; 491 492 ports { 493 #address-cells = <1>; 494 #size-cells = <0>; 495 496 port@0 { 497 reg = <0>; 498 499 bridge_out: endpoint { 500 remote-endpoint = <&panel_in>; 501 }; 502 }; 503 504 port@1 { 505 reg = <1>; 506 507 bridge_in: endpoint { 508 remote-endpoint = <&dp_out>; 509 }; 510 }; 511 }; 512 }; 513}; 514 515&i2c_8 { 516 status = "okay"; 517 samsung,i2c-sda-delay = <100>; 518 samsung,i2c-max-bus-freq = <378000>; 519 520 hdmiphy: hdmiphy@38 { 521 compatible = "samsung,exynos4212-hdmiphy"; 522 reg = <0x38>; 523 }; 524}; 525 526&i2s0 { 527 status = "okay"; 528}; 529 530/* eMMC flash */ 531&mmc_0 { 532 status = "okay"; 533 non-removable; 534 samsung,dw-mshc-ciu-div = <3>; 535 samsung,dw-mshc-sdr-timing = <2 3>; 536 samsung,dw-mshc-ddr-timing = <1 2>; 537 pinctrl-names = "default"; 538 pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_cd &sd0_bus4 &sd0_bus8>; 539 bus-width = <8>; 540 cap-mmc-highspeed; 541}; 542 543/* uSD card */ 544&mmc_2 { 545 status = "okay"; 546 card-detect-delay = <200>; 547 samsung,dw-mshc-ciu-div = <3>; 548 samsung,dw-mshc-sdr-timing = <2 3>; 549 samsung,dw-mshc-ddr-timing = <1 2>; 550 pinctrl-names = "default"; 551 pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus4>; 552 bus-width = <4>; 553 wp-gpios = <&gpc2 1 GPIO_ACTIVE_HIGH>; 554 cap-sd-highspeed; 555}; 556 557/* 558 * On Snow we've got SIP WiFi and so can keep drive strengths low to 559 * reduce EMI. 560 * 561 * WiFi SDIO module 562 */ 563&mmc_3 { 564 status = "okay"; 565 non-removable; 566 cap-sdio-irq; 567 keep-power-in-suspend; 568 samsung,dw-mshc-ciu-div = <3>; 569 samsung,dw-mshc-sdr-timing = <2 3>; 570 samsung,dw-mshc-ddr-timing = <1 2>; 571 pinctrl-names = "default"; 572 pinctrl-0 = <&sd3_clk &sd3_cmd &sd3_bus4 &wifi_en &wifi_rst>; 573 bus-width = <4>; 574 cap-sd-highspeed; 575 mmc-pwrseq = <&mmc3_pwrseq>; 576}; 577 578&pinctrl_0 { 579 wifi_en: wifi-en { 580 samsung,pins = "gpx0-1"; 581 samsung,pin-function = <EXYNOS_PIN_FUNC_OUTPUT>; 582 samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; 583 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 584 }; 585 586 wifi_rst: wifi-rst { 587 samsung,pins = "gpx0-2"; 588 samsung,pin-function = <EXYNOS_PIN_FUNC_OUTPUT>; 589 samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; 590 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 591 }; 592 593 power_key_irq: power-key-irq { 594 samsung,pins = "gpx1-3"; 595 samsung,pin-function = <EXYNOS_PIN_FUNC_F>; 596 samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; 597 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 598 }; 599 600 ec_irq: ec-irq { 601 samsung,pins = "gpx1-6"; 602 samsung,pin-function = <EXYNOS_PIN_FUNC_INPUT>; 603 samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; 604 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 605 }; 606 607 tps65090_irq: tps65090-irq { 608 samsung,pins = "gpx2-6"; 609 samsung,pin-function = <EXYNOS_PIN_FUNC_INPUT>; 610 samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; 611 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 612 }; 613 614 usb3_vbus_en: usb3-vbus-en { 615 samsung,pins = "gpx2-7"; 616 samsung,pin-function = <EXYNOS_PIN_FUNC_OUTPUT>; 617 samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; 618 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 619 }; 620 621 max77686_irq: max77686-irq { 622 samsung,pins = "gpx3-2"; 623 samsung,pin-function = <EXYNOS_PIN_FUNC_INPUT>; 624 samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; 625 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 626 }; 627 628 lid_irq: lid-irq { 629 samsung,pins = "gpx3-5"; 630 samsung,pin-function = <EXYNOS_PIN_FUNC_F>; 631 samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; 632 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 633 }; 634 635 hdmi_hpd_irq: hdmi-hpd-irq { 636 samsung,pins = "gpx3-7"; 637 samsung,pin-function = <EXYNOS_PIN_FUNC_INPUT>; 638 samsung,pin-pud = <EXYNOS_PIN_PULL_DOWN>; 639 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 640 }; 641}; 642 643&pinctrl_1 { 644 arb_their_claim: arb-their-claim { 645 samsung,pins = "gpe0-4"; 646 samsung,pin-function = <EXYNOS_PIN_FUNC_INPUT>; 647 samsung,pin-pud = <EXYNOS_PIN_PULL_UP>; 648 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 649 }; 650 651 arb_our_claim: arb-our-claim { 652 samsung,pins = "gpf0-3"; 653 samsung,pin-function = <EXYNOS_PIN_FUNC_OUTPUT>; 654 samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>; 655 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 656 }; 657}; 658 659&rtc { 660 status = "okay"; 661 clocks = <&clock CLK_RTC>, <&max77686 MAX77686_CLK_AP>; 662 clock-names = "rtc", "rtc_src"; 663}; 664 665&sd3_bus4 { 666 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 667}; 668 669&sd3_clk { 670 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 671}; 672 673&sd3_cmd { 674 samsung,pin-pud = <EXYNOS_PIN_PULL_UP>; 675 samsung,pin-drv = <EXYNOS4_PIN_DRV_LV1>; 676}; 677 678&spi_1 { 679 status = "okay"; 680 samsung,spi-src-clk = <0>; 681 num-cs = <1>; 682 cs-gpios = <&gpa2 5 GPIO_ACTIVE_HIGH>; 683}; 684 685&usbdrd_dwc3 { 686 dr_mode = "host"; 687}; 688 689&usbdrd_phy { 690 vbus-supply = <&usb3_vbus_reg>; 691}; 692 693#include "cros-ec-keyboard.dtsi" 694