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 "sm8250.dtsi"
10
11/ {
12	model = "Qualcomm Technologies, Inc. SM8250 MTP";
13	compatible = "qcom,sm8250-mtp";
14
15	aliases {
16		serial0 = &uart2;
17	};
18
19	chosen {
20		stdout-path = "serial0:115200n8";
21	};
22
23	vph_pwr: vph-pwr-regulator {
24		compatible = "regulator-fixed";
25		regulator-name = "vph_pwr";
26		regulator-min-microvolt = <3700000>;
27		regulator-max-microvolt = <3700000>;
28	};
29
30	vreg_s4a_1p8: pm8150-s4 {
31		compatible = "regulator-fixed";
32		regulator-name = "vreg_s4a_1p8";
33
34		regulator-min-microvolt = <1800000>;
35		regulator-max-microvolt = <1800000>;
36
37		regulator-always-on;
38		regulator-boot-on;
39
40		vin-supply = <&vph_pwr>;
41	};
42
43	vreg_s6c_0p88: smpc6-regulator {
44		compatible = "regulator-fixed";
45		regulator-name = "vreg_s6c_0p88";
46
47		regulator-min-microvolt = <880000>;
48		regulator-max-microvolt = <880000>;
49		regulator-always-on;
50		vin-supply = <&vph_pwr>;
51	};
52};
53
54&apps_rsc {
55	pm8150-rpmh-regulators {
56		compatible = "qcom,pm8150-rpmh-regulators";
57		qcom,pmic-id = "a";
58
59		vdd-s1-supply = <&vph_pwr>;
60		vdd-s2-supply = <&vph_pwr>;
61		vdd-s3-supply = <&vph_pwr>;
62		vdd-s4-supply = <&vph_pwr>;
63		vdd-s5-supply = <&vph_pwr>;
64		vdd-s6-supply = <&vph_pwr>;
65		vdd-s7-supply = <&vph_pwr>;
66		vdd-s8-supply = <&vph_pwr>;
67		vdd-s9-supply = <&vph_pwr>;
68		vdd-s10-supply = <&vph_pwr>;
69		vdd-l1-l8-l11-supply = <&vreg_s6c_0p88>;
70		vdd-l2-l10-supply = <&vreg_bob>;
71		vdd-l3-l4-l5-l18-supply = <&vreg_s6a_0p95>;
72		vdd-l6-l9-supply = <&vreg_s8c_1p3>;
73		vdd-l7-l12-l14-l15-supply = <&vreg_s5a_1p9>;
74		vdd-l13-l16-l17-supply = <&vreg_bob>;
75
76		vreg_s5a_1p9: smps5 {
77			regulator-name = "vreg_s5a_1p9";
78			regulator-min-microvolt = <1904000>;
79			regulator-max-microvolt = <2000000>;
80			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
81		};
82
83		vreg_s6a_0p95: smps6 {
84			regulator-name = "vreg_s6a_0p95";
85			regulator-min-microvolt = <920000>;
86			regulator-max-microvolt = <1128000>;
87			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
88		};
89
90		vreg_l2a_3p1: ldo2 {
91			regulator-name = "vreg_l2a_3p1";
92			regulator-min-microvolt = <3072000>;
93			regulator-max-microvolt = <3072000>;
94			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
95		};
96
97		vreg_l3a_0p9: ldo3 {
98			regulator-name = "vreg_l3a_0p9";
99			regulator-min-microvolt = <928000>;
100			regulator-max-microvolt = <932000>;
101			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
102		};
103
104		vreg_l5a_0p875: ldo5 {
105			regulator-name = "vreg_l5a_0p875";
106			regulator-min-microvolt = <880000>;
107			regulator-max-microvolt = <880000>;
108			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
109		};
110
111		vreg_l6a_1p2: ldo6 {
112			regulator-name = "vreg_l6a_1p2";
113			regulator-min-microvolt = <1200000>;
114			regulator-max-microvolt = <1200000>;
115			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
116		};
117
118		vreg_l7a_1p7: ldo7 {
119			regulator-name = "vreg_l7a_1p7";
120			regulator-min-microvolt = <1704000>;
121			regulator-max-microvolt = <1800000>;
122			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
123		};
124
125		vreg_l9a_1p2: ldo9 {
126			regulator-name = "vreg_l9a_1p2";
127			regulator-min-microvolt = <1200000>;
128			regulator-max-microvolt = <1200000>;
129			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
130		};
131
132		vreg_l10a_1p8: ldo10 {
133			regulator-name = "vreg_l10a_1p8";
134			regulator-min-microvolt = <1800000>;
135			regulator-max-microvolt = <1800000>;
136			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
137		};
138
139		vreg_l11a_0p75: ldo11 {
140			regulator-name = "vreg_l11a_0p75";
141			regulator-min-microvolt = <800000>;
142			regulator-max-microvolt = <800000>;
143			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
144		};
145
146		vreg_l12a_1p8: ldo12 {
147			regulator-name = "vreg_l12a_1p8";
148			regulator-min-microvolt = <1800000>;
149			regulator-max-microvolt = <1800000>;
150			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
151		};
152
153		vreg_l13a_ts_3p0: ldo13 {
154			regulator-name = "vreg_l13a_ts_3p0";
155			regulator-min-microvolt = <3008000>;
156			regulator-max-microvolt = <3008000>;
157			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
158		};
159
160		vreg_l14a_1p8: ldo14 {
161			regulator-name = "vreg_l14a_1p8";
162			regulator-min-microvolt = <1800000>;
163			regulator-max-microvolt = <1880000>;
164			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
165		};
166
167		vreg_l15a_11ad_io_1p8: ldo15 {
168			regulator-name = "vreg_l15a_11ad_io_1p8";
169			regulator-min-microvolt = <1800000>;
170			regulator-max-microvolt = <1800000>;
171			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
172		};
173
174		vreg_l16a_2p7: ldo16 {
175			regulator-name = "vreg_l16a_2p7";
176			regulator-min-microvolt = <2704000>;
177			regulator-max-microvolt = <2960000>;
178			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
179		};
180
181		vreg_l17a_3p0: ldo17 {
182			regulator-name = "vreg_l17a_3p0";
183			regulator-min-microvolt = <2856000>;
184			regulator-max-microvolt = <3008000>;
185			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
186		};
187	};
188
189	pm8150l-rpmh-regulators {
190		compatible = "qcom,pm8150l-rpmh-regulators";
191		qcom,pmic-id = "c";
192
193		vdd-s1-supply = <&vph_pwr>;
194		vdd-s2-supply = <&vph_pwr>;
195		vdd-s3-supply = <&vph_pwr>;
196		vdd-s4-supply = <&vph_pwr>;
197		vdd-s5-supply = <&vph_pwr>;
198		vdd-s6-supply = <&vph_pwr>;
199		vdd-s7-supply = <&vph_pwr>;
200		vdd-s8-supply = <&vph_pwr>;
201		vdd-l1-l8-supply = <&vreg_s4a_1p8>;
202		vdd-l2-l3-supply = <&vreg_s8c_1p3>;
203		vdd-l4-l5-l6-supply = <&vreg_bob>;
204		vdd-l7-l11-supply = <&vreg_bob>;
205		vdd-l9-l10-supply = <&vreg_bob>;
206		vdd-bob-supply = <&vph_pwr>;
207
208		vreg_bob: bob {
209			regulator-name = "vreg_bob";
210			regulator-min-microvolt = <3008000>;
211			regulator-max-microvolt = <4000000>;
212			regulator-initial-mode = <RPMH_REGULATOR_MODE_AUTO>;
213		};
214
215		vreg_s8c_1p3: smps8 {
216			regulator-name = "vreg_s8c_1p3";
217			regulator-min-microvolt = <1352000>;
218			regulator-max-microvolt = <1352000>;
219			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
220		};
221
222		vreg_l1c_1p8: ldo1 {
223			regulator-name = "vreg_l1c_1p8";
224			regulator-min-microvolt = <1800000>;
225			regulator-max-microvolt = <1800000>;
226			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
227		};
228
229		vreg_l2c_1p2: ldo2 {
230			regulator-name = "vreg_l2c_1p2";
231			regulator-min-microvolt = <1200000>;
232			regulator-max-microvolt = <1200000>;
233			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
234		};
235
236		vreg_l3c_0p92: ldo3 {
237			regulator-name = "vreg_l3c_0p92";
238			regulator-min-microvolt = <920000>;
239			regulator-max-microvolt = <920000>;
240			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
241		};
242
243		vreg_l4c_1p7: ldo4 {
244			regulator-name = "vreg_l4c_1p7";
245			regulator-min-microvolt = <1704000>;
246			regulator-max-microvolt = <2928000>;
247			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
248		};
249
250		vreg_l5c_1p8: ldo5 {
251			regulator-name = "vreg_l5c_1p8";
252			regulator-min-microvolt = <1800000>;
253			regulator-max-microvolt = <2928000>;
254			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
255		};
256
257		vreg_l6c_2p9: ldo6 {
258			regulator-name = "vreg_l6c_2p9";
259			regulator-min-microvolt = <1800000>;
260			regulator-max-microvolt = <2960000>;
261			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
262		};
263
264		vreg_l7c_cam_vcm0_2p85: ldo7 {
265			regulator-name = "vreg_l7c_cam_vcm0_2p85";
266			regulator-min-microvolt = <2856000>;
267			regulator-max-microvolt = <3104000>;
268			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
269		};
270
271		vreg_l8c_1p8: ldo8 {
272			regulator-name = "vreg_l8c_1p8";
273			regulator-min-microvolt = <1800000>;
274			regulator-max-microvolt = <1800000>;
275			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
276		};
277
278		vreg_l9c_2p9: ldo9 {
279			regulator-name = "vreg_l9c_2p9";
280			regulator-min-microvolt = <2704000>;
281			regulator-max-microvolt = <2960000>;
282			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
283		};
284
285		vreg_l10c_3p0: ldo10 {
286			regulator-name = "vreg_l10c_3p0";
287			regulator-min-microvolt = <3000000>;
288			regulator-max-microvolt = <3000000>;
289			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
290		};
291
292		vreg_l11c_3p3: ldo11 {
293			regulator-name = "vreg_l11c_3p3";
294			regulator-min-microvolt = <3000000>;
295			regulator-max-microvolt = <3312000>;
296			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
297		};
298	};
299
300	pm8009-rpmh-regulators {
301		compatible = "qcom,pm8009-rpmh-regulators";
302		qcom,pmic-id = "f";
303
304		vdd-s1-supply = <&vph_pwr>;
305		vdd-s2-supply = <&vreg_bob>;
306		vdd-l2-supply = <&vreg_s8c_1p3>;
307		vdd-l5-l6-supply = <&vreg_bob>;
308		vdd-l7-supply = <&vreg_s4a_1p8>;
309
310		vreg_l1f_cam_dvdd1_1p1: ldo1 {
311			regulator-name = "vreg_l1f_cam_dvdd1_1p1";
312			regulator-min-microvolt = <1104000>;
313			regulator-max-microvolt = <1104000>;
314			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
315		};
316
317		vreg_l2f_cam_dvdd0_1p2: ldo2 {
318			regulator-name = "vreg_l2f_cam_dvdd0_1p2";
319			regulator-min-microvolt = <1200000>;
320			regulator-max-microvolt = <1200000>;
321			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
322		};
323
324		vreg_l3f_cam_dvdd2_1p05: ldo3 {
325			regulator-name = "vreg_l3f_cam_dvdd2_1p05";
326			regulator-min-microvolt = <1056000>;
327			regulator-max-microvolt = <1056000>;
328			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
329		};
330
331		vreg_l5f_cam_avdd0_2p85: ldo5 {
332			regulator-name = "vreg_l5f_cam_avdd0_2p85";
333			regulator-min-microvolt = <2800000>;
334			regulator-max-microvolt = <2800000>;
335			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
336		};
337
338		vreg_l6f_cam_avdd1_2p85: ldo6 {
339			regulator-name = "vreg_l6f_cam_avdd1_2p85";
340			regulator-min-microvolt = <2856000>;
341			regulator-max-microvolt = <2856000>;
342			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
343		};
344
345		vreg_l7f_1p8: ldo7 {
346			regulator-name = "vreg_l7f_1p8";
347			regulator-min-microvolt = <1800000>;
348			regulator-max-microvolt = <1800000>;
349			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
350		};
351	};
352};
353
354&qupv3_id_1 {
355	status = "okay";
356};
357
358&uart2 {
359	status = "okay";
360};
361
362&ufs_mem_hc {
363	status = "okay";
364
365	vcc-supply = <&vreg_l17a_3p0>;
366	vcc-max-microamp = <750000>;
367	vccq-supply = <&vreg_l6a_1p2>;
368	vccq-max-microamp = <700000>;
369	vccq2-supply = <&vreg_s4a_1p8>;
370	vccq2-max-microamp = <750000>;
371};
372
373&ufs_mem_phy {
374	status = "okay";
375
376	vdda-phy-supply = <&vreg_l5a_0p875>;
377	vdda-max-microamp = <90200>;
378	vdda-pll-supply = <&vreg_l9a_1p2>;
379	vdda-pll-max-microamp = <19000>;
380};
381