1// SPDX-License-Identifier: GPL-2.0-only
2
3/dts-v1/;
4
5#include "msm8916.dtsi"
6#include "pm8916.dtsi"
7#include <dt-bindings/gpio/gpio.h>
8
9/ {
10	model = "Longcheer L8150";
11	compatible = "longcheer,l8150", "qcom,msm8916-v1-qrd/9-v1", "qcom,msm8916";
12
13	aliases {
14		serial0 = &blsp1_uart2;
15	};
16
17	chosen {
18		stdout-path = "serial0";
19	};
20
21	soc {
22		sdhci@7824000 {
23			status = "okay";
24
25			vmmc-supply = <&pm8916_l8>;
26			vqmmc-supply = <&pm8916_l5>;
27
28			pinctrl-names = "default", "sleep";
29			pinctrl-0 = <&sdc1_clk_on &sdc1_cmd_on &sdc1_data_on>;
30			pinctrl-1 = <&sdc1_clk_off &sdc1_cmd_off &sdc1_data_off>;
31		};
32
33		sdhci@7864000 {
34			status = "okay";
35
36			vmmc-supply = <&pm8916_l11>;
37			vqmmc-supply = <&pm8916_l12>;
38
39			pinctrl-names = "default", "sleep";
40			pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on>;
41			pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off>;
42
43			non-removable;
44		};
45
46		serial@78b0000 {
47			status = "okay";
48			pinctrl-names = "default", "sleep";
49			pinctrl-0 = <&blsp1_uart2_default>;
50			pinctrl-1 = <&blsp1_uart2_sleep>;
51		};
52
53		usb@78d9000 {
54			status = "okay";
55			dr_mode = "peripheral";
56			extcon = <&usb_vbus>;
57
58			hnp-disable;
59			srp-disable;
60			adp-disable;
61
62			ulpi {
63				phy {
64					extcon = <&usb_vbus>;
65					v1p8-supply = <&pm8916_l7>;
66					v3p3-supply = <&pm8916_l13>;
67				};
68			};
69		};
70
71		/*
72		 * Attempting to enable these devices causes a "synchronous
73		 * external abort". Suspected cause is that the debug power
74		 * domain is not enabled by default on this device.
75		 * Disable these devices for now to avoid the crash.
76		 *
77		 * See: https://lore.kernel.org/linux-arm-msm/20190618202623.GA53651@gerhold.net/
78		 */
79		tpiu@820000 { status = "disabled"; };
80		funnel@821000 { status = "disabled"; };
81		replicator@824000 { status = "disabled"; };
82		etf@825000 { status = "disabled"; };
83		etr@826000 { status = "disabled"; };
84		funnel@841000 { status = "disabled"; };
85		debug@850000 { status = "disabled"; };
86		debug@852000 { status = "disabled"; };
87		debug@854000 { status = "disabled"; };
88		debug@856000 { status = "disabled"; };
89		etm@85c000 { status = "disabled"; };
90		etm@85d000 { status = "disabled"; };
91		etm@85e000 { status = "disabled"; };
92		etm@85f000 { status = "disabled"; };
93	};
94
95	// FIXME: Use extcon device provided by charger driver when available
96	usb_vbus: usb-vbus {
97		compatible = "linux,extcon-usb-gpio";
98		vbus-gpio = <&msmgpio 62 GPIO_ACTIVE_HIGH>;
99		pinctrl-names = "default";
100		pinctrl-0 = <&usb_vbus_default>;
101	};
102};
103
104&msmgpio {
105	usb_vbus_default: usb-vbus-default {
106		pinmux {
107			function = "gpio";
108			pins = "gpio62";
109		};
110		pinconf {
111			pins = "gpio62";
112			bias-pull-up;
113		};
114	};
115};
116
117&smd_rpm_regulators {
118	vdd_l1_l2_l3-supply = <&pm8916_s3>;
119	vdd_l4_l5_l6-supply = <&pm8916_s4>;
120	vdd_l7-supply = <&pm8916_s4>;
121
122	s1 {
123		regulator-min-microvolt = <500000>;
124		regulator-max-microvolt = <1300000>;
125	};
126
127	s3 {
128		regulator-min-microvolt = <1200000>;
129		regulator-max-microvolt = <1300000>;
130	};
131
132	s4 {
133		regulator-min-microvolt = <1800000>;
134		regulator-max-microvolt = <2100000>;
135	};
136
137	l1 {
138		regulator-min-microvolt = <1225000>;
139		regulator-max-microvolt = <1225000>;
140	};
141
142	l2 {
143		regulator-min-microvolt = <1200000>;
144		regulator-max-microvolt = <1200000>;
145	};
146
147	l3 {
148		regulator-min-microvolt = <500000>;
149		regulator-max-microvolt = <1287500>;
150	};
151
152	l4 {
153		regulator-min-microvolt = <2050000>;
154		regulator-max-microvolt = <2050000>;
155	};
156
157	l5 {
158		regulator-min-microvolt = <1800000>;
159		regulator-max-microvolt = <1800000>;
160	};
161
162	l6 {
163		regulator-min-microvolt = <1800000>;
164		regulator-max-microvolt = <1800000>;
165	};
166
167	l7 {
168		regulator-min-microvolt = <1800000>;
169		regulator-max-microvolt = <1800000>;
170	};
171
172	l8 {
173		regulator-min-microvolt = <2850000>;
174		regulator-max-microvolt = <2900000>;
175	};
176
177	l9 {
178		regulator-min-microvolt = <3300000>;
179		regulator-max-microvolt = <3300000>;
180	};
181
182	l10 {
183		regulator-min-microvolt = <2700000>;
184		regulator-max-microvolt = <2800000>;
185	};
186
187	l11 {
188		regulator-min-microvolt = <1800000>;
189		regulator-max-microvolt = <2950000>;
190		regulator-allow-set-load;
191		regulator-system-load = <200000>;
192	};
193
194	l12 {
195		regulator-min-microvolt = <1800000>;
196		regulator-max-microvolt = <2950000>;
197	};
198
199	l13 {
200		regulator-min-microvolt = <3075000>;
201		regulator-max-microvolt = <3075000>;
202	};
203
204	l14 {
205		regulator-min-microvolt = <1800000>;
206		regulator-max-microvolt = <3300000>;
207	};
208
209	l15 {
210		regulator-min-microvolt = <1800000>;
211		regulator-max-microvolt = <3300000>;
212	};
213
214	l16 {
215		regulator-min-microvolt = <1800000>;
216		regulator-max-microvolt = <3300000>;
217	};
218
219	l17 {
220		regulator-min-microvolt = <2850000>;
221		regulator-max-microvolt = <2850000>;
222	};
223
224	l18 {
225		regulator-min-microvolt = <2700000>;
226		regulator-max-microvolt = <2700000>;
227	};
228};
229