xref: /linux/arch/arm64/boot/dts/qcom/sm8150-hdk.dts (revision e7d759f31ca295d589f7420719c311870bb3166f)
1// SPDX-License-Identifier: BSD-3-Clause
2/*
3 * Copyright (c) 2020, The Linux Foundation. All rights reserved.
4 */
5
6/dts-v1/;
7
8#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
9#include <dt-bindings/gpio/gpio.h>
10#include <dt-bindings/usb/pd.h>
11#include "sm8150.dtsi"
12#include "pm8150.dtsi"
13#include "pm8150b.dtsi"
14#include "pm8150l.dtsi"
15
16/ {
17	model = "Qualcomm Technologies, Inc. SM8150 HDK";
18	compatible = "qcom,sm8150-hdk", "qcom,sm8150";
19	chassis-type = "embedded";
20
21	aliases {
22		serial0 = &uart2;
23	};
24
25	chosen {
26		stdout-path = "serial0:115200n8";
27	};
28
29	vph_pwr: vph-pwr-regulator {
30		compatible = "regulator-fixed";
31		regulator-name = "vph_pwr";
32		regulator-min-microvolt = <3700000>;
33		regulator-max-microvolt = <3700000>;
34	};
35
36	vreg_s4a_1p8: pm8150-s4 {
37		compatible = "regulator-fixed";
38		regulator-name = "vreg_s4a_1p8";
39
40		regulator-min-microvolt = <1800000>;
41		regulator-max-microvolt = <1800000>;
42
43		regulator-always-on;
44		regulator-boot-on;
45
46		vin-supply = <&vph_pwr>;
47	};
48
49	gpio-keys {
50		compatible = "gpio-keys";
51
52		key-vol-up {
53			label = "Volume Up";
54			linux,code = <KEY_VOLUMEUP>;
55			gpios = <&pm8150_gpios 6 GPIO_ACTIVE_LOW>;
56		};
57	};
58
59	hdmi-out {
60		compatible = "hdmi-connector";
61		type = "a";
62
63		port {
64			hdmi_con: endpoint {
65				remote-endpoint = <&lt9611_out>;
66			};
67		};
68	};
69};
70
71&apps_rsc {
72	regulators-0 {
73		compatible = "qcom,pm8150-rpmh-regulators";
74		qcom,pmic-id = "a";
75
76		vdd-s1-supply = <&vph_pwr>;
77		vdd-s2-supply = <&vph_pwr>;
78		vdd-s3-supply = <&vph_pwr>;
79		vdd-s4-supply = <&vph_pwr>;
80		vdd-s5-supply = <&vph_pwr>;
81		vdd-s6-supply = <&vph_pwr>;
82		vdd-s7-supply = <&vph_pwr>;
83		vdd-s8-supply = <&vph_pwr>;
84		vdd-s9-supply = <&vph_pwr>;
85		vdd-s10-supply = <&vph_pwr>;
86
87		vdd-l1-l8-l11-supply = <&vreg_s6a_0p9>;
88		vdd-l2-l10-supply = <&vreg_bob>;
89		vdd-l3-l4-l5-l18-supply = <&vreg_s6a_0p9>;
90		vdd-l6-l9-supply = <&vreg_s8c_1p3>;
91		vdd-l7-l12-l14-l15-supply = <&vreg_s5a_2p0>;
92		vdd-l13-l16-l17-supply = <&vreg_bob>;
93
94		vreg_s5a_2p0: smps5 {
95			regulator-min-microvolt = <1904000>;
96			regulator-max-microvolt = <2000000>;
97		};
98
99		vreg_s6a_0p9: smps6 {
100			regulator-min-microvolt = <920000>;
101			regulator-max-microvolt = <1128000>;
102		};
103
104		vdda_wcss_pll:
105		vreg_l1a_0p75: ldo1 {
106			regulator-min-microvolt = <752000>;
107			regulator-max-microvolt = <752000>;
108			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
109		};
110
111		vdd_pdphy:
112		vdda_usb_hs_3p1:
113		vreg_l2a_3p1: ldo2 {
114			regulator-min-microvolt = <3072000>;
115			regulator-max-microvolt = <3072000>;
116			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
117		};
118
119		vreg_l3a_0p8: ldo3 {
120			regulator-min-microvolt = <480000>;
121			regulator-max-microvolt = <932000>;
122			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
123		};
124
125		vdd_usb_hs_core:
126		vdda_csi_0_0p9:
127		vdda_csi_1_0p9:
128		vdda_csi_2_0p9:
129		vdda_csi_3_0p9:
130		vdda_dsi_0_0p9:
131		vdda_dsi_1_0p9:
132		vdda_dsi_0_pll_0p9:
133		vdda_dsi_1_pll_0p9:
134		vdda_pcie_1ln_core:
135		vdda_pcie_2ln_core:
136		vdda_pll_hv_cc_ebi01:
137		vdda_pll_hv_cc_ebi23:
138		vdda_qrefs_0p875_5:
139		vdda_sp_sensor:
140		vdda_ufs_2ln_core_1:
141		vdda_ufs_2ln_core_2:
142		vdda_qlink_lv:
143		vdda_qlink_lv_ck:
144		vreg_l5a_0p875: ldo5 {
145			regulator-min-microvolt = <880000>;
146			regulator-max-microvolt = <880000>;
147			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
148		};
149
150		vreg_l6a_1p2: ldo6 {
151			regulator-min-microvolt = <1200000>;
152			regulator-max-microvolt = <1200000>;
153			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
154		};
155
156		vreg_l7a_1p8: ldo7 {
157			regulator-min-microvolt = <1800000>;
158			regulator-max-microvolt = <1800000>;
159			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
160		};
161
162		vddpx_10:
163		vreg_l9a_1p2: ldo9 {
164			regulator-min-microvolt = <1200000>;
165			regulator-max-microvolt = <1200000>;
166			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
167		};
168
169		vreg_l10a_2p5: ldo10 {
170			regulator-min-microvolt = <2504000>;
171			regulator-max-microvolt = <2960000>;
172			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
173		};
174
175		vreg_l11a_0p8: ldo11 {
176			regulator-min-microvolt = <800000>;
177			regulator-max-microvolt = <800000>;
178			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
179		};
180
181		vdd_qfprom:
182		vdd_qfprom_sp:
183		vdda_apc_cs_1p8:
184		vdda_gfx_cs_1p8:
185		vdda_usb_hs_1p8:
186		vdda_qrefs_vref_1p8:
187		vddpx_10_a:
188		vreg_l12a_1p8: ldo12 {
189			regulator-min-microvolt = <1800000>;
190			regulator-max-microvolt = <1800000>;
191			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
192		};
193
194		vreg_l13a_2p7: ldo13 {
195			regulator-min-microvolt = <2704000>;
196			regulator-max-microvolt = <2704000>;
197			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
198		};
199
200		vreg_l14a_1p8: ldo14 {
201			regulator-min-microvolt = <1800000>;
202			regulator-max-microvolt = <1880000>;
203			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
204		};
205
206		vreg_l15a_1p7: ldo15 {
207			regulator-min-microvolt = <1704000>;
208			regulator-max-microvolt = <1704000>;
209			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
210		};
211
212		vreg_l16a_2p7: ldo16 {
213			regulator-min-microvolt = <2704000>;
214			regulator-max-microvolt = <2960000>;
215			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
216		};
217
218		vreg_l17a_3p0: ldo17 {
219			regulator-min-microvolt = <2856000>;
220			regulator-max-microvolt = <3008000>;
221			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
222		};
223
224		vreg_l18a_0p8: ldo18 {
225			regulator-min-microvolt = <880000>;
226			regulator-max-microvolt = <880000>;
227			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
228		};
229	};
230
231	regulators-1 {
232		compatible = "qcom,pm8150l-rpmh-regulators";
233		qcom,pmic-id = "c";
234
235		vdd-s1-supply = <&vph_pwr>;
236		vdd-s2-supply = <&vph_pwr>;
237		vdd-s3-supply = <&vph_pwr>;
238		vdd-s4-supply = <&vph_pwr>;
239		vdd-s5-supply = <&vph_pwr>;
240		vdd-s6-supply = <&vph_pwr>;
241		vdd-s7-supply = <&vph_pwr>;
242		vdd-s8-supply = <&vph_pwr>;
243
244		vdd-l1-l8-supply = <&vreg_s4a_1p8>;
245		vdd-l2-l3-supply = <&vreg_s8c_1p3>;
246		vdd-l4-l5-l6-supply = <&vreg_bob>;
247		vdd-l7-l11-supply = <&vreg_bob>;
248		vdd-l9-l10-supply = <&vreg_bob>;
249
250		vdd-bob-supply = <&vph_pwr>;
251		vdd-flash-supply = <&vreg_bob>;
252		vdd-rgb-supply = <&vreg_bob>;
253
254		vreg_bob: bob {
255			regulator-min-microvolt = <3008000>;
256			regulator-max-microvolt = <4000000>;
257			regulator-initial-mode = <RPMH_REGULATOR_MODE_AUTO>;
258			regulator-allow-bypass;
259		};
260
261		vreg_s8c_1p3: smps8 {
262			regulator-min-microvolt = <1352000>;
263			regulator-max-microvolt = <1352000>;
264		};
265
266		vreg_l1c_1p8: ldo1 {
267			regulator-min-microvolt = <1800000>;
268			regulator-max-microvolt = <1800000>;
269			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
270		};
271
272		vdda_wcss_adcdac_1:
273		vdda_wcss_adcdac_22:
274		vreg_l2c_1p3: ldo2 {
275			regulator-min-microvolt = <1304000>;
276			regulator-max-microvolt = <1304000>;
277			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
278		};
279
280		vdda_hv_ebi0:
281		vdda_hv_ebi1:
282		vdda_hv_ebi2:
283		vdda_hv_ebi3:
284		vdda_hv_refgen0:
285		vdda_qlink_hv_ck:
286		vreg_l3c_1p2: ldo3 {
287			regulator-min-microvolt = <1200000>;
288			regulator-max-microvolt = <1200000>;
289			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
290		};
291
292		vddpx_5:
293		vreg_l4c_1p8: ldo4 {
294			regulator-min-microvolt = <1704000>;
295			regulator-max-microvolt = <2928000>;
296			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
297		};
298
299		vddpx_6:
300		vreg_l5c_1p8: ldo5 {
301			regulator-min-microvolt = <1704000>;
302			regulator-max-microvolt = <2928000>;
303			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
304		};
305
306		vddpx_2:
307		vreg_l6c_2p9: ldo6 {
308			regulator-min-microvolt = <1800000>;
309			regulator-max-microvolt = <2960000>;
310			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
311		};
312
313		vreg_l7c_3p0: ldo7 {
314			regulator-min-microvolt = <2856000>;
315			regulator-max-microvolt = <3104000>;
316			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
317		};
318
319		vreg_l8c_1p8: ldo8 {
320			regulator-min-microvolt = <1800000>;
321			regulator-max-microvolt = <1800000>;
322			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
323		};
324
325		vreg_l9c_2p9: ldo9 {
326			regulator-min-microvolt = <2704000>;
327			regulator-max-microvolt = <2960000>;
328			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
329		};
330
331		vreg_l10c_3p3: ldo10 {
332			regulator-min-microvolt = <3000000>;
333			regulator-max-microvolt = <3312000>;
334			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
335		};
336
337		vreg_l11c_3p3: ldo11 {
338			regulator-min-microvolt = <3000000>;
339			regulator-max-microvolt = <3312000>;
340			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
341		};
342	};
343
344	regulators-2 {
345		compatible = "qcom,pm8009-rpmh-regulators";
346		qcom,pmic-id = "f";
347
348		vdd-s1-supply = <&vph_pwr>;
349		vdd-s2-supply = <&vreg_bob>;
350
351		vdd-l2-supply = <&vreg_s8c_1p3>;
352		vdd-l5-l6-supply = <&vreg_bob>;
353
354		vreg_l2f_1p2: ldo2 {
355			regulator-min-microvolt = <1200000>;
356			regulator-max-microvolt = <1200000>;
357			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
358		};
359
360		vreg_l5f_2p85: ldo5 {
361			regulator-min-microvolt = <2800000>;
362			regulator-max-microvolt = <2800000>;
363			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
364		};
365
366		vreg_l6f_2p85: ldo6 {
367			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
368			regulator-min-microvolt = <2856000>;
369			regulator-max-microvolt = <2856000>;
370		};
371	};
372};
373
374&gmu {
375	status = "okay";
376};
377
378&gpi_dma0 {
379	status = "okay";
380};
381
382&gpi_dma1 {
383	status = "okay";
384};
385
386&gpu {
387	status = "okay";
388};
389
390&i2c4 {
391	clock-frequency = <100000>;
392
393	status = "okay";
394
395	typec-mux@42 {
396		compatible = "fcs,fsa4480";
397		reg = <0x42>;
398
399		interrupts-extended = <&tlmm 152 IRQ_TYPE_LEVEL_LOW>;
400
401		vcc-supply = <&vreg_bob>;
402		mode-switch;
403		orientation-switch;
404
405		port {
406			fsa4480_sbu_mux: endpoint {
407				remote-endpoint = <&pm8150b_typec_sbu_out>;
408			};
409		};
410	};
411};
412
413&i2c9 {
414	status = "okay";
415	clock-frequency = <400000>;
416
417	lt9611_codec: hdmi-bridge@3b {
418		compatible = "lontium,lt9611";
419		reg = <0x3b>;
420		#sound-dai-cells = <1>;
421
422		interrupts-extended = <&tlmm 9 IRQ_TYPE_EDGE_FALLING>;
423
424		reset-gpios = <&tlmm 7 GPIO_ACTIVE_HIGH>;
425
426		vdd-supply = <&vreg_s4a_1p8>;
427		vcc-supply = <&vreg_bob>;
428
429		pinctrl-names = "default";
430		pinctrl-0 = <&lt9611_irq_pin>;
431
432		ports {
433			#address-cells = <1>;
434			#size-cells = <0>;
435
436			port@0 {
437				reg = <0>;
438
439				lt9611_a: endpoint {
440					remote-endpoint = <&mdss_dsi0_out>;
441				};
442			};
443
444			port@1 {
445				reg = <1>;
446
447				lt9611_b: endpoint {
448					remote-endpoint = <&mdss_dsi1_out>;
449				};
450			};
451
452			port@2 {
453				reg = <2>;
454
455				lt9611_out: endpoint {
456					remote-endpoint = <&hdmi_con>;
457				};
458			};
459		};
460	};
461};
462
463&mdss {
464	status = "okay";
465};
466
467&mdss_dp {
468	status = "okay";
469};
470
471&mdss_dp_out {
472	data-lanes = <0 1>;
473	remote-endpoint = <&usb_1_qmpphy_dp_in>;
474};
475
476&mdss_dsi0 {
477	status = "okay";
478	vdda-supply = <&vreg_l3c_1p2>;
479
480	qcom,dual-dsi-mode;
481	qcom,master-dsi;
482
483	ports {
484		port@1 {
485			endpoint {
486				remote-endpoint = <&lt9611_a>;
487				data-lanes = <0 1 2 3>;
488			};
489		};
490	};
491};
492
493&mdss_dsi0_phy {
494	status = "okay";
495	vdds-supply = <&vreg_l5a_0p875>;
496};
497
498&mdss_dsi1 {
499	vdda-supply = <&vreg_l3c_1p2>;
500
501	qcom,dual-dsi-mode;
502
503	/* DSI1 is slave, so use DSI0 clocks */
504	assigned-clock-parents = <&mdss_dsi0_phy 0>, <&mdss_dsi0_phy 1>;
505
506	status = "okay";
507
508	ports {
509		port@1 {
510			endpoint {
511				remote-endpoint = <&lt9611_b>;
512				data-lanes = <0 1 2 3>;
513			};
514		};
515	};
516};
517
518&mdss_dsi1_phy {
519	vdds-supply = <&vreg_l5a_0p875>;
520	status = "okay";
521};
522
523&pm8150b_vbus {
524	regulator-min-microamp = <500000>;
525	regulator-max-microamp = <3000000>;
526	status = "okay";
527};
528
529&pm8150b_typec {
530	status = "okay";
531
532	vdd-pdphy-supply = <&vreg_l2a_3p1>;
533
534	connector {
535		compatible = "usb-c-connector";
536
537		power-role = "source";
538		data-role = "dual";
539		self-powered;
540
541		source-pdos = <PDO_FIXED(5000, 3000,
542					 PDO_FIXED_DUAL_ROLE |
543					 PDO_FIXED_USB_COMM |
544					 PDO_FIXED_DATA_SWAP)>;
545
546		altmodes {
547			displayport {
548				svid = /bits/ 16 <0xff01>;
549				vdo = <0x00001c46>;
550			};
551		};
552
553		ports {
554			#address-cells = <1>;
555			#size-cells = <0>;
556
557			port@0 {
558				reg = <0>;
559				pm8150b_role_switch_in: endpoint {
560					remote-endpoint = <&usb_1_dwc3_hs>;
561				};
562			};
563
564			port@1 {
565				reg = <1>;
566				pm8150b_typec_mux_in: endpoint {
567					remote-endpoint = <&usb_1_qmpphy_out>;
568				};
569			};
570
571			port@2 {
572				reg = <2>;
573
574				pm8150b_typec_sbu_out: endpoint {
575					remote-endpoint = <&fsa4480_sbu_mux>;
576				};
577			};
578		};
579	};
580};
581
582&pon_pwrkey {
583	status = "okay";
584};
585
586&pon_resin {
587	status = "okay";
588
589	linux,code = <KEY_VOLUMEDOWN>;
590};
591
592&qupv3_id_0 {
593	status = "okay";
594};
595
596&qupv3_id_1 {
597	status = "okay";
598};
599
600&remoteproc_adsp {
601	status = "okay";
602
603	firmware-name = "qcom/sm8150/adsp.mbn";
604};
605
606&remoteproc_cdsp {
607	status = "okay";
608
609	firmware-name = "qcom/sm8150/cdsp.mbn";
610};
611
612&remoteproc_slpi {
613	status = "okay";
614
615	firmware-name = "qcom/sm8150/slpi.mbn";
616};
617
618&tlmm {
619	gpio-reserved-ranges = <0 4>, <126 4>;
620
621	lt9611_irq_pin: lt9611-irq-state {
622		pins = "gpio9";
623		function = "gpio";
624		bias-disable;
625	};
626
627};
628
629&uart2 {
630	status = "okay";
631};
632
633&ufs_mem_hc {
634	status = "okay";
635
636	reset-gpios = <&tlmm 175 GPIO_ACTIVE_LOW>;
637
638	vcc-supply = <&vreg_l10a_2p5>;
639	vcc-max-microamp = <750000>;
640	vccq-supply = <&vreg_l9a_1p2>;
641	vccq-max-microamp = <700000>;
642	vccq2-supply = <&vreg_s4a_1p8>;
643	vccq2-max-microamp = <750000>;
644};
645
646&ufs_mem_phy {
647	status = "okay";
648
649	vdda-phy-supply = <&vdda_ufs_2ln_core_1>;
650	vdda-pll-supply = <&vreg_l3c_1p2>;
651};
652
653&usb_1_hsphy {
654	status = "okay";
655	vdda-pll-supply = <&vdd_usb_hs_core>;
656	vdda33-supply = <&vdda_usb_hs_3p1>;
657	vdda18-supply = <&vdda_usb_hs_1p8>;
658};
659
660&usb_2_hsphy {
661	status = "okay";
662	vdda-pll-supply = <&vdd_usb_hs_core>;
663	vdda33-supply = <&vdda_usb_hs_3p1>;
664	vdda18-supply = <&vdda_usb_hs_1p8>;
665};
666
667&usb_1_qmpphy {
668	status = "okay";
669	vdda-phy-supply = <&vreg_l3c_1p2>;
670	vdda-pll-supply = <&vreg_l18a_0p8>;
671	orientation-switch;
672};
673
674&usb_1_qmpphy_dp_in {
675	remote-endpoint = <&mdss_dp_out>;
676};
677
678&usb_1_qmpphy_out {
679	remote-endpoint = <&pm8150b_typec_mux_in>;
680};
681
682&usb_1_qmpphy_usb_ss_in {
683	remote-endpoint = <&usb_1_dwc3_ss>;
684};
685
686&usb_2_qmpphy {
687	status = "okay";
688	vdda-phy-supply = <&vreg_l3c_1p2>;
689	vdda-pll-supply = <&vreg_l5a_0p875>;
690};
691
692&usb_1 {
693	status = "okay";
694};
695
696&usb_2 {
697	status = "okay";
698};
699
700&usb_1_dwc3 {
701	dr_mode = "otg";
702	usb-role-switch;
703};
704
705&usb_1_dwc3_hs {
706	remote-endpoint = <&pm8150b_role_switch_in>;
707};
708
709&usb_1_dwc3_ss {
710	remote-endpoint = <&usb_1_qmpphy_usb_ss_in>;
711};
712
713&usb_2_dwc3 {
714	dr_mode = "host";
715};
716