Debian Codegraph @

scripts/dtc/include-prefixes/arm64/qcom/sc7180-idp.dts

raw
1 // SPDX-License-Identifier: BSD-3-Clause
2 /*
3 * SC7180 IDP board device tree source
4 *
5 * Copyright (c) 2019, The Linux Foundation. All rights reserved.
6 */
7
8 /dts-v1/;
9
10 #include <dt-bindings/gpio/gpio.h>
11 #include <dt-bindings/regulator/qcom,rpmh-regulator.h>
12 #include <dt-bindings/pinctrl/qcom,pmic-gpio.h>
13 #include "sc7180.dtsi"
14 #include "sc7180-firmware-tfa.dtsi"
15 #include "pm6150.dtsi"
16 #include "pm6150l.dtsi"
17
18 / {
19 model = "Qualcomm Technologies, Inc. SC7180 IDP";
20 compatible = "qcom,sc7180-idp", "qcom,sc7180";
21
22 aliases {
23 bluetooth0 = &bluetooth;
24 hsuart0 = &uart3;
25 serial0 = &uart8;
26 wifi0 = &wifi;
27 };
28
29 chosen {
30 stdout-path = "serial0:115200n8";
31 };
32 };
33
34 /*
35 * Reserved memory changes
36 *
37 * Delete all unused memory nodes and define the peripheral memory regions
38 * required by the board dts.
39 *
40 */
41
42 /delete-node/ &gpu_zap_shader;
43 /delete-node/ &hyp_mem;
44 /delete-node/ &xbl_mem;
45 /delete-node/ &aop_mem;
46 /delete-node/ &sec_apps_mem;
47 /delete-node/ &tz_mem;
48
49 /* Increase the size from 2MB to 8MB */
50 &rmtfs_mem {
51 reg = <0x0 0x94600000 0x0 0x800000>;
52 };
53
54 / {
55 reserved-memory {
56 atf_mem: memory@80b00000 {
57 reg = <0x0 0x80b00000 0x0 0x100000>;
58 no-map;
59 };
60
61 mpss_mem: memory@86000000 {
62 reg = <0x0 0x86000000 0x0 0x8c00000>;
63 no-map;
64 };
65
66 camera_mem: memory@8ec00000 {
67 reg = <0x0 0x8ec00000 0x0 0x500000>;
68 no-map;
69 };
70
71 venus_mem: memory@8f600000 {
72 reg = <0 0x8f600000 0 0x500000>;
73 no-map;
74 };
75
76 wlan_mem: memory@94100000 {
77 reg = <0x0 0x94100000 0x0 0x200000>;
78 no-map;
79 };
80
81 mba_mem: memory@94400000 {
82 reg = <0x0 0x94400000 0x0 0x200000>;
83 no-map;
84 };
85
86 mdata_mem: mpss-metadata {
87 alloc-ranges = <0x0 0xa0000000 0x0 0x20000000>;
88 size = <0x0 0x4000>;
89 no-map;
90 };
91 };
92 };
93
94 &apps_rsc {
95 regulators-0 {
96 compatible = "qcom,pm6150-rpmh-regulators";
97 qcom,pmic-id = "a";
98
99 vreg_s1a_1p1: smps1 {
100 regulator-min-microvolt = <1128000>;
101 regulator-max-microvolt = <1128000>;
102 };
103
104 vreg_s4a_1p0: smps4 {
105 regulator-min-microvolt = <824000>;
106 regulator-max-microvolt = <1120000>;
107 };
108
109 vreg_s5a_2p0: smps5 {
110 regulator-min-microvolt = <1744000>;
111 regulator-max-microvolt = <2040000>;
112 };
113
114 vreg_l1a_1p2: ldo1 {
115 regulator-min-microvolt = <1178000>;
116 regulator-max-microvolt = <1256000>;
117 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
118 };
119
120 vreg_l2a_1p0: ldo2 {
121 regulator-min-microvolt = <944000>;
122 regulator-max-microvolt = <1056000>;
123 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
124 };
125
126 vreg_l3a_1p0: ldo3 {
127 regulator-min-microvolt = <968000>;
128 regulator-max-microvolt = <1064000>;
129 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
130 };
131
132 vreg_l4a_0p8: ldo4 {
133 regulator-min-microvolt = <824000>;
134 regulator-max-microvolt = <928000>;
135 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
136 };
137
138 vreg_l5a_2p7: ldo5 {
139 regulator-min-microvolt = <2496000>;
140 regulator-max-microvolt = <3000000>;
141 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
142 };
143
144 vreg_l6a_0p6: ldo6 {
145 regulator-min-microvolt = <568000>;
146 regulator-max-microvolt = <648000>;
147 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
148 };
149
150 vreg_l9a_0p6: ldo9 {
151 regulator-min-microvolt = <488000>;
152 regulator-max-microvolt = <800000>;
153 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
154 };
155
156 vreg_l10a_1p8: ldo10 {
157 regulator-min-microvolt = <1800000>;
158 regulator-max-microvolt = <1832000>;
159 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
160 };
161
162 vreg_l11a_1p8: ldo11 {
163 regulator-min-microvolt = <1696000>;
164 regulator-max-microvolt = <1904000>;
165 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
166 };
167
168 vreg_l12a_1p8: ldo12 {
169 regulator-min-microvolt = <1800000>;
170 regulator-max-microvolt = <1800000>;
171 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
172 };
173
174 vreg_l13a_1p8: ldo13 {
175 regulator-min-microvolt = <1696000>;
176 regulator-max-microvolt = <1904000>;
177 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
178 };
179
180 vreg_l14a_1p8: ldo14 {
181 regulator-min-microvolt = <1728000>;
182 regulator-max-microvolt = <1832000>;
183 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
184 };
185
186 vreg_l15a_1p8: ldo15 {
187 regulator-min-microvolt = <1696000>;
188 regulator-max-microvolt = <1904000>;
189 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
190 };
191
192 vreg_l16a_2p7: ldo16 {
193 regulator-min-microvolt = <2496000>;
194 regulator-max-microvolt = <3304000>;
195 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
196 };
197
198 vreg_l17a_3p0: ldo17 {
199 regulator-min-microvolt = <2920000>;
200 regulator-max-microvolt = <3232000>;
201 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
202 };
203
204 vreg_l18a_2p8: ldo18 {
205 regulator-min-microvolt = <2496000>;
206 regulator-max-microvolt = <3304000>;
207 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
208 };
209
210 vreg_l19a_2p9: ldo19 {
211 regulator-min-microvolt = <2960000>;
212 regulator-max-microvolt = <2960000>;
213 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
214 };
215 };
216
217 regulators-1 {
218 compatible = "qcom,pm6150l-rpmh-regulators";
219 qcom,pmic-id = "c";
220
221 vreg_s8c_1p3: smps8 {
222 regulator-min-microvolt = <1120000>;
223 regulator-max-microvolt = <1408000>;
224 };
225
226 vreg_l1c_1p8: ldo1 {
227 regulator-min-microvolt = <1616000>;
228 regulator-max-microvolt = <1984000>;
229 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
230 };
231
232 vreg_l2c_1p3: ldo2 {
233 regulator-min-microvolt = <1168000>;
234 regulator-max-microvolt = <1304000>;
235 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
236 };
237
238 vreg_l3c_1p2: ldo3 {
239 regulator-min-microvolt = <1144000>;
240 regulator-max-microvolt = <1304000>;
241 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
242 };
243
244 vreg_l4c_1p8: ldo4 {
245 regulator-min-microvolt = <1648000>;
246 regulator-max-microvolt = <3304000>;
247 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
248 };
249
250 vreg_l5c_1p8: ldo5 {
251 regulator-min-microvolt = <1648000>;
252 regulator-max-microvolt = <3304000>;
253 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
254 };
255
256 vreg_l6c_2p9: ldo6 {
257 regulator-min-microvolt = <1800000>;
258 regulator-max-microvolt = <2950000>;
259 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
260 };
261
262 vreg_l7c_3p0: ldo7 {
263 regulator-min-microvolt = <3000000>;
264 regulator-max-microvolt = <3312000>;
265 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
266 };
267
268 vreg_l8c_1p8: ldo8 {
269 regulator-min-microvolt = <1800000>;
270 regulator-max-microvolt = <1904000>;
271 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
272 };
273
274 vreg_l9c_2p9: ldo9 {
275 regulator-min-microvolt = <2960000>;
276 regulator-max-microvolt = <2960000>;
277 regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
278 };
279
280 vreg_l10c_3p3: ldo10 {
281 regulator-min-microvolt = <3000000>;
282 regulator-max-microvolt = <3400000>;
283 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
284 };
285
286 vreg_l11c_3p3: ldo11 {
287 regulator-min-microvolt = <3000000>;
288 regulator-max-microvolt = <3400000>;
289 regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
290 };
291
292 vreg_bob: bob {
293 regulator-min-microvolt = <3008000>;
294 regulator-max-microvolt = <3960000>;
295 regulator-initial-mode = <RPMH_REGULATOR_MODE_AUTO>;
296 };
297 };
298 };
299
300 &mdss {
301 status = "okay";
302 };
303
304 &mdss_dsi0 {
305 status = "okay";
306
307 vdda-supply = <&vreg_l3c_1p2>;
308
309 panel@0 {
310 compatible = "visionox,rm69299-1080p-display";
311 reg = <0>;
312
313 vdda-supply = <&vreg_l8c_1p8>;
314 vdd3p3-supply = <&vreg_l18a_2p8>;
315
316 pinctrl-names = "default";
317 pinctrl-0 = <&disp_pins>;
318
319 reset-gpios = <&pm6150l_gpios 3 GPIO_ACTIVE_HIGH>;
320
321 port {
322 panel0_in: endpoint {
323 remote-endpoint = <&mdss_dsi0_out>;
324 };
325 };
326 };
327 };
328
329 &mdss_dsi0_out {
330 remote-endpoint = <&panel0_in>;
331 data-lanes = <0 1 2 3>;
332 };
333
334 &mdss_dsi0_phy {
335 status = "okay";
336 vdds-supply = <&vreg_l4a_0p8>;
337 };
338
339 &qfprom {
340 vcc-supply = <&vreg_l11a_1p8>;
341 };
342
343 &qspi {
344 status = "okay";
345 pinctrl-names = "default";
346 pinctrl-0 = <&qspi_clk>, <&qspi_cs0>, <&qspi_data0>, <&qspi_data1>;
347
348 flash@0 {
349 compatible = "jedec,spi-nor";
350 reg = <0>;
351 spi-max-frequency = <25000000>;
352 spi-tx-bus-width = <2>;
353 spi-rx-bus-width = <2>;
354 };
355 };
356
357 &qupv3_id_0 {
358 status = "okay";
359 };
360
361 &qupv3_id_1 {
362 status = "okay";
363 };
364
365 &remoteproc_mpss {
366 status = "okay";
367 compatible = "qcom,sc7180-mss-pil";
368 reg = <0 0x04080000 0 0x4040>, <0 0x04180000 0 0x48>;
369 reg-names = "qdsp6", "rmb";
370
371 clocks = <&gcc GCC_MSS_CFG_AHB_CLK>,
372 <&gcc GCC_MSS_Q6_MEMNOC_AXI_CLK>,
373 <&gcc GCC_MSS_NAV_AXI_CLK>,
374 <&gcc GCC_MSS_SNOC_AXI_CLK>,
375 <&gcc GCC_MSS_MFAB_AXIS_CLK>,
376 <&rpmhcc RPMH_CXO_CLK>;
377 clock-names = "iface", "bus", "nav", "snoc_axi", "mnoc_axi", "xo";
378
379 iommus = <&apps_smmu 0x461 0x0>, <&apps_smmu 0x444 0x3>;
380 memory-region = <&mba_mem>, <&mpss_mem>, <&mdata_mem>;
381
382 resets = <&aoss_reset AOSS_CC_MSS_RESTART>,
383 <&pdc_reset PDC_MODEM_SYNC_RESET>;
384 reset-names = "mss_restart", "pdc_reset";
385
386 qcom,halt-regs = <&tcsr_regs_1 0x3000 0x5000 0x4000>;
387 qcom,spare-regs = <&tcsr_regs_2 0xb3e4>;
388 };
389
390 &scm {
391 /* TF-A firmware maps memory cached so mark dma-coherent to match. */
392 dma-coherent;
393 };
394
395 &sdhc_1 {
396 status = "okay";
397
398 pinctrl-names = "default", "sleep";
399 pinctrl-0 = <&sdc1_on>;
400 pinctrl-1 = <&sdc1_off>;
401 vmmc-supply = <&vreg_l19a_2p9>;
402 vqmmc-supply = <&vreg_l12a_1p8>;
403 };
404
405 &sdhc_2 {
406 status = "okay";
407
408 pinctrl-names = "default","sleep";
409 pinctrl-0 = <&sdc2_on>;
410 pinctrl-1 = <&sdc2_off>;
411 vmmc-supply = <&vreg_l9c_2p9>;
412 vqmmc-supply = <&vreg_l6c_2p9>;
413
414 cd-gpios = <&tlmm 69 GPIO_ACTIVE_LOW>;
415 };
416
417 &uart3 {
418 status = "okay";
419
420 /delete-property/interrupts;
421 interrupts-extended = <&intc GIC_SPI 604 IRQ_TYPE_LEVEL_HIGH>,
422 <&tlmm 41 IRQ_TYPE_EDGE_FALLING>;
423
424 pinctrl-names = "default", "sleep";
425 pinctrl-1 = <&qup_uart3_sleep>;
426
427 bluetooth: bluetooth {
428 compatible = "qcom,wcn3990-bt";
429 vddio-supply = <&vreg_l10a_1p8>;
430 vddxo-supply = <&vreg_l1c_1p8>;
431 vddrf-supply = <&vreg_l2c_1p3>;
432 vddch0-supply = <&vreg_l10c_3p3>;
433 max-speed = <3200000>;
434 };
435 };
436
437 &uart8 {
438 status = "okay";
439 };
440
441 &usb_1 {
442 status = "okay";
443 };
444
445 &usb_1_dwc3 {
446 dr_mode = "host";
447 };
448
449 &usb_1_hsphy {
450 status = "okay";
451 vdd-supply = <&vreg_l4a_0p8>;
452 vdda-pll-supply = <&vreg_l11a_1p8>;
453 vdda-phy-dpdm-supply = <&vreg_l17a_3p0>;
454 qcom,imp-res-offset-value = <8>;
455 qcom,preemphasis-level = <QUSB2_V2_PREEMPHASIS_15_PERCENT>;
456 qcom,preemphasis-width = <QUSB2_V2_PREEMPHASIS_WIDTH_HALF_BIT>;
457 qcom,bias-ctrl-value = <0x22>;
458 qcom,charge-ctrl-value = <3>;
459 qcom,hsdisc-trim-value = <0>;
460 };
461
462 &usb_1_qmpphy {
463 status = "okay";
464 vdda-phy-supply = <&vreg_l3c_1p2>;
465 vdda-pll-supply = <&vreg_l4a_0p8>;
466 };
467
468 &venus {
469 video-firmware {
470 iommus = <&apps_smmu 0x0c42 0x0>;
471 };
472 };
473
474 &wifi {
475 status = "okay";
476 vdd-0.8-cx-mx-supply = <&vreg_l9a_0p6>;
477 vdd-1.8-xo-supply = <&vreg_l1c_1p8>;
478 vdd-1.3-rfa-supply = <&vreg_l2c_1p3>;
479 vdd-3.3-ch0-supply = <&vreg_l10c_3p3>;
480 vdd-3.3-ch1-supply = <&vreg_l11c_3p3>;
481 wifi-firmware {
482 iommus = <&apps_smmu 0xc2 0x1>;
483 };
484 };
485
486 /* PINCTRL - additions to nodes defined in sc7180.dtsi */
487
488 &pm6150l_gpios {
489 disp_pins: disp-state {
490 pinconf {
491 pins = "gpio3";
492 function = PMIC_GPIO_FUNC_FUNC1;
493 qcom,drive-strength = <PMIC_GPIO_STRENGTH_MED>;
494 power-source = <0>;
495 bias-disable;
496 output-low;
497 };
498 };
499 };
500
501 &qspi_clk {
502 bias-disable;
503 };
504
505 &qspi_cs0 {
506 bias-disable;
507 };
508
509 &qspi_data0 {
510 bias-pull-up;
511 };
512
513 &qspi_data1 {
514 bias-pull-up;
515 };
516
517 &qup_i2c2_default {
518 drive-strength = <2>;
519
520 /* Has external pullup */
521 bias-disable;
522 };
523
524 &qup_i2c4_default {
525 drive-strength = <2>;
526
527 /* Has external pullup */
528 bias-disable;
529 };
530
531 &qup_i2c7_default {
532 drive-strength = <2>;
533
534 /* Has external pullup */
535 bias-disable;
536 };
537
538 &qup_i2c9_default {
539 drive-strength = <2>;
540
541 /* Has external pullup */
542 bias-disable;
543 };
544
545 &qup_uart3_cts {
546 /*
547 * Configure a pull-down on CTS to match the pull of
548 * the Bluetooth module.
549 */
550 bias-pull-down;
551 };
552
553 &qup_uart3_rts {
554 /* We'll drive RTS, so no pull */
555 drive-strength = <2>;
556 bias-disable;
557 };
558
559 &qup_uart3_tx {
560 /* We'll drive TX, so no pull */
561 drive-strength = <2>;
562 bias-disable;
563 };
564
565 &qup_uart3_rx {
566 /*
567 * Configure a pull-up on RX. This is needed to avoid
568 * garbage data when the TX pin of the Bluetooth module is
569 * in tri-state (module powered off or not driving the
570 * signal yet).
571 */
572 bias-pull-up;
573 };
574
575 &qup_uart8_tx {
576 drive-strength = <2>;
577 bias-disable;
578 };
579
580 &qup_uart8_rx {
581 drive-strength = <2>;
582 bias-pull-up;
583 };
584
585 &qup_spi0_spi {
586 drive-strength = <2>;
587 bias-disable;
588 };
589
590 &qup_spi0_cs {
591 drive-strength = <2>;
592 bias-disable;
593 };
594
595 &qup_spi6_spi {
596 drive-strength = <2>;
597 bias-disable;
598 };
599
600 &qup_spi6_cs {
601 drive-strength = <2>;
602 bias-disable;
603 };
604
605 &qup_spi10_spi {
606 drive-strength = <2>;
607 bias-disable;
608 };
609
610 &qup_spi10_cs {
611 drive-strength = <2>;
612 bias-disable;
613 };
614
615 &tlmm {
616 qup_uart3_sleep: qup-uart3-sleep-state {
617 cts-pins {
618 /*
619 * Configure a pull-down on CTS to match the pull of
620 * the Bluetooth module.
621 */
622 pins = "gpio38";
623 function = "gpio";
624 bias-pull-down;
625 };
626
627 rts-pins {
628 /*
629 * Configure pull-down on RTS. As RTS is active low
630 * signal, pull it low to indicate the BT SoC that it
631 * can wakeup the system anytime from suspend state by
632 * pulling RX low (by sending wakeup bytes).
633 */
634 pins = "gpio39";
635 function = "gpio";
636 bias-pull-down;
637 };
638
639 tx-pins {
640 /*
641 * Configure pull-up on TX when it isn't actively driven
642 * to prevent BT SoC from receiving garbage during sleep.
643 */
644 pins = "gpio40";
645 function = "gpio";
646 bias-pull-up;
647 };
648
649 rx-pins {
650 /*
651 * Configure a pull-up on RX. This is needed to avoid
652 * garbage data when the TX pin of the Bluetooth module
653 * is floating which may cause spurious wakeups.
654 */
655 pins = "gpio41";
656 function = "gpio";
657 bias-pull-up;
658 };
659 };
660
661 sdc1_on: sdc1-on-state {
662 clk-pins {
663 pins = "sdc1_clk";
664 bias-disable;
665 drive-strength = <16>;
666 };
667
668 cmd-pins {
669 pins = "sdc1_cmd";
670 bias-pull-up;
671 drive-strength = <10>;
672 };
673
674 data-pins {
675 pins = "sdc1_data";
676 bias-pull-up;
677 drive-strength = <10>;
678 };
679
680 rclk-pins {
681 pins = "sdc1_rclk";
682 bias-pull-down;
683 };
684 };
685
686 sdc1_off: sdc1-off-state {
687 clk-pins {
688 pins = "sdc1_clk";
689 bias-disable;
690 drive-strength = <2>;
691 };
692
693 cmd-pins {
694 pins = "sdc1_cmd";
695 bias-pull-up;
696 drive-strength = <2>;
697 };
698
699 data-pins {
700 pins = "sdc1_data";
701 bias-pull-up;
702 drive-strength = <2>;
703 };
704
705 rclk-pins {
706 pins = "sdc1_rclk";
707 bias-pull-down;
708 };
709 };
710
711 sdc2_on: sdc2-on-state {
712 clk-pins {
713 pins = "sdc2_clk";
714 bias-disable;
715 drive-strength = <16>;
716 };
717
718 cmd-pins {
719 pins = "sdc2_cmd";
720 bias-pull-up;
721 drive-strength = <10>;
722 };
723
724 data-pins {
725 pins = "sdc2_data";
726 bias-pull-up;
727 drive-strength = <10>;
728 };
729
730 sd-cd-pins {
731 pins = "gpio69";
732 function = "gpio";
733 bias-pull-up;
734 drive-strength = <2>;
735 };
736 };
737
738 sdc2_off: sdc2-off-state {
739 clk-pins {
740 pins = "sdc2_clk";
741 bias-disable;
742 drive-strength = <2>;
743 };
744
745 cmd-pins {
746 pins = "sdc2_cmd";
747 bias-pull-up;
748 drive-strength = <2>;
749 };
750
751 data-pins {
752 pins = "sdc2_data";
753 bias-pull-up;
754 drive-strength = <2>;
755 };
756
757 sd-cd-pins {
758 pins = "gpio69";
759 function = "gpio";
760 bias-pull-up;
761 drive-strength = <2>;
762 };
763 };
764 };