1// SPDX-License-Identifier: GPL-2.0
2/* Copyright (c) 2016, The Linux Foundation. All rights reserved. */
3
4/dts-v1/;
5
6#include "msm8998.dtsi"
7#include "pm8005.dtsi"
8#include "pm8998.dtsi"
9#include "pmi8998.dtsi"
10
11/ {
12	model = "Qualcomm Technologies, Inc. MSM8998 v1 MTP";
13	compatible = "qcom,msm8998-mtp", "qcom,msm8998";
14
15	qcom,board-id = <8 0>;
16
17	aliases {
18		serial0 = &blsp2_uart1;
19		serial1 = &blsp1_uart3;
20	};
21
22	chosen {
23		stdout-path = "serial0:115200n8";
24	};
25
26	vph_pwr: vph-pwr-regulator {
27		compatible = "regulator-fixed";
28		regulator-name = "vph_pwr";
29		regulator-always-on;
30		regulator-boot-on;
31	};
32};
33
34&blsp1_uart3 {
35	status = "okay";
36
37	bluetooth {
38		compatible = "qcom,wcn3990-bt";
39
40		vddio-supply = <&vreg_s4a_1p8>;
41		vddxo-supply = <&vreg_l7a_1p8>;
42		vddrf-supply = <&vreg_l17a_1p3>;
43		vddch0-supply = <&vreg_l25a_3p3>;
44		max-speed = <3200000>;
45	};
46};
47
48&blsp1_uart3_on {
49	rx {
50		/delete-property/ bias-disable;
51		/*
52		 * Configure a pull-up on 45 (RX). This is needed to
53		 * avoid garbage data when the TX pin of the Bluetooth
54		 * module is in tri-state (module powered off or not
55		 * driving the signal yet).
56		 */
57		bias-pull-up;
58	};
59
60	cts {
61		/delete-property/ bias-disable;
62		/*
63		 * Configure a pull-down on 47 (CTS) to match the pull
64		 * of the Bluetooth module.
65		 */
66		bias-pull-down;
67	};
68};
69
70&blsp2_uart1 {
71	status = "okay";
72};
73
74&etf {
75	status = "okay";
76};
77
78&etm1 {
79	status = "okay";
80};
81
82&etm2 {
83	status = "okay";
84};
85
86&etm3 {
87	status = "okay";
88};
89
90&etm4 {
91	status = "okay";
92};
93
94&etm5 {
95	status = "okay";
96};
97
98&etm6 {
99	status = "okay";
100};
101
102&etm7 {
103	status = "okay";
104};
105
106&etm8 {
107	status = "okay";
108};
109
110&etr {
111	status = "okay";
112};
113
114&funnel1 {
115	status = "okay";
116};
117
118&funnel2 {
119	status = "okay";
120};
121
122&funnel3 {
123	status = "okay";
124};
125
126&funnel4 {
127	// FIXME: Figure out why clock late_initcall crashes the board with
128	// this enabled.
129	// status = "okay";
130};
131
132&funnel5 {
133	// FIXME: Figure out why clock late_initcall crashes the board with
134	// this enabled.
135	// status = "okay";
136};
137
138&pcie0 {
139	status = "okay";
140};
141
142&pcie_phy {
143	status = "okay";
144};
145
146&pm8005_regulators {
147	vdd_s1-supply = <&vph_pwr>;
148
149	pm8005_s1: s1 { /* VDD_GFX supply */
150		regulator-min-microvolt = <524000>;
151		regulator-max-microvolt = <1100000>;
152		regulator-enable-ramp-delay = <500>;
153
154		/* Hack until we rig up the gpu consumer */
155		regulator-always-on;
156	};
157};
158
159&qusb2phy {
160	status = "okay";
161
162	vdda-pll-supply = <&vreg_l12a_1p8>;
163	vdda-phy-dpdm-supply = <&vreg_l24a_3p075>;
164};
165
166&replicator1 {
167	status = "okay";
168};
169
170&rpm_requests {
171	pm8998-regulators {
172		compatible = "qcom,rpm-pm8998-regulators";
173
174		vdd_s1-supply = <&vph_pwr>;
175		vdd_s2-supply = <&vph_pwr>;
176		vdd_s3-supply = <&vph_pwr>;
177		vdd_s4-supply = <&vph_pwr>;
178		vdd_s5-supply = <&vph_pwr>;
179		vdd_s6-supply = <&vph_pwr>;
180		vdd_s7-supply = <&vph_pwr>;
181		vdd_s8-supply = <&vph_pwr>;
182		vdd_s9-supply = <&vph_pwr>;
183		vdd_s10-supply = <&vph_pwr>;
184		vdd_s11-supply = <&vph_pwr>;
185		vdd_s12-supply = <&vph_pwr>;
186		vdd_s13-supply = <&vph_pwr>;
187		vdd_l1_l27-supply = <&vreg_s7a_1p025>;
188		vdd_l2_l8_l17-supply = <&vreg_s3a_1p35>;
189		vdd_l3_l11-supply = <&vreg_s7a_1p025>;
190		vdd_l4_l5-supply = <&vreg_s7a_1p025>;
191		vdd_l6-supply = <&vreg_s5a_2p04>;
192		vdd_l7_l12_l14_l15-supply = <&vreg_s5a_2p04>;
193		vdd_l9-supply = <&vreg_bob>;
194		vdd_l10_l23_l25-supply = <&vreg_bob>;
195		vdd_l13_l19_l21-supply = <&vreg_bob>;
196		vdd_l16_l28-supply = <&vreg_bob>;
197		vdd_l18_l22-supply = <&vreg_bob>;
198		vdd_l20_l24-supply = <&vreg_bob>;
199		vdd_l26-supply = <&vreg_s3a_1p35>;
200		vdd_lvs1_lvs2-supply = <&vreg_s4a_1p8>;
201
202		vreg_s3a_1p35: s3 {
203			regulator-min-microvolt = <1352000>;
204			regulator-max-microvolt = <1352000>;
205		};
206
207		vreg_s4a_1p8: s4 {
208			regulator-min-microvolt = <1800000>;
209			regulator-max-microvolt = <1800000>;
210			regulator-allow-set-load;
211		};
212
213		vreg_s5a_2p04: s5 {
214			regulator-min-microvolt = <1904000>;
215			regulator-max-microvolt = <2040000>;
216		};
217
218		vreg_s7a_1p025: s7 {
219			regulator-min-microvolt = <900000>;
220			regulator-max-microvolt = <1028000>;
221		};
222
223		vreg_l1a_0p875: l1 {
224			regulator-min-microvolt = <880000>;
225			regulator-max-microvolt = <880000>;
226		};
227
228		vreg_l2a_1p2: l2 {
229			regulator-min-microvolt = <1200000>;
230			regulator-max-microvolt = <1200000>;
231		};
232
233		vreg_l3a_1p0: l3 {
234			regulator-min-microvolt = <1000000>;
235			regulator-max-microvolt = <1000000>;
236		};
237
238		vreg_l5a_0p8: l5 {
239			regulator-min-microvolt = <800000>;
240			regulator-max-microvolt = <800000>;
241		};
242
243		vreg_l6a_1p8: l6 {
244			regulator-min-microvolt = <1808000>;
245			regulator-max-microvolt = <1808000>;
246		};
247
248		vreg_l7a_1p8: l7 {
249			regulator-min-microvolt = <1800000>;
250			regulator-max-microvolt = <1800000>;
251		};
252
253		vreg_l8a_1p2: l8 {
254			regulator-min-microvolt = <1200000>;
255			regulator-max-microvolt = <1200000>;
256		};
257
258		vreg_l9a_1p8: l9 {
259			regulator-min-microvolt = <1808000>;
260			regulator-max-microvolt = <2960000>;
261		};
262
263		vreg_l10a_1p8: l10 {
264			regulator-min-microvolt = <1808000>;
265			regulator-max-microvolt = <2960000>;
266		};
267
268		vreg_l11a_1p0: l11 {
269			regulator-min-microvolt = <1000000>;
270			regulator-max-microvolt = <1000000>;
271		};
272
273		vreg_l12a_1p8: l12 {
274			regulator-min-microvolt = <1800000>;
275			regulator-max-microvolt = <1800000>;
276		};
277
278		vreg_l13a_2p95: l13 {
279			regulator-min-microvolt = <1808000>;
280			regulator-max-microvolt = <2960000>;
281		};
282
283		vreg_l14a_1p88: l14 {
284			regulator-min-microvolt = <1880000>;
285			regulator-max-microvolt = <1880000>;
286		};
287
288		vreg_l15a_1p8: l15 {
289			regulator-min-microvolt = <1800000>;
290			regulator-max-microvolt = <1800000>;
291		};
292
293		vreg_l16a_2p7: l16 {
294			regulator-min-microvolt = <2704000>;
295			regulator-max-microvolt = <2704000>;
296		};
297
298		vreg_l17a_1p3: l17 {
299			regulator-min-microvolt = <1304000>;
300			regulator-max-microvolt = <1304000>;
301		};
302
303		vreg_l18a_2p7: l18 {
304			regulator-min-microvolt = <2704000>;
305			regulator-max-microvolt = <2704000>;
306		};
307
308		vreg_l19a_3p0: l19 {
309			regulator-min-microvolt = <3008000>;
310			regulator-max-microvolt = <3008000>;
311		};
312
313		vreg_l20a_2p95: l20 {
314			regulator-min-microvolt = <2960000>;
315			regulator-max-microvolt = <2960000>;
316			regulator-allow-set-load;
317		};
318
319		vreg_l21a_2p95: l21 {
320			regulator-min-microvolt = <2960000>;
321			regulator-max-microvolt = <2960000>;
322			regulator-system-load = <800000>;
323			regulator-allow-set-load;
324		};
325
326		vreg_l22a_2p85: l22 {
327			regulator-min-microvolt = <2864000>;
328			regulator-max-microvolt = <2864000>;
329		};
330
331		vreg_l23a_3p3: l23 {
332			regulator-min-microvolt = <3312000>;
333			regulator-max-microvolt = <3312000>;
334		};
335
336		vreg_l24a_3p075: l24 {
337			regulator-min-microvolt = <3088000>;
338			regulator-max-microvolt = <3088000>;
339		};
340
341		vreg_l25a_3p3: l25 {
342			regulator-min-microvolt = <3104000>;
343			regulator-max-microvolt = <3312000>;
344		};
345
346		vreg_l26a_1p2: l26 {
347			regulator-min-microvolt = <1200000>;
348			regulator-max-microvolt = <1200000>;
349			regulator-allow-set-load;
350		};
351
352		vreg_l28_3p0: l28 {
353			regulator-min-microvolt = <3008000>;
354			regulator-max-microvolt = <3008000>;
355		};
356
357		vreg_lvs1a_1p8: lvs1 {
358			regulator-min-microvolt = <1800000>;
359			regulator-max-microvolt = <1800000>;
360		};
361
362		vreg_lvs2a_1p8: lvs2 {
363			regulator-min-microvolt = <1800000>;
364			regulator-max-microvolt = <1800000>;
365		};
366
367	};
368
369	pmi8998-regulators {
370		compatible = "qcom,rpm-pmi8998-regulators";
371
372		vdd_bob-supply = <&vph_pwr>;
373
374		vreg_bob: bob {
375			regulator-min-microvolt = <3312000>;
376			regulator-max-microvolt = <3600000>;
377		};
378	};
379};
380
381&remoteproc_adsp {
382	status = "okay";
383};
384
385&remoteproc_mss {
386	status = "okay";
387};
388
389&remoteproc_slpi {
390	status = "okay";
391};
392
393&tlmm {
394	gpio-reserved-ranges = <0 4>, <81 4>;
395};
396
397&sdhc2 {
398	status = "okay";
399	cd-gpios = <&tlmm 95 GPIO_ACTIVE_LOW>;
400
401	vmmc-supply = <&vreg_l21a_2p95>;
402	vqmmc-supply = <&vreg_l13a_2p95>;
403
404	pinctrl-names = "default", "sleep";
405	pinctrl-0 = <&sdc2_on &sdc2_cd>;
406	pinctrl-1 = <&sdc2_off &sdc2_cd>;
407};
408
409&stm {
410	status = "okay";
411};
412
413&ufshc {
414	status = "okay";
415	vcc-supply = <&vreg_l20a_2p95>;
416	vccq-supply = <&vreg_l26a_1p2>;
417	vccq2-supply = <&vreg_s4a_1p8>;
418	vcc-max-microamp = <750000>;
419	vccq-max-microamp = <560000>;
420	vccq2-max-microamp = <750000>;
421};
422
423&ufsphy {
424	status = "okay";
425	vdda-phy-supply = <&vreg_l1a_0p875>;
426	vdda-pll-supply = <&vreg_l2a_1p2>;
427	vddp-ref-clk-supply = <&vreg_l26a_1p2>;
428};
429
430&usb3 {
431	status = "okay";
432};
433
434&usb3_dwc3 {
435	dr_mode = "host"; /* Force to host until we have Type-C hooked up */
436};
437
438&usb3phy {
439	status = "okay";
440
441	vdda-phy-supply = <&vreg_l1a_0p875>;
442	vdda-pll-supply = <&vreg_l2a_1p2>;
443};
444
445&wifi {
446	status = "okay";
447
448	vdd-0.8-cx-mx-supply = <&vreg_l5a_0p8>;
449	vdd-1.8-xo-supply = <&vreg_l7a_1p8>;
450	vdd-1.3-rfa-supply = <&vreg_l17a_1p3>;
451	vdd-3.3-ch0-supply = <&vreg_l25a_3p3>;
452};
453