exynos5420-peach-pit.dts 8.9 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
/*
 * Google Peach Pit Rev 6+ board device tree source
 *
 * Copyright (c) 2014 Google, Inc
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 as
 * published by the Free Software Foundation.
 */

/dts-v1/;
#include <dt-bindings/input/input.h>
#include <dt-bindings/gpio/gpio.h>
#include "exynos5420.dtsi"

/ {
	model = "Google Peach Pit Rev 6+";

	compatible = "google,pit-rev16",
		"google,pit-rev15", "google,pit-rev14",
		"google,pit-rev13", "google,pit-rev12",
		"google,pit-rev11", "google,pit-rev10",
		"google,pit-rev9", "google,pit-rev8",
		"google,pit-rev7", "google,pit-rev6",
		"google,pit", "google,peach","samsung,exynos5420",
		"samsung,exynos5";

28 29 30 31 32
	aliases {
		/* Assign 20 so we don't get confused w/ builtin ones */
		i2c20 = "/spi@12d40000/cros-ec@0/i2c-tunnel";
	};

33 34 35 36 37 38 39
	backlight {
		compatible = "pwm-backlight";
		pwms = <&pwm 0 1000000 0>;
		brightness-levels = <0 100 500 1000 1500 2000 2500 2800>;
		default-brightness-level = <7>;
		pinctrl-0 = <&pwm0_out>;
		pinctrl-names = "default";
40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
	};

	fixed-rate-clocks {
		oscclk {
			compatible = "samsung,exynos5420-oscclk";
			clock-frequency = <24000000>;
		};
	};

	gpio-keys {
		compatible = "gpio-keys";

		pinctrl-names = "default";
		pinctrl-0 = <&power_key_irq>;

		power {
			label = "Power";
			gpios = <&gpx1 2 GPIO_ACTIVE_LOW>;
			linux,code = <KEY_POWER>;
			gpio-key,wakeup;
		};
	};

63 64
	memory {
		reg = <0x20000000 0x80000000>;
65
	};
66 67 68 69

	sound {
		compatible = "google,snow-audio-max98090";

70
		samsung,model = "Peach-Pit-I2S-MAX98090";
71 72 73
		samsung,i2s-controller = <&i2s0>;
		samsung,audio-codec = <&max98090>;
	};
74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95

	usb300_vbus_reg: regulator-usb300 {
		compatible = "regulator-fixed";
		regulator-name = "P5.0V_USB3CON0";
		regulator-min-microvolt = <5000000>;
		regulator-max-microvolt = <5000000>;
		gpio = <&gph0 0 0>;
		pinctrl-names = "default";
		pinctrl-0 = <&usb300_vbus_en>;
		enable-active-high;
	};

	usb301_vbus_reg: regulator-usb301 {
		compatible = "regulator-fixed";
		regulator-name = "P5.0V_USB3CON1";
		regulator-min-microvolt = <5000000>;
		regulator-max-microvolt = <5000000>;
		gpio = <&gph0 1 0>;
		pinctrl-names = "default";
		pinctrl-0 = <&usb301_vbus_en>;
		enable-active-high;
	};
96 97 98 99 100 101 102

	vbat: fixed-regulator {
		compatible = "regulator-fixed";
		regulator-name = "vbat-supply";
		regulator-boot-on;
		regulator-always-on;
	};
103 104
};

105 106 107 108 109 110 111 112 113 114 115
&dp {
	status = "okay";
	pinctrl-names = "default";
	pinctrl-0 = <&dp_hpd_gpio>;
	samsung,color-space = <0>;
	samsung,dynamic-range = <0>;
	samsung,ycbcr-coeff = <0>;
	samsung,color-depth = <1>;
	samsung,link-rate = <0x06>;
	samsung,lane-count = <2>;
	samsung,hpd-gpio = <&gpx2 6 0>;
116

117 118
	display-timings {
		native-mode = <&timing1>;
119

120 121 122 123 124 125 126 127 128 129 130
		timing1: timing@1 {
			clock-frequency = <70589280>;
			hactive = <1366>;
			vactive = <768>;
			hfront-porch = <40>;
			hback-porch = <40>;
			hsync-len = <32>;
			vback-porch = <10>;
			vfront-porch = <12>;
			vsync-len = <6>;
		};
131
	};
132
};
133

134 135 136 137
&fimd {
	status = "okay";
	samsung,invert-vclk;
};
138

139 140 141 142 143 144
&hdmi {
	status = "okay";
	hpd-gpio = <&gpx3 7 GPIO_ACTIVE_HIGH>;
	pinctrl-names = "default";
	pinctrl-0 = <&hdmi_hpd_irq>;
	ddc = <&i2c_2>;
145 146
};

