GNU Linux-libre 6.1.90-gnu
[releases.git] / arch / arm64 / boot / dts / qcom / msm8996-sony-xperia-tone.dtsi
1 // SPDX-License-Identifier: BSD-3-Clause
2 /*
3  * Copyright (c) 2021, AngeloGioacchino Del Regno
4  *                     <angelogioacchino.delregno@somainline.org>
5  * Copyright (c) 2021, Konrad Dybcio <konrad.dybcio@somainline.org>
6  */
7
8 #include "msm8996.dtsi"
9 #include "pm8994.dtsi"
10 #include "pmi8994.dtsi"
11 #include "pmi8996.dtsi"
12 #include <dt-bindings/input/input.h>
13 #include <dt-bindings/gpio/gpio.h>
14 #include <dt-bindings/pinctrl/qcom,pmic-gpio.h>
15 #include <dt-bindings/pinctrl/qcom,pmic-mpp.h>
16
17 /delete-node/ &adsp_mem;
18 /delete-node/ &slpi_mem;
19 /delete-node/ &venus_mem;
20 /delete-node/ &gpu_mem;
21
22 / {
23         qcom,msm-id = <246 0x30001>; /* MSM8996 V3.1 (Final) */
24         qcom,board-id = <8 0>;
25
26         chosen {
27                 /*
28                  * Due to an unknown-for-a-few-years regression,
29                  * SDHCI only works on MSM8996 in PIO (lame) mode.
30                  */
31                 bootargs = "sdhci.debug_quirks=0x40 sdhci.debug_quirks2=0x4 maxcpus=2";
32         };
33
34         reserved-memory {
35                 ramoops@a7f00000 {
36                         compatible = "ramoops";
37                         reg = <0 0xa7f00000 0 0x100000>;
38                         record-size = <0x20000>;
39                         console-size = <0x40000>;
40                         ftrace-size = <0x20000>;
41                         pmsg-size = <0x20000>;
42                         ecc-size = <16>;
43                 };
44
45                 adsp_mem: adsp@8ea00000 {
46                         reg = <0x0 0x8ea00000 0x0 0x1a00000>;
47                         no-map;
48                 };
49
50                 gpu_mem: gpu@90400000 {
51                         compatible = "shared-dma-pool";
52                         reg = <0x0 0x90400000 0x0 0x2000>;
53                         no-map;
54                 };
55
56                 slpi_mem: memory@90500000 {
57                         reg = <0 0x90500000 0 0xa00000>;
58                         no-map;
59                 };
60
61                 venus_mem: memory@90f00000 {
62                         reg = <0 0x90f00000 0 0x500000>;
63                         no-map;
64                 };
65         };
66
67         panel_tvdd: tvdd-regulator {
68                 compatible = "regulator-fixed";
69                 regulator-name = "panel_tvdd";
70                 gpio = <&tlmm 50 GPIO_ACTIVE_LOW>;
71                 pinctrl-0 = <&tp_vddio_en>;
72                 pinctrl-names = "default";
73         };
74
75         usb3_id: usb3-id {
76                 compatible = "linux,extcon-usb-gpio";
77                 id-gpio = <&tlmm 25 GPIO_ACTIVE_LOW>;
78                 pinctrl-names = "default";
79                 pinctrl-0 = <&usb_detect>;
80         };
81
82         vph_pwr: vph-pwr-regulator {
83                 compatible = "regulator-fixed";
84                 regulator-min-microvolt = <3700000>;
85                 regulator-max-microvolt = <3700000>;
86                 regulator-name = "vph_pwr";
87                 regulator-always-on;
88                 regulator-boot-on;
89         };
90
91         wlan_en: wlan-en-1-8v {
92                 compatible = "regulator-fixed";
93                 regulator-name = "wlan-en-regulator";
94                 regulator-min-microvolt = <1800000>;
95                 regulator-max-microvolt = <1800000>;
96                 gpio = <&tlmm 84 GPIO_ACTIVE_HIGH>;
97                 pinctrl-names = "default";
98                 pinctrl-0 = <&wl_reg_on>;
99
100                 /* WLAN card specific delay */
101                 startup-delay-us = <70000>;
102                 enable-active-high;
103         };
104 };
105
106 &blsp1_i2c3 {
107         status = "okay";
108         clock-frequency = <355000>;
109
110         tof_sensor: vl53l0x@29 {
111                 compatible = "st,vl53l0x";
112                 reg = <0x29>;
113         };
114 };
115
116 &blsp1_uart2 {
117         status = "okay";
118 };
119
120 &blsp2_i2c5 {
121         status = "okay";
122         clock-frequency = <355000>;
123
124         /* FUSB301 USB-C controller */
125 };
126
127 &blsp2_i2c6 {
128         status = "okay";
129         clock-frequency = <355000>;
130
131         synaptics@2c {
132                 compatible = "syna,rmi4-i2c";
133                 reg = <0x2c>;
134                 interrupt-parent = <&tlmm>;
135                 interrupts = <125 IRQ_TYPE_EDGE_FALLING>;
136                 vdd-supply = <&panel_tvdd>;
137
138                 syna,reset-delay-ms = <220>;
139                 syna,startup-delay-ms = <220>;
140                 #address-cells = <1>;
141                 #size-cells = <0>;
142
143                 rmi4-f01@1 {
144                         reg = <0x1>;
145                         syna,nosleep-mode = <1>;
146                 };
147
148                 rmi4-f11@11 {
149                         reg = <0x11>;
150                         syna,sensor-type = <1>;
151                 };
152         };
153 };
154
155 &blsp2_uart2 {
156         status = "okay";
157 };
158
159 &camera0_mclk {
160         drive-strength = <2>;
161         output-low;
162 };
163
164 &camera0_pwdn {
165         drive-strength = <2>;
166         output-low;
167 };
168
169 &camera0_rst {
170         pins = "gpio30";
171         drive-strength = <2>;
172         output-low;
173 };
174
175 &camera2_mclk {
176         drive-strength = <2>;
177         output-low;
178 };
179
180 &camera2_rst {
181         drive-strength = <2>;
182         output-low;
183 };
184
185 &hsusb_phy1 {
186         status = "okay";
187
188         vdd-supply = <&pm8994_l28>;
189         vdda-pll-supply = <&pm8994_l12>;
190         vdda-phy-dpdm-supply = <&pm8994_l24>;
191 };
192
193 &mmcc {
194         vdd-gfx-supply = <&vdd_gfx>;
195 };
196
197 &pcie0 {
198         status = "okay";
199         perst-gpios = <&tlmm 35 GPIO_ACTIVE_LOW>;
200         wake-gpios = <&tlmm 37 GPIO_ACTIVE_HIGH>;
201         vddpe-3v3-supply = <&wlan_en>;
202         vdda-supply = <&pm8994_l28>;
203 };
204
205 &pcie_phy {
206         status = "okay";
207
208         vdda-phy-supply = <&pm8994_l28>;
209         vdda-pll-supply = <&pm8994_l12>;
210 };
211
212 &pm8994_gpios {
213         pinctrl-names = "default";
214         pinctrl-0 = <&pm8994_gpios_defaults>;
215         gpio-line-names =
216                 "NC",
217                 "VOL_DOWN_N",
218                 "VOL_UP_N",
219                 "SNAPSHOT_N",
220                 "FOCUS_N",
221                 "NC",
222                 "NFC_VEN",
223                 "NC",
224                 "NC",
225                 "NC",
226                 "NC",
227                 "NC",
228                 "EAR_EN",
229                 "NC",
230                 "PM_DIVCLK1",
231                 "PMI_CLK",
232                 "NC",
233                 "WL_SLEEP_CLK",
234                 "NC",
235                 "PMIC_SPON",
236                 "UIM_BATT_ALARM",
237                 "PMK_SLEEP_CLK";
238
239         /*
240          * We don't yet know for sure which GPIOs are of our interest, but what
241          * we do know is that if a vendor sets the pins to a non-default state, there's
242          * probably a reason for it, and just to be on the safe side, we follow suit.
243          */
244         pm8994_gpios_defaults: pm8994-gpios-default-state {
245                 pm8994-gpio1-nc-pins {
246                         pins = "gpio1";
247                         function = PMIC_GPIO_FUNC_NORMAL;
248                         drive-push-pull;
249                         bias-high-impedance;
250                 };
251
252                 vol-down-n-pins {
253                         pins = "gpio2";
254                         function = PMIC_GPIO_FUNC_NORMAL;
255                         drive-push-pull;
256                         input-enable;
257                         bias-pull-up;
258                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
259                         power-source = <PM8994_GPIO_S4>;
260                 };
261
262                 vol-up-n-pins {
263                         pins = "gpio3";
264                         function = PMIC_GPIO_FUNC_NORMAL;
265                         drive-push-pull;
266                         input-enable;
267                         bias-pull-up;
268                         power-source = <PM8994_GPIO_S4>;
269                 };
270
271                 camera-snapshot-n-pins {
272                         pins = "gpio4";
273                         function = PMIC_GPIO_FUNC_NORMAL;
274                         drive-push-pull;
275                         input-enable;
276                         bias-pull-up;
277                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
278                         power-source = <PM8994_GPIO_S4>;
279                 };
280
281                 camera-focus-n-pins {
282                         pins = "gpio5";
283                         function = PMIC_GPIO_FUNC_NORMAL;
284                         drive-push-pull;
285                         input-enable;
286                         bias-pull-up;
287                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
288                         power-source = <PM8994_GPIO_S4>;
289                 };
290
291                 pm8994-gpio6-nc-pins {
292                         pins = "gpio6";
293                         function = PMIC_GPIO_FUNC_NORMAL;
294                         drive-push-pull;
295                         bias-high-impedance;
296                         power-source = <PM8994_GPIO_VPH>;
297                 };
298
299                 nfc-download-pins {
300                         pins = "gpio7";
301                         function = PMIC_GPIO_FUNC_NORMAL;
302                         output-low;
303                         drive-push-pull;
304                         bias-disable;
305                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_LOW>;
306                         power-source = <PM8994_GPIO_S4>;
307                 };
308
309                 pm8994-gpio8-nc-pins {
310                         pins = "gpio8";
311                         function = PMIC_GPIO_FUNC_NORMAL;
312                         output-low;
313                         drive-push-pull;
314                         bias-high-impedance;
315                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
316                         power-source = <PM8994_GPIO_VPH>;
317                 };
318
319                 pm8994-gpio9-nc-pins {
320                         pins = "gpio9";
321                         function = PMIC_GPIO_FUNC_NORMAL;
322                         output-high;
323                         drive-push-pull;
324                         bias-high-impedance;
325                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_LOW>;
326                         power-source = <PM8994_GPIO_VPH>;
327                 };
328
329                 nfc-clock-pins {
330                         pins = "gpio10";
331                         function = PMIC_GPIO_FUNC_NORMAL;
332                         input-enable;
333                         drive-push-pull;
334                         bias-pull-down;
335                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
336                         power-source = <PM8994_GPIO_S4>;
337                 };
338
339                 pm8994-gpio11-nc-pins {
340                         pins = "gpio11";
341                         function = PMIC_GPIO_FUNC_NORMAL;
342                         drive-push-pull;
343                         bias-high-impedance;
344                         power-source = <PM8994_GPIO_VPH>;
345                 };
346
347                 pm8994-gpio12-nc-pins {
348                         pins = "gpio12";
349                         function = PMIC_GPIO_FUNC_NORMAL;
350                         drive-push-pull;
351                         bias-high-impedance;
352                         power-source = <PM8994_GPIO_VPH>;
353                 };
354
355                 ear-enable-pins {
356                         pins = "gpio13";
357                         function = PMIC_GPIO_FUNC_NORMAL;
358                         output-high;
359                         drive-push-pull;
360                         bias-disable;
361                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_LOW>;
362                         power-source = <PM8994_GPIO_S4>;
363                 };
364
365                 pm8994-gpio14-nc-pins {
366                         pins = "gpio14";
367                         function = PMIC_GPIO_FUNC_NORMAL;
368                         drive-push-pull;
369                         input-enable;
370                         bias-high-impedance;
371                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_LOW>;
372                         power-source = <PM8994_GPIO_VPH>;
373                 };
374
375                 pm-divclk1-gpio-pins {
376                         pins = "gpio15";
377                         function = "func1";
378                         output-high;
379                         drive-push-pull;
380                         bias-high-impedance;
381                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_LOW>;
382                         power-source = <PM8994_GPIO_VPH>;
383                 };
384
385                 pmi-clk-gpio-pins {
386                         pins = "gpio16";
387                         function = PMIC_GPIO_FUNC_NORMAL;
388                         drive-push-pull;
389                 };
390
391                 pm8994-gpio17-nc-pins {
392                         pins = "gpio17";
393                         function = PMIC_GPIO_FUNC_NORMAL;
394                         drive-push-pull;
395                         bias-high-impedance;
396                         power-source = <PM8994_GPIO_VPH>;
397                 };
398
399                 rome-sleep-pins {
400                         pins = "gpio18";
401                         function = PMIC_GPIO_FUNC_FUNC2;
402                         output-low;
403                         drive-push-pull;
404                         bias-disable;
405                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_MED>;
406                         power-source = <PM8994_GPIO_S4>;
407                 };
408
409                 pm8994-gpio19-nc-pins {
410                         pins = "gpio19";
411                         function = PMIC_GPIO_FUNC_NORMAL;
412                         output-low;
413                         drive-push-pull;
414                         bias-high-impedance;
415                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
416                         power-source = <PM8994_GPIO_VPH>;
417                 };
418
419                 pm8994-gpio22-nc-pins {
420                         pins = "gpio22";
421                         function = PMIC_GPIO_FUNC_NORMAL;
422                         drive-push-pull;
423                         bias-high-impedance;
424                         power-source = <PM8994_GPIO_VPH>;
425                 };
426         };
427 };
428
429 &pm8994_mpps {
430         pinctrl-names = "default";
431         pinctrl-0 = <&pm8994_mpps_defaults>;
432
433         gpio-line-names =
434                 "SDC_UIM_VBIAS",
435                 "LCD_ID_ADC",
436                 "VREF_DACX",
437                 "NC",
438                 "FLASH_THERM",
439                 "NC",
440                 "NC",
441                 "RF_ID";
442
443         pm8994_mpps_defaults: pm8994-mpps-default-state {
444                 lcd-id_adc-mpp-pins {
445                         pins = "mpp2";
446                         function = "analog";
447                         input-enable;
448                         qcom,amux-route = <PMIC_MPP_AMUX_ROUTE_CH6>;
449                 };
450
451                 pm-mpp4-nc-pins {
452                         pins = "mpp4";
453                         function = "digital";
454                         bias-high-impedance;
455                         power-source = <PM8994_GPIO_VPH>;
456                 };
457
458                 flash-therm-mpp-pins {
459                         pins = "mpp5";
460                         function = "analog";
461                         input-enable;
462                         qcom,amux-route = <PMIC_MPP_AMUX_ROUTE_CH5>;
463                 };
464
465                 mpp6-nc-pins {
466                         pins = "mpp6";
467                         function = "digital";
468                         bias-high-impedance;
469                 };
470
471                 rf-id-mpp-pins {
472                         pins = "mpp8";
473                         function = "analog";
474                         input-enable;
475                         qcom,amux-route = <PMIC_MPP_AMUX_ROUTE_CH8>;
476                 };
477         };
478 };
479
480 &pm8994_resin {
481         status = "okay";
482         linux,code = <KEY_VOLUMEUP>;
483 };
484
485 &pmi8994_gpios {
486         pinctrl-names = "default";
487         pinctrl-0 = <&pmi8994_gpios_defaults>;
488
489         gpio-line-names =
490                 "VIB_LDO_EN",
491                 "NC",
492                 "NC",
493                 "NC",
494                 "NC",
495                 "NC",
496                 "NC",
497                 "NC",
498                 "USB_SWITCH_SEL",
499                 "NC";
500
501         pmi8994_gpios_defaults: pmi8994-gpios-default-state {
502                 vib-ldo-en-gpio-pins {
503                         pins = "gpio1";
504                         function = PMIC_GPIO_FUNC_NORMAL;
505                         drive-push-pull;
506                         output-low;
507                         bias-disable;
508                         power-source = <PM8994_GPIO_S4>;
509                 };
510
511                 pmi-gpio2-nc-pins {
512                         pins = "gpio2";
513                         function = PMIC_GPIO_FUNC_NORMAL;
514                         drive-push-pull;
515                         input-enable;
516                         bias-high-impedance;
517                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
518                         power-source = <PM8994_GPIO_VPH>;
519                 };
520
521                 pmi-gpio3-nc-pins {
522                         pins = "gpio3";
523                         function = PMIC_GPIO_FUNC_NORMAL;
524                         drive-push-pull;
525                         input-enable;
526                         bias-high-impedance;
527                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
528                         power-source = <PM8994_GPIO_VPH>;
529                 };
530
531                 pmi-gpio4-nc-pins {
532                         pins = "gpio4";
533                         function = PMIC_GPIO_FUNC_NORMAL;
534                         drive-push-pull;
535                         output-high;
536                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_LOW>;
537                         power-source = <PM8994_GPIO_S4>;
538                 };
539
540                 pmi-gpio5-nc-pins {
541                         pins = "gpio5";
542                         function = PMIC_GPIO_FUNC_NORMAL;
543                         drive-push-pull;
544                         output-high;
545                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
546                         power-source = <PM8994_GPIO_S4>;
547                 };
548
549                 pmi-gpio6-nc-pins {
550                         pins = "gpio6";
551                         function = PMIC_GPIO_FUNC_NORMAL;
552                         drive-push-pull;
553                         output-high;
554                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_LOW>;
555                         power-source = <PM8994_GPIO_S4>;
556                 };
557
558                 pmi-gpio7-nc-pins {
559                         pins = "gpio7";
560                         function = PMIC_GPIO_FUNC_NORMAL;
561                         drive-push-pull;
562                         output-high;
563                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_LOW>;
564                         power-source = <PM8994_GPIO_S4>;
565                 };
566
567                 pmi-gpio8-nc-pins {
568                         pins = "gpio8";
569                         function = PMIC_GPIO_FUNC_NORMAL;
570                         drive-push-pull;
571                         output-high;
572                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_LOW>;
573                         power-source = <PM8994_GPIO_S4>;
574                 };
575
576                 usb-switch-sel-pins {
577                         pins = "gpio9";
578                         function = PMIC_GPIO_FUNC_NORMAL;
579                         drive-push-pull;
580                 };
581
582                 pmi-gpio10-nc-pins {
583                         pins = "gpio10";
584                         function = PMIC_GPIO_FUNC_NORMAL;
585                         output-low;
586                         drive-push-pull;
587                         bias-disable;
588                         qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
589                         power-source = <PM8994_GPIO_S4>;
590                 };
591         };
592 };
593
594 &pm8994_spmi_regulators {
595         qcom,saw-reg = <&saw3>;
596
597         pm8994_s9: s9 {
598                 qcom,saw-slave;
599         };
600
601         pm8994_s10: s10 {
602                 qcom,saw-slave;
603         };
604
605         pm8994_s11: s11 {
606                 qcom,saw-leader;
607                 regulator-name = "vdd_apcc";
608                 regulator-always-on;
609                 regulator-min-microvolt = <470000>;
610                 regulator-max-microvolt = <1140000>;
611         };
612 };
613
614 &pmi8994_spmi_regulators {
615         vdd_gfx:
616         pmi8994_s2: s2 {
617                 /* Pinned to a high value for now to avoid random crashes. */
618                 regulator-min-microvolt = <1015000>;
619                 regulator-max-microvolt = <1015000>;
620                 regulator-name = "vdd_gfx";
621                 regulator-always-on;
622         };
623 };
624
625 &pmi8994_wled {
626         status = "okay";
627         default-brightness = <512>;
628         qcom,num-strings = <3>;
629 };
630
631 &rpm_requests {
632         pm8994-regulators {
633                 compatible = "qcom,rpm-pm8994-regulators";
634
635                 vdd_s1-supply = <&vph_pwr>;
636                 vdd_s2-supply = <&vph_pwr>;
637                 vdd_s3-supply = <&vph_pwr>;
638                 vdd_s4-supply = <&vph_pwr>;
639                 vdd_s5-supply = <&vph_pwr>;
640                 vdd_s6-supply = <&vph_pwr>;
641                 vdd_s7-supply = <&vph_pwr>;
642                 vdd_s8-supply = <&vph_pwr>;
643                 vdd_s9-supply = <&vph_pwr>;
644                 vdd_s10-supply = <&vph_pwr>;
645                 vdd_s11-supply = <&vph_pwr>;
646                 vdd_s12-supply = <&vph_pwr>;
647                 vdd_l1-supply = <&pm8994_s3>;
648                 vdd_l2_l26_l28-supply = <&pm8994_s3>;
649                 vdd_l3_l11-supply = <&pm8994_s3>;
650                 vdd_l4_l27_l31-supply = <&pm8994_s3>;
651                 vdd_l5_l7-supply = <&pm8994_s5>;
652                 vdd_l6_l12_l32-supply = <&pm8994_s5>;
653                 vdd_l8_l16_l30-supply = <&vph_pwr>;
654                 vdd_l14_l15-supply = <&pm8994_s5>;
655                 vdd_l20_l21-supply = <&pm8994_s5>;
656                 vdd_l25-supply = <&pm8994_s3>;
657                 vdd_lvs1_2-supply = <&pm8994_s4>;
658
659                 pm8994_s3: s3 {
660                         regulator-min-microvolt = <1300000>;
661                         regulator-max-microvolt = <1300000>;
662                 };
663
664                 pm8994_s4: s4 {
665                         regulator-min-microvolt = <1800000>;
666                         regulator-max-microvolt = <1800000>;
667                         regulator-system-load = <325000>;
668                         regulator-always-on;
669                 };
670
671                 pm8994_s5: s5 {
672                         regulator-min-microvolt = <2150000>;
673                         regulator-max-microvolt = <2150000>;
674                 };
675
676                 pm8994_s7: s7 {
677                         regulator-min-microvolt = <800000>;
678                         regulator-max-microvolt = <800000>;
679                 };
680
681                 pm8994_l1: l1 {
682                         regulator-min-microvolt = <1000000>;
683                         regulator-max-microvolt = <1000000>;
684                 };
685
686                 pm8994_l2: l2 {
687                         regulator-min-microvolt = <1250000>;
688                         regulator-max-microvolt = <1250000>;
689                 };
690
691                 pm8994_l3: l3 {
692                         regulator-min-microvolt = <1100000>;
693                         regulator-max-microvolt = <1100000>;
694                 };
695
696                 pm8994_l4: l4 {
697                         regulator-min-microvolt = <1225000>;
698                         regulator-max-microvolt = <1225000>;
699                 };
700
701                 /* L6 and L7 seem unused. */
702
703                 pm8994_l8: l8 {
704                         regulator-min-microvolt = <1800000>;
705                         regulator-max-microvolt = <1800000>;
706                 };
707
708                 pm8994_l9: l9 {
709                         regulator-min-microvolt = <1800000>;
710                         regulator-max-microvolt = <1800000>;
711                 };
712
713                 pm8994_l10: l10 {
714                         regulator-min-microvolt = <1800000>;
715                         regulator-max-microvolt = <1800000>;
716                 };
717
718                 pm8994_l11: l11 {
719                         regulator-min-microvolt = <1100000>;
720                         regulator-max-microvolt = <1100000>;
721                 };
722
723                 pm8994_l12: l12 {
724                         regulator-min-microvolt = <1800000>;
725                         regulator-max-microvolt = <1800000>;
726                         regulator-allow-set-load;
727                 };
728
729                 pm8994_l13: l13 {
730                         regulator-min-microvolt = <1800000>;
731                         regulator-max-microvolt = <2950000>;
732                         regulator-system-load = <22000>;
733                         regulator-allow-set-load;
734                 };
735
736                 pm8994_l14: l14 {
737                         regulator-min-microvolt = <1700000>;
738                         regulator-max-microvolt = <1900000>;
739                 };
740
741                 pm8994_l15: l15 {
742                         regulator-min-microvolt = <1800000>;
743                         regulator-max-microvolt = <1800000>;
744                 };
745
746                 pm8994_l16: l16 {
747                         regulator-min-microvolt = <2700000>;
748                         regulator-max-microvolt = <2700000>;
749                 };
750
751                 pm8994_l17: l17 {
752                         regulator-min-microvolt = <2200000>;
753                         regulator-max-microvolt = <2500000>;
754                 };
755
756                 pm8994_l18: l18 {
757                         regulator-min-microvolt = <1800000>;
758                         regulator-max-microvolt = <1800000>;
759                 };
760
761                 pm8994_l19: l19 {
762                         regulator-min-microvolt = <3000000>;
763                         regulator-max-microvolt = <3000000>;
764                 };
765
766                 pm8994_l20: l20 {
767                         regulator-min-microvolt = <2950000>;
768                         regulator-max-microvolt = <2950000>;
769                         regulator-system-load = <570000>;
770                         regulator-allow-set-load;
771                 };
772
773                 pm8994_l21: l21 {
774                         regulator-min-microvolt = <2950000>;
775                         regulator-max-microvolt = <2950000>;
776                         regulator-system-load = <800000>;
777                         regulator-allow-set-load;
778                 };
779
780                 pm8994_l22: l22 {
781                         regulator-min-microvolt = <3000000>;
782                         regulator-max-microvolt = <3000000>;
783                 };
784
785                 pm8994_l23: l23 {
786                         regulator-min-microvolt = <2700000>;
787                         regulator-max-microvolt = <2700000>;
788                 };
789
790                 pm8994_l24: l24 {
791                         regulator-min-microvolt = <3075000>;
792                         regulator-max-microvolt = <3075000>;
793                         regulator-allow-set-load;
794                 };
795
796                 pm8994_l25: l25 {
797                         regulator-min-microvolt = <1200000>;
798                         regulator-max-microvolt = <1200000>;
799                         regulator-allow-set-load;
800                 };
801
802                 pm8994_l27: l27 {
803                         regulator-min-microvolt = <1000000>;
804                         regulator-max-microvolt = <1200000>;
805                 };
806
807                 pm8994_l28: l28 {
808                         regulator-min-microvolt = <925000>;
809                         regulator-max-microvolt = <925000>;
810                         regulator-allow-set-load;
811                 };
812
813                 pm8994_l29: l29 {
814                         regulator-min-microvolt = <2700000>;
815                         regulator-max-microvolt = <2700000>;
816                 };
817
818                 pm8994_l30: l30 { };
819
820                 pm8994_l32: l32 {
821                         regulator-min-microvolt = <1800000>;
822                         regulator-max-microvolt = <1800000>;
823                 };
824         };
825 };
826
827 &sdhc1 {
828         /* eMMC doesn't seem to cooperate even in PIO mode.. */
829         status = "disabled";
830
831         vmmc-supply = <&pm8994_l20>;
832         vqmmc-supply = <&pm8994_s4>;
833         mmc-hs400-1_8v;
834         mmc-hs200-1_8v;
835 };
836
837 &sdhc2 {
838         status = "okay";
839
840         cd-gpios = <&tlmm 40 GPIO_ACTIVE_HIGH>;
841         vmmc-supply = <&pm8994_l21>;
842         vqmmc-supply = <&pm8994_l13>;
843 };
844
845 &tlmm {
846         gpio-reserved-ranges = <0 4>;
847         pinctrl-0 = <&sw_service_gpio>;
848         pinctrl-names = "default";
849
850         disp_reset_n_gpio: disp-reset-n {
851                 pins = "gpio8";
852                 function = "gpio";
853                 drive-strength = <2>;
854                 bias-disable;
855         };
856
857         mdp_vsync_p_gpio: mdp-vsync-p {
858                 pins = "gpio10";
859                 function = "mdp_vsync";
860                 drive-strength = <2>;
861                 bias-disable;
862         };
863
864         sw_service_gpio: sw-service-gpio {
865                 pins = "gpio16";
866                 function = "gpio";
867                 drive-strength = <2>;
868                 bias-pull-up;
869         };
870
871         usb_detect: usb-detect {
872                 pins = "gpio25";
873                 function = "gpio";
874                 drive-strength = <2>;
875                 bias-disable;
876                 output-high;
877         };
878
879         uim_detect_en: uim-detect-en {
880                 pins = "gpio29";
881                 function = "gpio";
882                 drive-strength = <2>;
883                 bias-disable;
884                 output-high;
885         };
886
887         tray_det_pin: tray-det {
888                 pins = "gpio40";
889                 function = "gpio";
890                 drive-strength = <2>;
891                 bias-disable;
892         };
893
894         tp_vddio_en: tp-vddio-en {
895                 pins = "gpio50";
896                 function = "gpio";
897                 drive-strength = <2>;
898                 bias-disable;
899                 output-high;
900         };
901
902         lcd_vddio_en: lcd-vddio-en {
903                 pins = "gpio51";
904                 function = "gpio";
905                 drive-strength = <2>;
906                 bias-disable;
907                 output-low;
908         };
909
910         wl_host_wake: wl-host-wake {
911                 pins = "gpio79";
912                 function = "gpio";
913                 drive-strength = <2>;
914                 bias-pull-down;
915                 input-high;
916         };
917
918         wl_reg_on: wl-reg-on {
919                 pins = "gpio84";
920                 function = "gpio";
921                 drive-strength = <2>;
922                 bias-disable;
923                 output-low;
924         };
925
926         ts_reset_n: ts-rst-n {
927                 pins = "gpio89";
928                 function = "gpio";
929                 drive-strength = <2>;
930         };
931
932         touch_int_n: touch-int-n {
933                 pins = "gpio125";
934                 function = "gpio";
935                 drive-strength = <2>;
936                 bias-pull-up;
937         };
938
939         touch_int_sleep: touch-int-sleep {
940                 pins = "gpio125";
941                 function = "gpio";
942                 drive-strength = <2>;
943                 bias-pull-down;
944         };
945 };
946
947 &usb3 {
948         status = "okay";
949         qcom,select-utmi-as-pipe-clk;
950 };
951
952 &usb3_dwc3 {
953         extcon = <&usb3_id>;
954         dr_mode = "peripheral";
955         maximum-speed = "high-speed";
956         phys = <&hsusb_phy1>;
957         phy-names = "usb2-phy";
958         snps,hird-threshold = /bits/ 8 <0>;
959 };