This repository has been archived by the owner on Jul 11, 2023. It is now read-only.
forked from MiCode/Xiaomi_Kernel_OpenSource
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdavinci-sm8150.dtsi
executable file
·584 lines (519 loc) · 12.7 KB
/
davinci-sm8150.dtsi
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
/*
this file is for attribution only of davinci
And public attribution of xiaomi platforms(like F1 and so and)
*/
#include "davinci-pinctrl.dtsi"
#include "xiaomi-sm8150-common.dtsi"
#include "davinci-sm8150-camera-sensor.dtsi"
&qupv3_se4_i2c {
#include "smb1355.dtsi"
};
&vendor {
mtp_batterydata: qcom,battery-data {
qcom,batt-id-range-pct = <15>;
#include "fg-gen4-batterydata-alium-3600mah_F10.dtsi"
};
};
&pm8150b_fg {
qcom,battery-data = <&mtp_batterydata>;
qcom,rapid-soc-dec-en;
qcom,fg-sys-term-current = <(-300)>;
qcom,fg-cutoff-voltage = <3400>;
qcom,fg-cutoff-current = <200>;
qcom,fg-empty-voltage = <3100>;
qcom,fg-force-load-profile;
/* ESR fast calibration */
qcom,fg-esr-timer-chg-fast = <0 7>;
qcom,fg-esr-timer-dischg-fast = <0 7>;
qcom,fg-esr-timer-chg-slow = <0 96>;
qcom,fg-esr-timer-dischg-slow = <0 96>;
qcom,fg-esr-cal-soc-thresh = <26 230>;
qcom,fg-esr-cal-temp-thresh = <10 40>;
};
&pm8150b_charger {
qcom,sec-charger-config = <2>;
qcom,usb-icl-ua = <2800000>;
qcom,fcc-max-ua = <3000000>;
qcom,fv-max-uv = <4400000>;
qcom,auto-recharge-soc = <99>;
qcom,chg-term-src = <1>;
qcom,chg-term-current-ma = <(-200)>;
qcom,thermal-mitigation = <3000000 2800000 2600000 2400000 2200000 2100000 2000000
1800000 1600000 1500000 1400000 1200000 1000000 900000
800000 500000>;
qcom,thermal-mitigation-icl
= <2800000 2700000 2600000 2400000 2200000 2100000 2000000
1800000 1700000 1700000 1600000 1500000 1400000 1300000
950000 750000>;
qcom,thermal-mitigation-dcp
= <1800000 1800000 1800000 1800000 1800000 1800000 1800000
1800000 1800000 1700000 1600000 1400000 1200000 1100000
1100000 1000000>;
qcom,thermal-mitigation-qc2
= <1500000 1500000 1500000 1500000 1450000 1400000 1350000
1300000 1150000 1100000 1000000 900000 850000 750000
650000 500000>;
qcom,thermal-fcc-qc3-normal
= <3200000 3000000 2800000 2600000 2500000 2400000 2300000
2200000 2100000 1800000 1600000 1400000 1200000 1000000
750000 750000>;
qcom,thermal-fcc-qc3-cp
= <4800000 4700000 4600000 4500000 4400000 4200000 3800000
3600000 3200000 2800000 2400000 2200000 2000000 1300000
750000 700000>;
qcom,thermal-mitigation-pd-base
= <3000000 2800000 2600000 2500000 2300000 2200000 2100000
1900000 1800000 1600000 1500000 1400000 1200000 1000000
950000 500000>;
qcom,thermal-fcc-pps-cp
= <4800000 4700000 4600000 4500000 4400000 4200000 3800000
3600000 3200000 2800000 2400000 2200000 2000000 1300000
750000 750000>;
qcom,thermal-mitigation-dc
= <2200000 2000000 1800000 1600000 1400000 1200000 1100000
1000000 900000 800000 700000 600000 500000 400000
300000 200000>;
io-channels = <&pm8150b_vadc ADC_MID_CHG_DIV6>,
<&pm8150b_vadc ADC_USB_IN_V_16>,
<&pm8150b_vadc ADC_USB_IN_I>,
<&pm8150b_vadc ADC_SBUx>,
<&pm8150b_vadc ADC_VPH_PWR>,
<&pm8150b_vadc ADC_CHG_TEMP>;
io-channel-names = "mid_voltage",
"usb_in_voltage",
"usb_in_current",
"sbux_res",
"vph_voltage",
"chg_temp";
qcom,battery-data = <&mtp_batterydata>;
dpdm-supply = <&usb2_phy0>;
qcom,sw-jeita-enable;
};
&qupv3_se9_i2c {
status = "ok";
tfa98xx@34 {
compatible = "nxp,tfa98xx";
reset-gpio = <&tlmm 59 0>;
irq-gpio = <&tlmm 60 0>;
interrupt-parent = <&tlmm>;
interrupts = <60 0>;
interrupt-names = "smartpa_irq";
pinctrl-names = "default", "sleep";
pinctrl-0 = <&smartpa_int_active &smartpa_enable_active>;
pinctrl-1 = <&smartpa_int_suspend &smartpa_enable_suspend>;
reg = <0x34>;
status = "ok";
};
};
&qupv3_se4_i2c {
status = "ok";
fsa4480@42 {
status = "disabled";
};
};
&smb1355 {
pinctrl-names = "default";
pinctrl-0 = <&smb_stat_default>;
status = "ok";
};
&smb1355_charger {
io-channels = <&pm8150b_vadc ADC_AMUX_THM2>;
io-channel-names = "charger_temp";
status = "ok";
};
&usb0 {
dwc3@a600000 {
usb-phy = <&usb2_phy0>, <&usb_nop_phy>;
maximum-speed = "high-speed";
};
};
&usb2_phy0 {
qcom,param-override-seq =
<0x85 0x70
0x2d 0x74>;
};
&usb_qmp_dp_phy {
status = "disabled";
};
&usb1 {
extcon = <&extcon_usb1>;
status = "disabled";
};
&usb2_phy1 {
status = "disabled";
};
&usb_qmp_phy {
status = "disabled";
};
&soc {
touch_vddio_vreg: touch_vddio_vreg {
compatible = "regulator-fixed";
regulator-name = "disp_vddio_vreg";
startup-delay-us = <4000>;
enable-active-high;
regulator-boot-on;
gpio = <&tlmm 99 0>;
};
vdd_boost_vreg: vdd_boost_vreg {
compatible = "regulator-fixed";
regulator-name = "vdd_boost_vreg";
startup-delay-us = <4000>;
enable-active-high;
regulator-always-on;
gpio = <&pm8150b_gpios 5 0>;
};
fp_vdd_vreg: fp_vdd_vreg {
compatible = "regulator-fixed";
regulator-name = "fp_vdd_vreg";
startup-delay-us = <4000>;
enable-active-high;
gpio = <&tlmm 125 0>;
regulator-always-on;
};
fingerprint_fpc {
status = "ok";
compatible = "fpc,fpc1020";
interrupt-parent = <&tlmm>;
interrupts = <118 0x0>;
fpc,gpio_irq = <&tlmm 118 0x0>;
/* fpc,enable-on-boot; */
/* fpc,enable-wakeup; */
pinctrl-names = "fpc1020_reset_reset",
"fpc1020_reset_active";
pinctrl-0 = <&msm_gpio_37>;
pinctrl-1 = <&msm_gpio_37_output_high>;
};
fingerprint_goodix {
compatible = "goodix,fingerprint";
goodix,gpio-reset = <&tlmm 37 0x0>;
goodix,gpio-irq = <&tlmm 118 0x0>;
fp-gpio-pwr = <&tlmm 125 0>;
status = "ok";
};
gpio_keys {
hall_key {
label = "hall_key";
gpios = <&tlmm 120 GPIO_ACTIVE_LOW>;
linux,input-type = <5>;
linux,code = <0>;
gpio-key,wakeup;
debounce-interval = <15>;
};
};
};
&qupv3_se19_i2c {
status = "ok";
novatek@62 {
compatible = "novatek,NVT-ts";
reg = <0x62>;
interrupt-parent = <&tlmm>;
interrupts = <122 0x2001>;
pinctrl-names = "pmx_ts_active", "pmx_ts_suspend";
pinctrl-0 = <&ts_active>;
pinctrl-1 = <&ts_int_suspend &ts_reset_suspend>;
avdd-supply = <&pm8150l_l1>;
novatek,vddio-reg-name = "avdd";
novatek,irq-gpio = <&tlmm 122 0x2001>;
novatek,reset-gpio = <&tlmm 54 0x00>;
novatek,reset-tddi = <&tlmm 6 0x00>;
novatek,config-array-size = <1>;
novatek,dump-click-count;
novatek,cfg_0 {
novatek,tp-vendor = <0x46>;
novatek,hw-version = <0x1>;
novatek,fw-name = "novatek_nt36672_f10.fw";
novatek,clicknum-file-name = "nvt+tianma";
};
};
};
&qupv3_se17_i2c {
status = "ok";
idtp9220: idtp9220@3b {
compatible = "idt,p9220";
reg = <0x3b>;
idt,irq = <&tlmm 114 0x00>;
idt,enable = <&tlmm 115 0x00>;
interrupt-parent = <&tlmm>;
interrupts = <114 0>;
interrupt-names = "idt_irq";
pinctrl-names = "idt_active", "idt_suspend";
pinctrl-0 = <&idt_int_active &idt_enable_active>;
pinctrl-1 = <&idt_int_suspend &idt_enable_suspend>;
};
};
&pm8150b_vadc {
vph_pwr {
reg = <ADC_VPH_PWR>;
label = "vph_pwr";
qcom,pre-scaling = <1 3>;
};
wp_therm {
reg = <ADC_AMUX_THM1_PU2>;
label = "wp_therm";
qcom,ratiometric;
qcom,hw-settle-time = <200>;
qcom,pre-scaling = <1 1>;
};
vcoin {
reg = <ADC_VCOIN>;
label = "vcoin";
qcom,pre-scaling = <1 3>;
};
conn_therm {
reg = <ADC_AMUX_THM3_PU2>;
label = "conn_therm";
qcom,ratiometric;
qcom,hw-settle-time = <200>;
qcom,pre-scaling = <1 1>;
};
chg_sbux {
reg = <ADC_SBUx>;
label = "chg_sbux";
qcom,pre-scaling = <1 3>;
};
mid_chg_div6 {
reg = <ADC_MID_CHG_DIV6>;
label = "chg_mid";
qcom,pre-scaling = <1 6>;
};
usb_in_i_uv {
reg = <ADC_USB_IN_I>;
label = "usb_in_i_uv";
qcom,pre-scaling = <1 1>;
};
usb_in_v_div_16 {
reg = <ADC_USB_IN_V_16>;
label = "usb_in_v_div_16";
qcom,pre-scaling = <1 16>;
};
};
&pm8150_vadc {
vph_pwr {
reg = <ADC_VPH_PWR>;
label = "vph_pwr";
qcom,pre-scaling = <1 3>;
};
vcoin {
reg = <ADC_VCOIN>;
label = "vcoin";
qcom,pre-scaling = <1 3>;
};
xo_therm {
reg = <ADC_XO_THERM_PU2>;
label = "xo_therm";
qcom,ratiometric;
qcom,hw-settle-time = <200>;
qcom,pre-scaling = <1 1>;
};
quiet_therm {
reg = <ADC_AMUX_THM1_PU2>;
label = "quiet_therm";
qcom,ratiometric;
qcom,hw-settle-time = <200>;
qcom,pre-scaling = <1 1>;
};
pa_therm0 {
reg = <ADC_AMUX_THM2_PU2>;
label = "pa_therm0";
qcom,ratiometric;
qcom,hw-settle-time = <200>;
qcom,pre-scaling = <1 1>;
};
};
&pm8150l_vadc {
vph_pwr {
reg = <ADC_VPH_PWR>;
label = "vph_pwr";
qcom,pre-scaling = <1 3>;
};
cam_therm0 {
reg = <ADC_AMUX_THM1_PU2>;
label = "camera_flash_therm";
qcom,ratiometric;
qcom,hw-settle-time = <200>;
qcom,pre-scaling = <1 1>;
};
cam_therm1 {
reg = <ADC_AMUX_THM2_PU2>;
label = "skin_msm_therm";
qcom,ratiometric;
qcom,hw-settle-time = <200>;
qcom,pre-scaling = <1 1>;
};
pa_therm1 {
reg = <ADC_AMUX_THM3_PU2>;
label = "pa_therm1";
qcom,ratiometric;
qcom,hw-settle-time = <200>;
qcom,pre-scaling = <1 1>;
};
};
&pm8150b_adc_tm {
wp_therm {
reg = <ADC_AMUX_THM1_PU2>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
};
};
&pm8150_adc_tm {
xo_therm {
reg = <ADC_XO_THERM_PU2>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
};
quiet_therm {
reg = <ADC_AMUX_THM1_PU2>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
};
pa_therm0 {
reg = <ADC_AMUX_THM2_PU2>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
};
};
&pm8150l_adc_tm {
cam_therm0 {
reg = <ADC_AMUX_THM1_PU2>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
};
cam_therm1 {
reg = <ADC_AMUX_THM2_PU2>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
};
pa_therm1 {
reg = <ADC_AMUX_THM3_PU2>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
};
};
&thermal_zones {
wp_therm {
polling-delay-passive = <0>;
polling-delay = <0>;
thermal-governor = "user_space";
thermal-sensors = <&pm8150b_adc_tm ADC_AMUX_THM1_PU2>;
trips {
active-config0 {
temperature = <125000>;
hysteresis = <1000>;
type = "passive";
};
};
};
xo_therm {
polling-delay-passive = <0>;
polling-delay = <0>;
thermal-governor = "user_space";
thermal-sensors = <&pm8150_adc_tm ADC_XO_THERM_PU2>;
trips {
active-config0 {
temperature = <125000>;
hysteresis = <1000>;
type = "passive";
};
};
};
quiet_therm {
polling-delay-passive = <0>;
polling-delay = <0>;
thermal-governor = "user_space";
thermal-sensors = <&pm8150_adc_tm ADC_AMUX_THM1_PU2>;
trips {
active-config0 {
temperature = <125000>;
hysteresis = <1000>;
type = "passive";
};
};
};
pa_therm0 {
polling-delay-passive = <0>;
polling-delay = <0>;
thermal-governor = "user_space";
thermal-sensors = <&pm8150_adc_tm ADC_AMUX_THM2_PU2>;
trips {
active-config0 {
temperature = <125000>;
hysteresis = <1000>;
type = "passive";
};
};
};
cam_therm0 {
polling-delay-passive = <0>;
polling-delay = <0>;
thermal-governor = "user_space";
thermal-sensors = <&pm8150l_adc_tm ADC_AMUX_THM1_PU2>;
trips {
active-config0 {
temperature = <125000>;
hysteresis = <1000>;
type = "passive";
};
};
};
cam_therm1 {
polling-delay-passive = <0>;
polling-delay = <0>;
thermal-governor = "user_space";
thermal-sensors = <&pm8150l_adc_tm ADC_AMUX_THM2_PU2>;
trips {
active-config0 {
temperature = <125000>;
hysteresis = <1000>;
type = "passive";
};
};
};
pa_therm1 {
polling-delay-passive = <0>;
polling-delay = <0>;
thermal-governor = "user_space";
thermal-sensors = <&pm8150l_adc_tm ADC_AMUX_THM3_PU2>;
trips {
active-config0 {
temperature = <125000>;
hysteresis = <1000>;
type = "passive";
};
};
};
};
&pm8150b_haptics {
qcom,vmax-mv = <2545>;
qcom,play-rate-us = <4878>;
qcom,lra-resonance-sig-shape = "sine";
qcom,lra-auto-resonance-mode = "qwd";
qcom,lra-allow-variable-play-rate;
};
&pm8150l_lpg {
qcom,lut-patterns = <0 10 20 30 40 50 60 70 80 90 100
90 80 70 60 50 40 30 20 10 0>;
};
&pwm_lpg1 {
qcom,lpg-chan-id = <1>;
qcom,ramp-step-ms = <100>;
qcom,ramp-pause-hi-count = <2>;
qcom,ramp-pause-lo-count = <2>;
qcom,ramp-low-index = <0>;
qcom,ramp-high-index = <20>;
qcom,ramp-from-low-to-high;
qcom,ramp-pattern-repeat;
};
&red_led {
label = "white";
};
&green_led {
status = "disabled";
};
&blue_led {
status = "disabled";
};
&pm8150l_wled {
qcom,string-cfg= <15>;// if use 2 string, the number is 3
qcom,leds-per-string = <5>;
status = "ok";
};