147 148 149 150 151 152 153 154 155 156
&hsi2c_7 {
	status = "okay";

	max98090: codec@10 {
		compatible = "maxim,max98090";
		reg = <0x10>;
		interrupts = <2 0>;
		interrupt-parent = <&gpx0>;
		pinctrl-names = "default";
		pinctrl-0 = <&max98090_irq>;
157
	};
158
};
159

160 161 162 163 164 165 166 167 168 169 170
&hsi2c_9 {
	status = "okay";
	clock-frequency = <400000>;

	tpm@20 {
		compatible = "infineon,slb9645tt";
		reg = <0x20>;

		/* Unused irq; but still need to configure the pins */
		pinctrl-names = "default";
		pinctrl-0 = <&tpm_irq>;
171 172 173
	};
};

174
&i2c_2 {
175
	status = "okay";
176 177 178
	samsung,i2c-sda-delay = <100>;
	samsung,i2c-max-bus-freq = <66000>;
	samsung,i2c-slave-addr = <0x50>;
179 180
};

181
&i2s0 {
182 183 184 185 186 187 188 189
	status = "okay";
};

&mmc_0 {
	status = "okay";
	num-slots = <1>;
	broken-cd;
	caps2-mmc-hs200-1_8v;
190
	cap-mmc-highspeed;
191 192 193 194 195 196 197 198
	non-removable;
	card-detect-delay = <200>;
	clock-frequency = <400000000>;
	samsung,dw-mshc-ciu-div = <3>;
	samsung,dw-mshc-sdr-timing = <0 4>;
	samsung,dw-mshc-ddr-timing = <0 2>;
	pinctrl-names = "default";
	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_bus4 &sd0_bus8>;
199
	bus-width = <8>;
200 201 202 203 204
};

&mmc_2 {
	status = "okay";
	num-slots = <1>;
205
	cap-sd-highspeed;
206 207 208 209 210 211 212
	card-detect-delay = <200>;
	clock-frequency = <400000000>;
	samsung,dw-mshc-ciu-div = <3>;
	samsung,dw-mshc-sdr-timing = <2 3>;
	samsung,dw-mshc-ddr-timing = <1 2>;
	pinctrl-names = "default";
	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_cd &sd2_bus4>;
213
	bus-width = <4>;
214 215
};

216

217
&pinctrl_0 {
218 219 220
	pinctrl-names = "default";
	pinctrl-0 = <&mask_tpm_reset>;

221 222 223 224 225
	max98090_irq: max98090-irq {
		samsung,pins = "gpx0-2";
		samsung,pin-function = <0>;
		samsung,pin-pud = <0>;
		samsung,pin-drv = <0>;
226 227
	};

228 229 230 231 232 233 234 235 236
	/* We need GPX0_6 to be low at sleep time; just keep it low always */
	mask_tpm_reset: mask-tpm-reset {
		samsung,pins = "gpx0-6";
		samsung,pin-function = <1>;
		samsung,pin-pud = <0>;
		samsung,pin-drv = <0>;
		samsung,pin-val = <0>;
	};

237 238 239 240 241 242
	tpm_irq: tpm-irq {
		samsung,pins = "gpx1-0";
		samsung,pin-function = <0>;
		samsung,pin-pud = <0>;
		samsung,pin-drv = <0>;
	};
243

244 245 246 247 248 249
	power_key_irq: power-key-irq {
		samsung,pins = "gpx1-2";
		samsung,pin-function = <0>;
		samsung,pin-pud = <0>;
		samsung,pin-drv = <0>;
	};
250

251 252 253 254 255 256 257 258 259 260 261 262 263 264
	ec_irq: ec-irq {
		samsung,pins = "gpx1-5";
		samsung,pin-function = <0>;
		samsung,pin-pud = <0>;
		samsung,pin-drv = <0>;
	};

	tps65090_irq: tps65090-irq {
		samsung,pins = "gpx2-5";
		samsung,pin-function = <0>;
		samsung,pin-pud = <0>;
		samsung,pin-drv = <0>;
	};

265 266 267 268 269 270 271 272 273 274 275 276
	dp_hpd_gpio: dp_hpd_gpio {
		samsung,pins = "gpx2-6";
		samsung,pin-function = <0>;
		samsung,pin-pud = <3>;
		samsung,pin-drv = <0>;
	};

	hdmi_hpd_irq: hdmi-hpd-irq {
		samsung,pins = "gpx3-7";
		samsung,pin-function = <0>;
		samsung,pin-pud = <1>;
		samsung,pin-drv = <0>;
277 278 279
	};
};

