xref: /freebsd/sys/contrib/device-tree/src/arm/samsung/exynos4210-trats.dts (revision 5ca8e32633c4ffbbcd6762e5888b6a4ba0708c6c)
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * Samsung's Exynos4210 based Trats board device tree source
4 *
5 * Copyright (c) 2012 Samsung Electronics Co., Ltd.
6 *		http://www.samsung.com
7 *
8 * Device tree source file for Samsung's Trats board which is based on
9 * Samsung's Exynos4210 SoC.
10 */
11
12/dts-v1/;
13#include "exynos4210.dtsi"
14#include <dt-bindings/gpio/gpio.h>
15
16/ {
17	model = "Samsung Trats based on Exynos4210";
18	compatible = "samsung,trats", "samsung,exynos4210", "samsung,exynos4";
19	chassis-type = "handset";
20
21	memory@40000000 {
22		device_type = "memory";
23		reg =  <0x40000000 0x10000000
24			0x50000000 0x10000000
25			0x60000000 0x10000000
26			0x70000000 0x10000000>;
27	};
28
29	aliases {
30		mmc0 = &sdhci_0;
31		mmc1 = &sdhci_2;
32		mmc2 = &sdhci_3;
33	};
34
35	chosen {
36		bootargs = "root=/dev/mmcblk0p5 rootwait earlyprintk panic=5";
37		stdout-path = "serial2:115200n8";
38	};
39
40	vemmc_reg: regulator-0 {
41		compatible = "regulator-fixed";
42		regulator-name = "VMEM_VDD_2.8V";
43		regulator-min-microvolt = <2800000>;
44		regulator-max-microvolt = <2800000>;
45		gpio = <&gpk0 2 GPIO_ACTIVE_HIGH>;
46		enable-active-high;
47	};
48
49	tsp_reg: regulator-1 {
50		compatible = "regulator-fixed";
51		regulator-name = "TSP_FIXED_VOLTAGES";
52		regulator-min-microvolt = <2800000>;
53		regulator-max-microvolt = <2800000>;
54		gpio = <&gpl0 3 GPIO_ACTIVE_HIGH>;
55		enable-active-high;
56	};
57
58	cam_af_28v_reg: regulator-2 {
59		compatible = "regulator-fixed";
60		regulator-name = "8M_AF_2.8V_EN";
61		regulator-min-microvolt = <2800000>;
62		regulator-max-microvolt = <2800000>;
63		gpio = <&gpk1 1 GPIO_ACTIVE_HIGH>;
64		enable-active-high;
65	};
66
67	cam_io_en_reg: regulator-3 {
68		compatible = "regulator-fixed";
69		regulator-name = "CAM_IO_EN";
70		regulator-min-microvolt = <2800000>;
71		regulator-max-microvolt = <2800000>;
72		gpio = <&gpe2 1 GPIO_ACTIVE_HIGH>;
73		enable-active-high;
74	};
75
76	cam_io_12v_reg: regulator-4 {
77		compatible = "regulator-fixed";
78		regulator-name = "8M_1.2V_EN";
79		regulator-min-microvolt = <1200000>;
80		regulator-max-microvolt = <1200000>;
81		gpio = <&gpe2 5 GPIO_ACTIVE_HIGH>;
82		enable-active-high;
83	};
84
85	vt_core_15v_reg: regulator-5 {
86		compatible = "regulator-fixed";
87		regulator-name = "VT_CORE_1.5V";
88		regulator-min-microvolt = <1500000>;
89		regulator-max-microvolt = <1500000>;
90		gpio = <&gpe2 2 GPIO_ACTIVE_HIGH>;
91		enable-active-high;
92	};
93
94	gpio-keys {
95		compatible = "gpio-keys";
96
97		vol-down-key {
98			gpios = <&gpx2 1 GPIO_ACTIVE_LOW>;
99			linux,code = <114>;
100			label = "volume down";
101			debounce-interval = <10>;
102		};
103
104		vol-up-key {
105			gpios = <&gpx2 0 GPIO_ACTIVE_LOW>;
106			linux,code = <115>;
107			label = "volume up";
108			debounce-interval = <10>;
109		};
110
111		power-key {
112			gpios = <&gpx2 7 GPIO_ACTIVE_LOW>;
113			linux,code = <116>;
114			label = "power";
115			debounce-interval = <10>;
116			wakeup-source;
117		};
118
119		ok-key {
120			gpios = <&gpx3 5 GPIO_ACTIVE_LOW>;
121			linux,code = <352>;
122			label = "ok";
123			debounce-interval = <10>;
124		};
125	};
126
127	wlan_pwrseq: sdhci3-pwrseq {
128		compatible = "mmc-pwrseq-simple";
129		reset-gpios = <&gpl1 2 GPIO_ACTIVE_LOW>;
130	};
131
132	fixed-rate-clocks {
133		xxti {
134			compatible = "samsung,clock-xxti";
135			clock-frequency = <0>;
136		};
137
138		xusbxti {
139			compatible = "samsung,clock-xusbxti";
140			clock-frequency = <24000000>;
141		};
142
143		pmic_ap_clk: pmic-ap-clk {
144			/* Workaround for missing clock on max8997 PMIC */
145			compatible = "fixed-clock";
146			#clock-cells = <0>;
147			clock-frequency = <32768>;
148		};
149	};
150};
151
152&camera {
153	status = "okay";
154};
155
156&cpu0 {
157	cpu0-supply = <&varm_breg>;
158};
159
160&cpu_thermal {
161	cooling-maps {
162		map0 {
163			/* Corresponds to 800MHz at freq_table */
164			cooling-device = <&cpu0 2 2>, <&cpu1 2 2>;
165		};
166		map1 {
167			/* Corresponds to 200MHz at freq_table */
168			cooling-device = <&cpu0 4 4>, <&cpu1 4 4>;
169		};
170	};
171};
172
173&dsi_0 {
174	vddcore-supply = <&vusb_reg>;
175	vddio-supply = <&vmipi_reg>;
176	samsung,burst-clock-frequency = <500000000>;
177	samsung,esc-clock-frequency = <20000000>;
178	samsung,pll-clock-frequency = <24000000>;
179	status = "okay";
180
181	panel@0 {
182		reg = <0>;
183		compatible = "samsung,s6e8aa0";
184		vdd3-supply = <&vcclcd_reg>;
185		vci-supply = <&vlcd_reg>;
186		reset-gpios = <&gpy4 5 GPIO_ACTIVE_HIGH>;
187		power-on-delay = <50>;
188		reset-delay = <100>;
189		init-delay = <100>;
190		flip-horizontal;
191		flip-vertical;
192		panel-width-mm = <58>;
193		panel-height-mm = <103>;
194
195		display-timings {
196			timing-0 {
197				clock-frequency = <57153600>;
198				hactive = <720>;
199				vactive = <1280>;
200				hfront-porch = <5>;
201				hback-porch = <5>;
202				hsync-len = <5>;
203				vfront-porch = <13>;
204				vback-porch = <1>;
205				vsync-len = <2>;
206			};
207		};
208	};
209};
210
211&exynos_usbphy {
212	status = "okay";
213	vbus-supply = <&safe1_sreg>;
214};
215
216&fimc_0 {
217	status = "okay";
218	assigned-clocks = <&clock CLK_MOUT_FIMC0>,
219			  <&clock CLK_SCLK_FIMC0>;
220	assigned-clock-parents = <&clock CLK_SCLK_MPLL>;
221	assigned-clock-rates = <0>, <160000000>;
222};
223
224&fimc_1 {
225	status = "okay";
226	assigned-clocks = <&clock CLK_MOUT_FIMC1>,
227			  <&clock CLK_SCLK_FIMC1>;
228	assigned-clock-parents = <&clock CLK_SCLK_MPLL>;
229	assigned-clock-rates = <0>, <160000000>;
230};
231
232&fimc_2 {
233	status = "okay";
234	assigned-clocks = <&clock CLK_MOUT_FIMC2>,
235			  <&clock CLK_SCLK_FIMC2>;
236	assigned-clock-parents = <&clock CLK_SCLK_MPLL>;
237		assigned-clock-rates = <0>, <160000000>;
238};
239
240&fimc_3 {
241	status = "okay";
242	assigned-clocks = <&clock CLK_MOUT_FIMC3>,
243			  <&clock CLK_SCLK_FIMC3>;
244	assigned-clock-parents = <&clock CLK_SCLK_MPLL>;
245	assigned-clock-rates = <0>, <160000000>;
246};
247
248&fimd {
249	status = "okay";
250};
251
252&gpu {
253	status = "okay";
254};
255
256&hsotg {
257	vusb_d-supply = <&vusb_reg>;
258	vusb_a-supply = <&vusbdac_reg>;
259	dr_mode = "peripheral";
260	status = "okay";
261};
262
263&i2c_3 {
264	samsung,i2c-sda-delay = <100>;
265	samsung,i2c-slave-addr = <0x10>;
266	samsung,i2c-max-bus-freq = <400000>;
267	pinctrl-0 = <&i2c3_bus>;
268	pinctrl-names = "default";
269	status = "okay";
270
271	touchscreen@48 {
272		compatible = "melfas,mms114";
273		reg = <0x48>;
274		interrupt-parent = <&gpx0>;
275		interrupts = <4 IRQ_TYPE_EDGE_FALLING>;
276		touchscreen-size-x = <720>;
277		touchscreen-size-y = <1280>;
278		avdd-supply = <&tsp_reg>;
279		vdd-supply = <&tsp_reg>;
280	};
281};
282
283&i2c_5 {
284	samsung,i2c-sda-delay = <100>;
285	samsung,i2c-slave-addr = <0x10>;
286	samsung,i2c-max-bus-freq = <100000>;
287	pinctrl-0 = <&i2c5_bus>;
288	pinctrl-names = "default";
289	status = "okay";
290
291	pmic@66 {
292		compatible = "maxim,max8997-pmic";
293
294		reg = <0x66>;
295		interrupts-extended = <&gpx0 7 IRQ_TYPE_LEVEL_LOW>,
296				      <&gpx2 3 IRQ_TYPE_EDGE_FALLING>;
297
298		max8997,pmic-buck1-uses-gpio-dvs;
299		max8997,pmic-buck2-uses-gpio-dvs;
300		max8997,pmic-buck5-uses-gpio-dvs;
301
302		max8997,pmic-ignore-gpiodvs-side-effect;
303		max8997,pmic-buck125-default-dvs-idx = <0>;
304
305		max8997,pmic-buck125-dvs-gpios = <&gpx0 5 GPIO_ACTIVE_HIGH>,
306						 <&gpx0 6 GPIO_ACTIVE_HIGH>,
307						 <&gpl0 0 GPIO_ACTIVE_HIGH>;
308
309		max8997,pmic-buck1-dvs-voltage = <1350000>, <1300000>,
310						 <1250000>, <1200000>,
311						 <1150000>, <1100000>,
312						 <1000000>, <950000>;
313
314		max8997,pmic-buck2-dvs-voltage = <1100000>, <1000000>,
315						 <950000>,  <900000>,
316						 <1100000>, <1000000>,
317						 <950000>,  <900000>;
318
319		max8997,pmic-buck5-dvs-voltage = <1200000>, <1200000>,
320						 <1200000>, <1200000>,
321						 <1200000>, <1200000>,
322						 <1200000>, <1200000>;
323
324		regulators {
325			valive_reg: LDO2 {
326				regulator-name = "VALIVE_1.1V_C210";
327				regulator-min-microvolt = <1100000>;
328				regulator-max-microvolt = <1100000>;
329				regulator-always-on;
330			};
331
332			vusb_reg: LDO3 {
333				regulator-name = "VUSB_1.1V_C210";
334				regulator-min-microvolt = <1100000>;
335				regulator-max-microvolt = <1100000>;
336			};
337
338			vmipi_reg: LDO4 {
339				regulator-name = "VMIPI_1.8V";
340				regulator-min-microvolt = <1800000>;
341				regulator-max-microvolt = <1800000>;
342			};
343
344			vpda_reg: LDO6 {
345				regulator-name = "VCC_1.8V_PDA";
346				regulator-min-microvolt = <1800000>;
347				regulator-max-microvolt = <1800000>;
348				regulator-always-on;
349			};
350
351			vcam_reg: LDO7 {
352				regulator-name = "CAM_ISP_1.8V";
353				regulator-min-microvolt = <1800000>;
354				regulator-max-microvolt = <1800000>;
355			};
356
357			vusbdac_reg: LDO8 {
358				regulator-name = "VUSB+VDAC_3.3V_C210";
359				regulator-min-microvolt = <3300000>;
360				regulator-max-microvolt = <3300000>;
361			};
362
363			vccpda_reg: LDO9 {
364				regulator-name = "VCC_2.8V_PDA";
365				regulator-min-microvolt = <2800000>;
366				regulator-max-microvolt = <2800000>;
367				regulator-always-on;
368			};
369
370			vpll_reg: LDO10 {
371				regulator-name = "VPLL_1.1V_C210";
372				regulator-min-microvolt = <1100000>;
373				regulator-max-microvolt = <1100000>;
374				regulator-always-on;
375			};
376
377			vtcam_reg: LDO12 {
378				regulator-name = "VT_CAM_1.8V";
379				regulator-min-microvolt = <1800000>;
380				regulator-max-microvolt = <1800000>;
381			};
382
383			vcclcd_reg: LDO13 {
384				regulator-name = "VCC_3.3V_LCD";
385				regulator-min-microvolt = <3300000>;
386				regulator-max-microvolt = <3300000>;
387			};
388
389			vlcd_reg: LDO15 {
390				regulator-name = "VLCD_2.2V";
391				regulator-min-microvolt = <2200000>;
392				regulator-max-microvolt = <2200000>;
393			};
394
395			camsensor_reg: LDO16 {
396				regulator-name = "CAM_SENSOR_IO_1.8V";
397				regulator-min-microvolt = <1800000>;
398				regulator-max-microvolt = <1800000>;
399			};
400
401			tflash_reg: LDO17 {
402				regulator-name = "VTF_2.8V";
403				regulator-min-microvolt = <2800000>;
404				regulator-max-microvolt = <2800000>;
405			};
406
407			vddq_reg: LDO21 {
408				regulator-name = "VDDQ_M1M2_1.2V";
409				regulator-min-microvolt = <1200000>;
410				regulator-max-microvolt = <1200000>;
411				regulator-always-on;
412			};
413
414			varm_breg: BUCK1 {
415				regulator-name = "VARM_1.2V_C210";
416				regulator-min-microvolt = <900000>;
417				regulator-max-microvolt = <1350000>;
418				regulator-always-on;
419			};
420
421			vint_breg: BUCK2 {
422				regulator-name = "VINT_1.1V_C210";
423				regulator-min-microvolt = <900000>;
424				regulator-max-microvolt = <1100000>;
425				regulator-always-on;
426			};
427
428			camisp_breg: BUCK4 {
429				regulator-name = "CAM_ISP_CORE_1.2V";
430				regulator-min-microvolt = <1200000>;
431				regulator-max-microvolt = <1200000>;
432			};
433
434			vmem_breg: BUCK5 {
435				regulator-name = "VMEM_1.2V_C210";
436				regulator-min-microvolt = <1200000>;
437				regulator-max-microvolt = <1200000>;
438				regulator-always-on;
439			};
440
441			vccsub_breg: BUCK7 {
442				regulator-name = "VCC_SUB_2.0V";
443				regulator-min-microvolt = <2000000>;
444				regulator-max-microvolt = <2000000>;
445				regulator-always-on;
446			};
447
448			safe1_sreg: ESAFEOUT1 {
449				regulator-name = "SAFEOUT1";
450			};
451
452			safe2_sreg: ESAFEOUT2 {
453				regulator-name = "SAFEOUT2";
454				regulator-boot-on;
455			};
456
457			EN32KHZ_AP {
458				regulator-name = "EN32KHZ_AP";
459				regulator-always-on;
460			};
461
462			EN32KHZ_CP {
463				regulator-name = "EN32KHZ_CP";
464				regulator-always-on;
465			};
466		};
467	};
468};
469
470&pinctrl_1 {
471	bt_shutdown: bt-shutdown-pins {
472		samsung,pins = "gpl1-0";
473		samsung,pin-function = <EXYNOS_PIN_FUNC_OUTPUT>;
474		samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>;
475	};
476
477	bt_host_wakeup: bt-host-wakeup-pins {
478		samsung,pins = "gpx2-6";
479		samsung,pin-function = <EXYNOS_PIN_FUNC_INPUT>;
480		samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>;
481	};
482
483	bt_device_wakeup: bt-device-wakeup-pins {
484		samsung,pins = "gpx3-1";
485		samsung,pin-function = <EXYNOS_PIN_FUNC_OUTPUT>;
486		samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>;
487	};
488};
489
490&rtc {
491	status = "okay";
492	clocks = <&clock CLK_RTC>, <&pmic_ap_clk>;
493	clock-names = "rtc", "rtc_src";
494};
495
496&sdhci_0 {
497	bus-width = <8>;
498	non-removable;
499	pinctrl-0 = <&sd0_clk &sd0_cmd &sd0_bus8>;
500	pinctrl-names = "default";
501	vmmc-supply = <&vemmc_reg>;
502	status = "okay";
503};
504
505&sdhci_2 {
506	bus-width = <4>;
507	pinctrl-0 = <&sd2_clk &sd2_cmd &sd2_bus4>;
508	pinctrl-names = "default";
509	vmmc-supply = <&tflash_reg>;
510	cd-gpios = <&gpx3 4 GPIO_ACTIVE_LOW>;
511	status = "okay";
512};
513
514&sdhci_3 {
515	status = "okay";
516
517	#address-cells = <1>;
518	#size-cells = <0>;
519
520	non-removable;
521	bus-width = <4>;
522	mmc-pwrseq = <&wlan_pwrseq>;
523	vmmc-supply = <&tflash_reg>;
524
525	pinctrl-names = "default";
526	pinctrl-0 = <&sd3_clk>, <&sd3_cmd>, <&sd3_bus4>;
527
528	brcmf: wifi@1 {
529		compatible = "brcm,bcm4330-fmac", "brcm,bcm4329-fmac";
530		reg = <1>;
531
532		interrupt-parent = <&gpx2>;
533		interrupts = <5 IRQ_TYPE_LEVEL_HIGH>;
534		interrupt-names = "host-wake";
535	};
536};
537
538&serial_0 {
539	status = "okay";
540	pinctrl-0 = <&uart0_data &uart0_fctl>;
541	pinctrl-names = "default";
542
543	bluetooth {
544		compatible = "brcm,bcm4330-bt";
545		pinctrl-0 = <&bt_shutdown &bt_device_wakeup &bt_host_wakeup>;
546		pinctrl-names = "default";
547		shutdown-gpios = <&gpl1 0 GPIO_ACTIVE_HIGH>;
548		device-wakeup-gpios = <&gpx3 1 GPIO_ACTIVE_HIGH>;
549		host-wakeup-gpios = <&gpx2 6 GPIO_ACTIVE_HIGH>;
550	};
551};
552
553&serial_1 {
554	status = "okay";
555};
556
557&serial_2 {
558	status = "okay";
559};
560
561&serial_3 {
562	status = "okay";
563};
564
565&tmu {
566	status = "okay";
567};
568