Commit | Line | Data |
---|---|---|
16e8e807 SG |
1 | // SPDX-License-Identifier: GPL-2.0-only |
2 | ||
3 | /dts-v1/; | |
4 | ||
bfe9d754 | 5 | #include "msm8916-pm8916.dtsi" |
16e8e807 | 6 | #include <dt-bindings/gpio/gpio.h> |
3ba8bbc4 | 7 | #include <dt-bindings/input/input.h> |
6eb81528 | 8 | #include <dt-bindings/interrupt-controller/irq.h> |
6b4ad4be | 9 | #include <dt-bindings/leds/common.h> |
16e8e807 SG |
10 | |
11 | / { | |
12 | model = "Longcheer L8150"; | |
13 | compatible = "longcheer,l8150", "qcom,msm8916-v1-qrd/9-v1", "qcom,msm8916"; | |
eaa744b1 | 14 | chassis-type = "handset"; |
16e8e807 SG |
15 | |
16 | aliases { | |
17 | serial0 = &blsp1_uart2; | |
18 | }; | |
19 | ||
20 | chosen { | |
21 | stdout-path = "serial0"; | |
22 | }; | |
23 | ||
b0e1600d NT |
24 | reserved-memory { |
25 | // wcnss.mdt is not relocatable, so it must be loaded at 0x8b600000 | |
26 | /delete-node/ wcnss@89300000; | |
27 | ||
28 | wcnss_mem: wcnss@8b600000 { | |
29 | reg = <0x0 0x8b600000 0x0 0x600000>; | |
30 | no-map; | |
31 | }; | |
32 | }; | |
33 | ||
3ba8bbc4 NT |
34 | gpio-keys { |
35 | compatible = "gpio-keys"; | |
36 | ||
37 | pinctrl-names = "default"; | |
38 | pinctrl-0 = <&gpio_keys_default>; | |
39 | ||
40 | label = "GPIO Buttons"; | |
41 | ||
42 | volume-up { | |
43 | label = "Volume Up"; | |
44 | gpios = <&msmgpio 107 GPIO_ACTIVE_LOW>; | |
45 | linux,code = <KEY_VOLUMEUP>; | |
46 | }; | |
47 | }; | |
6eb81528 NT |
48 | |
49 | reg_ctp: regulator-ctp { | |
50 | compatible = "regulator-fixed"; | |
51 | regulator-name = "ctp"; | |
52 | ||
53 | regulator-min-microvolt = <2800000>; | |
54 | regulator-max-microvolt = <2800000>; | |
55 | ||
56 | gpio = <&msmgpio 17 GPIO_ACTIVE_HIGH>; | |
57 | enable-active-high; | |
58 | ||
59 | pinctrl-names = "default"; | |
60 | pinctrl-0 = <&ctp_pwr_en_default>; | |
61 | }; | |
6b4ad4be NT |
62 | |
63 | flash-led-controller { | |
64 | compatible = "sgmicro,sgm3140"; | |
65 | flash-gpios = <&msmgpio 31 GPIO_ACTIVE_HIGH>; | |
66 | enable-gpios = <&msmgpio 32 GPIO_ACTIVE_HIGH>; | |
67 | ||
68 | pinctrl-names = "default"; | |
69 | pinctrl-0 = <&camera_flash_default>; | |
70 | ||
71 | flash_led: led { | |
72 | function = LED_FUNCTION_FLASH; | |
73 | color = <LED_COLOR_ID_WHITE>; | |
74 | flash-max-timeout-us = <250000>; | |
75 | }; | |
76 | }; | |
6eb81528 NT |
77 | }; |
78 | ||
38260b9e NT |
79 | &blsp_i2c1 { |
80 | status = "okay"; | |
81 | ||
82 | led-controller@45 { | |
83 | compatible = "awinic,aw2013"; | |
84 | reg = <0x45>; | |
85 | #address-cells = <1>; | |
86 | #size-cells = <0>; | |
87 | ||
88 | vcc-supply = <&pm8916_l17>; | |
89 | ||
90 | led@0 { | |
91 | reg = <0>; | |
92 | led-max-microamp = <5000>; | |
93 | function = LED_FUNCTION_INDICATOR; | |
94 | color = <LED_COLOR_ID_RED>; | |
95 | }; | |
96 | ||
97 | led@1 { | |
98 | reg = <1>; | |
99 | led-max-microamp = <5000>; | |
100 | function = LED_FUNCTION_INDICATOR; | |
101 | color = <LED_COLOR_ID_GREEN>; | |
102 | }; | |
103 | ||
104 | led@2 { | |
105 | reg = <2>; | |
106 | led-max-microamp = <5000>; | |
107 | function = LED_FUNCTION_INDICATOR; | |
108 | color = <LED_COLOR_ID_BLUE>; | |
109 | }; | |
110 | }; | |
111 | }; | |
112 | ||
6bd2cae7 NT |
113 | &blsp_i2c2 { |
114 | status = "okay"; | |
115 | ||
116 | accelerometer@10 { | |
51c7786f | 117 | compatible = "bosch,bmc156_accel"; |
6bd2cae7 NT |
118 | reg = <0x10>; |
119 | ||
51c7786f SG |
120 | /* |
121 | * For some reason the interrupt line is usually not connected | |
122 | * to the BMC156. However, there are two pads next to the chip | |
123 | * that can be shorted to make it work if needed. | |
124 | * | |
125 | * interrupt-parent = <&msmgpio>; | |
126 | * interrupts = <116 IRQ_TYPE_EDGE_RISING>; | |
127 | */ | |
128 | ||
129 | pinctrl-names = "default"; | |
130 | pinctrl-0 = <&accel_int_default>; | |
131 | ||
6bd2cae7 NT |
132 | vdd-supply = <&pm8916_l17>; |
133 | vddio-supply = <&pm8916_l6>; | |
134 | ||
135 | mount-matrix = "0", "1", "0", | |
136 | "-1", "0", "0", | |
137 | "0", "0", "1"; | |
138 | }; | |
139 | ||
140 | magnetometer@12 { | |
51c7786f | 141 | compatible = "bosch,bmc156_magn"; |
6bd2cae7 NT |
142 | reg = <0x12>; |
143 | ||
51c7786f SG |
144 | interrupt-parent = <&msmgpio>; |
145 | interrupts = <113 IRQ_TYPE_EDGE_RISING>; | |
146 | ||
147 | pinctrl-names = "default"; | |
148 | pinctrl-0 = <&magn_int_default>; | |
149 | ||
6bd2cae7 NT |
150 | vdd-supply = <&pm8916_l17>; |
151 | vddio-supply = <&pm8916_l6>; | |
152 | }; | |
153 | ||
3016af34 NT |
154 | light-sensor@23 { |
155 | compatible = "liteon,ltr559"; | |
156 | reg = <0x23>; | |
157 | proximity-near-level = <75>; | |
158 | ||
159 | interrupt-parent = <&msmgpio>; | |
160 | interrupts = <115 IRQ_TYPE_EDGE_FALLING>; | |
161 | ||
162 | pinctrl-names = "default"; | |
163 | pinctrl-0 = <&light_int_default>; | |
164 | ||
165 | vdd-supply = <&pm8916_l17>; | |
166 | vio-supply = <&pm8916_l6>; | |
167 | }; | |
168 | ||
6bd2cae7 NT |
169 | gyroscope@68 { |
170 | compatible = "bosch,bmg160"; | |
171 | reg = <0x68>; | |
172 | ||
173 | interrupt-parent = <&msmgpio>; | |
51c7786f SG |
174 | interrupts = <23 IRQ_TYPE_EDGE_RISING>, |
175 | <22 IRQ_TYPE_EDGE_RISING>; | |
6bd2cae7 NT |
176 | |
177 | pinctrl-names = "default"; | |
178 | pinctrl-0 = <&gyro_int_default>; | |
179 | ||
180 | vdd-supply = <&pm8916_l17>; | |
181 | vddio-supply = <&pm8916_l6>; | |
182 | }; | |
183 | }; | |
184 | ||
6eb81528 NT |
185 | &blsp_i2c5 { |
186 | status = "okay"; | |
187 | ||
188 | rmi4@20 { | |
189 | compatible = "syna,rmi4-i2c"; | |
190 | reg = <0x20>; | |
191 | #address-cells = <1>; | |
192 | #size-cells = <0>; | |
193 | ||
194 | interrupt-parent = <&msmgpio>; | |
195 | interrupts = <13 IRQ_TYPE_EDGE_FALLING>; | |
196 | ||
197 | vdd-supply = <®_ctp>; | |
198 | vio-supply = <&pm8916_l6>; | |
199 | ||
200 | pinctrl-names = "default"; | |
201 | pinctrl-0 = <&tp_int_default>; | |
202 | ||
203 | syna,startup-delay-ms = <10>; | |
204 | ||
205 | rmi4-f01@1 { | |
206 | reg = <0x1>; | |
207 | syna,nosleep-mode = <1>; // Allow sleeping | |
208 | }; | |
209 | ||
210 | rmi4-f12@12 { | |
211 | reg = <0x12>; | |
212 | syna,sensor-type = <1>; // Touchscreen | |
213 | }; | |
214 | }; | |
16e8e807 SG |
215 | }; |
216 | ||
e2f6482a SG |
217 | &blsp1_uart2 { |
218 | status = "okay"; | |
e2f6482a SG |
219 | }; |
220 | ||
4eb7b63d SG |
221 | &pm8916_resin { |
222 | status = "okay"; | |
223 | linux,code = <KEY_VOLUMEDOWN>; | |
224 | }; | |
225 | ||
b30cad26 SG |
226 | &pm8916_usbin { |
227 | status = "okay"; | |
228 | }; | |
229 | ||
0af8bbdb NT |
230 | &pm8916_vib { |
231 | status = "okay"; | |
232 | }; | |
233 | ||
e2f6482a SG |
234 | &pronto { |
235 | status = "okay"; | |
236 | }; | |
237 | ||
238 | &sdhc_1 { | |
239 | status = "okay"; | |
240 | ||
e2f6482a SG |
241 | pinctrl-names = "default", "sleep"; |
242 | pinctrl-0 = <&sdc1_clk_on &sdc1_cmd_on &sdc1_data_on>; | |
243 | pinctrl-1 = <&sdc1_clk_off &sdc1_cmd_off &sdc1_data_off>; | |
244 | }; | |
245 | ||
246 | &sdhc_2 { | |
247 | status = "okay"; | |
248 | ||
e2f6482a SG |
249 | pinctrl-names = "default", "sleep"; |
250 | pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on>; | |
251 | pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off>; | |
252 | ||
253 | non-removable; | |
254 | }; | |
255 | ||
e2f6482a SG |
256 | &usb { |
257 | status = "okay"; | |
258 | dr_mode = "peripheral"; | |
b30cad26 | 259 | extcon = <&pm8916_usbin>; |
e2f6482a SG |
260 | }; |
261 | ||
262 | &usb_hs_phy { | |
b30cad26 | 263 | extcon = <&pm8916_usbin>; |
e2f6482a SG |
264 | }; |
265 | ||
16e8e807 SG |
266 | &smd_rpm_regulators { |
267 | vdd_l1_l2_l3-supply = <&pm8916_s3>; | |
268 | vdd_l4_l5_l6-supply = <&pm8916_s4>; | |
269 | vdd_l7-supply = <&pm8916_s4>; | |
270 | ||
16e8e807 SG |
271 | s3 { |
272 | regulator-min-microvolt = <1200000>; | |
273 | regulator-max-microvolt = <1300000>; | |
274 | }; | |
275 | ||
276 | s4 { | |
277 | regulator-min-microvolt = <1800000>; | |
278 | regulator-max-microvolt = <2100000>; | |
279 | }; | |
280 | ||
281 | l1 { | |
282 | regulator-min-microvolt = <1225000>; | |
283 | regulator-max-microvolt = <1225000>; | |
284 | }; | |
285 | ||
286 | l2 { | |
287 | regulator-min-microvolt = <1200000>; | |
288 | regulator-max-microvolt = <1200000>; | |
289 | }; | |
290 | ||
16e8e807 SG |
291 | l4 { |
292 | regulator-min-microvolt = <2050000>; | |
293 | regulator-max-microvolt = <2050000>; | |
294 | }; | |
295 | ||
296 | l5 { | |
297 | regulator-min-microvolt = <1800000>; | |
298 | regulator-max-microvolt = <1800000>; | |
299 | }; | |
300 | ||
301 | l6 { | |
302 | regulator-min-microvolt = <1800000>; | |
303 | regulator-max-microvolt = <1800000>; | |
304 | }; | |
305 | ||
306 | l7 { | |
307 | regulator-min-microvolt = <1800000>; | |
308 | regulator-max-microvolt = <1800000>; | |
309 | }; | |
310 | ||
311 | l8 { | |
312 | regulator-min-microvolt = <2850000>; | |
313 | regulator-max-microvolt = <2900000>; | |
314 | }; | |
315 | ||
316 | l9 { | |
317 | regulator-min-microvolt = <3300000>; | |
318 | regulator-max-microvolt = <3300000>; | |
319 | }; | |
320 | ||
321 | l10 { | |
322 | regulator-min-microvolt = <2700000>; | |
323 | regulator-max-microvolt = <2800000>; | |
324 | }; | |
325 | ||
326 | l11 { | |
327 | regulator-min-microvolt = <1800000>; | |
328 | regulator-max-microvolt = <2950000>; | |
329 | regulator-allow-set-load; | |
330 | regulator-system-load = <200000>; | |
331 | }; | |
332 | ||
333 | l12 { | |
334 | regulator-min-microvolt = <1800000>; | |
335 | regulator-max-microvolt = <2950000>; | |
336 | }; | |
337 | ||
338 | l13 { | |
339 | regulator-min-microvolt = <3075000>; | |
340 | regulator-max-microvolt = <3075000>; | |
341 | }; | |
342 | ||
343 | l14 { | |
344 | regulator-min-microvolt = <1800000>; | |
345 | regulator-max-microvolt = <3300000>; | |
346 | }; | |
347 | ||
348 | l15 { | |
349 | regulator-min-microvolt = <1800000>; | |
350 | regulator-max-microvolt = <3300000>; | |
351 | }; | |
352 | ||
353 | l16 { | |
354 | regulator-min-microvolt = <1800000>; | |
355 | regulator-max-microvolt = <3300000>; | |
356 | }; | |
357 | ||
358 | l17 { | |
359 | regulator-min-microvolt = <2850000>; | |
360 | regulator-max-microvolt = <2850000>; | |
361 | }; | |
362 | ||
363 | l18 { | |
364 | regulator-min-microvolt = <2700000>; | |
365 | regulator-max-microvolt = <2700000>; | |
366 | }; | |
367 | }; | |
f7f394f0 SG |
368 | |
369 | &msmgpio { | |
51c7786f SG |
370 | accel_int_default: accel-int-default { |
371 | pins = "gpio116"; | |
372 | function = "gpio"; | |
373 | ||
374 | drive-strength = <2>; | |
375 | bias-disable; | |
376 | }; | |
377 | ||
6b4ad4be NT |
378 | camera_flash_default: camera-flash-default { |
379 | pins = "gpio31", "gpio32"; | |
380 | function = "gpio"; | |
381 | ||
382 | drive-strength = <2>; | |
383 | bias-disable; | |
384 | }; | |
385 | ||
6eb81528 NT |
386 | ctp_pwr_en_default: ctp-pwr-en-default { |
387 | pins = "gpio17"; | |
388 | function = "gpio"; | |
389 | ||
390 | drive-strength = <2>; | |
391 | bias-disable; | |
392 | }; | |
393 | ||
f7f394f0 | 394 | gpio_keys_default: gpio-keys-default { |
6554a295 SG |
395 | pins = "gpio107"; |
396 | function = "gpio"; | |
397 | ||
398 | drive-strength = <2>; | |
399 | bias-pull-up; | |
f7f394f0 SG |
400 | }; |
401 | ||
6bd2cae7 | 402 | gyro_int_default: gyro-int-default { |
51c7786f SG |
403 | pins = "gpio22", "gpio23"; |
404 | function = "gpio"; | |
405 | ||
406 | drive-strength = <2>; | |
407 | bias-disable; | |
408 | }; | |
409 | ||
3016af34 NT |
410 | light_int_default: light-int-default { |
411 | pins = "gpio115"; | |
412 | function = "gpio"; | |
413 | ||
414 | drive-strength = <2>; | |
415 | bias-disable; | |
416 | }; | |
417 | ||
51c7786f SG |
418 | magn_int_default: magn-int-default { |
419 | pins = "gpio113"; | |
6bd2cae7 NT |
420 | function = "gpio"; |
421 | ||
422 | drive-strength = <2>; | |
423 | bias-disable; | |
424 | }; | |
425 | ||
6eb81528 NT |
426 | tp_int_default: tp-int-default { |
427 | pins = "gpio13"; | |
428 | function = "gpio"; | |
429 | ||
430 | drive-strength = <2>; | |
431 | bias-disable; | |
432 | }; | |
f7f394f0 | 433 | }; |