280
&pinctrl_3 {
281 282 283 284 285 286 287 288 289 290 291 292 293
	/* Drive SPI lines at x2 for better integrity */
	spi2-bus {
		samsung,pin-drv = <2>;
	};

	/* Drive SPI chip select at x2 for better integrity */
	ec_spi_cs: ec-spi-cs {
		samsung,pins = "gpb1-2";
		samsung,pin-function = <1>;
		samsung,pin-pud = <0>;
		samsung,pin-drv = <2>;
	};

294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309
	usb300_vbus_en: usb300-vbus-en {
		samsung,pins = "gph0-0";
		samsung,pin-function = <1>;
		samsung,pin-pud = <0>;
		samsung,pin-drv = <0>;
	};

	usb301_vbus_en: usb301-vbus-en {
		samsung,pins = "gph0-1";
		samsung,pin-function = <1>;
		samsung,pin-pud = <0>;
		samsung,pin-drv = <0>;
	};
};

&rtc {
310 311 312
	status = "okay";
};

313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359
&spi_2 {
	status = "okay";
	num-cs = <1>;
	samsung,spi-src-clk = <0>;
	cs-gpios = <&gpb1 2 0>;

	cros_ec: cros-ec@0 {
		compatible = "google,cros-ec-spi";
		interrupt-parent = <&gpx1>;
		interrupts = <5 0>;
		pinctrl-names = "default";
		pinctrl-0 = <&ec_spi_cs &ec_irq>;
		reg = <0>;
		spi-max-frequency = <3125000>;

		controller-data {
			samsung,spi-feedback-delay = <1>;
		};

		i2c-tunnel {
			compatible = "google,cros-ec-i2c-tunnel";
			#address-cells = <1>;
			#size-cells = <0>;
			google,remote-bus = <0>;

			battery: sbs-battery@b {
				compatible = "sbs,sbs-battery";
				reg = <0xb>;
				sbs,poll-retry-count = <1>;
				sbs,i2c-retry-count = <2>;
			};

			power-regulator@48 {
				compatible = "ti,tps65090";
				reg = <0x48>;

				/*
				 * Config irq to disable internal pulls
				 * even though we run in polling mode.
				 */
				pinctrl-names = "default";
				pinctrl-0 = <&tps65090_irq>;

				vsys1-supply = <&vbat>;
				vsys2-supply = <&vbat>;
				vsys3-supply = <&vbat>;
				infet1-supply = <&vbat>;
360 361 362 363 364 365
				infet2-supply = <&tps65090_dcdc1>;
				infet3-supply = <&tps65090_dcdc2>;
				infet4-supply = <&tps65090_dcdc2>;
				infet5-supply = <&tps65090_dcdc2>;
				infet6-supply = <&tps65090_dcdc2>;
				infet7-supply = <&tps65090_dcdc1>;
366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417
				vsys-l1-supply = <&vbat>;
				vsys-l2-supply = <&vbat>;

				regulators {
					tps65090_dcdc1: dcdc1 {
						ti,enable-ext-control;
					};
					tps65090_dcdc2: dcdc2 {
						ti,enable-ext-control;
					};
					tps65090_dcdc3: dcdc3 {
						ti,enable-ext-control;
					};
					tps65090_fet1: fet1 {
						regulator-name = "vcd_led";
					};
					tps65090_fet2: fet2 {
						regulator-name = "video_mid";
						regulator-always-on;
					};
					tps65090_fet3: fet3 {
						regulator-name = "wwan_r";
						regulator-always-on;
					};
					tps65090_fet4: fet4 {
						regulator-name = "sdcard";
						regulator-always-on;
					};
					tps65090_fet5: fet5 {
						regulator-name = "camout";
					};
					tps65090_fet6: fet6 {
						regulator-name = "lcd_vdd";
					};
					tps65090_fet7: fet7 {
						regulator-name = "video_mid_1a";
						regulator-always-on;
					};
					tps65090_ldo1: ldo1 {
					};
					tps65090_ldo2: ldo2 {
					};
				};

				charger {
					compatible = "ti,tps65090-charger";
				};
			};
		};
	};
};

418
&uart_3 {
419 420 421
	status = "okay";
};

422
&usbdrd_phy0 {
423 424 425
	vbus-supply = <&usb300_vbus_reg>;
};

426
&usbdrd_phy1 {
427 428 429
	vbus-supply = <&usb301_vbus_reg>;
};

430 431 432 433 434 435 436 437
/*
 * Use longest HW watchdog in SoC (32 seconds) since the hardware
 * watchdog provides no debugging information (compared to soft/hard
 * lockup detectors) and so should be last resort.
 */
&watchdog {
	timeout-sec = <32>;
};
438

439
#include "cros-ec-keyboard.dtsi"