1 // SPDX-License-Identifier: BSD-3-Clause
3 * Copyright (c) 2020, Konrad Dybcio <konrad.dybcio@somainline.org>
4 * Copyright (c) 2020, AngeloGioacchino Del Regno
5 * <angelogioacchino.delregno@somainline.org>
10 #include <dt-bindings/gpio/gpio.h>
11 #include <dt-bindings/input/input.h>
12 #include <dt-bindings/input/gpio-keys.h>
15 /* required for bootloader to select correct board */
16 qcom,msm-id = <318 0>;
17 qcom,board-id = <8 1>;
18 qcom,pmic-id = <0x1001b 0x101011a 0x00 0x00 0x1001b 0x201011a 0x00 0x00>;
20 /* This part enables graphical output via bootloader-enabled display */
22 bootargs = "earlycon=tty0 console=tty0";
28 stdout-path = "framebuffer0";
30 framebuffer0: framebuffer@9d400000 {
31 compatible = "simple-framebuffer";
32 reg = <0 0x9d400000 0 (1920 * 1080 * 4)>;
35 stride = <(1080 * 4)>;
41 board_vbat: vbat-regulator {
42 compatible = "regulator-fixed";
43 regulator-name = "VBAT";
45 regulator-min-microvolt = <4000000>;
46 regulator-max-microvolt = <4000000>;
51 vph_pwr: vph-pwr-regulator {
52 compatible = "regulator-fixed";
53 regulator-name = "vph_pwr";
59 cam_vdig_imx300_219_vreg: cam_vdig_imx300_219_vreg {
60 compatible = "regulator-fixed";
61 regulator-name = "cam_vdig_imx300_219_vreg";
62 startup-delay-us = <0>;
64 gpio = <&tlmm 52 GPIO_ACTIVE_HIGH>;
65 pinctrl-names = "default";
66 pinctrl-0 = <&cam_vdig_default>;
69 cam_vana_front_vreg: cam_vana_front_vreg {
70 compatible = "regulator-fixed";
71 regulator-name = "cam_vana_front_vreg";
72 startup-delay-us = <0>;
74 gpio = <&tlmm 51 GPIO_ACTIVE_HIGH>;
75 pinctrl-names = "default";
76 pinctrl-0 = <&imx219_vana_default>;
79 cam_vana_rear_vreg: cam_vana_rear_vreg {
80 compatible = "regulator-fixed";
81 regulator-name = "cam_vana_rear_vreg";
82 startup-delay-us = <0>;
84 gpio = <&tlmm 50 GPIO_ACTIVE_HIGH>;
86 pinctrl-names = "default";
87 pinctrl-0 = <&imx300_vana_default>;
92 compatible = "gpio-keys";
93 input-name = "gpio-keys";
98 label = "Camera Focus";
99 gpios = <&tlmm 64 GPIO_ACTIVE_LOW>;
100 linux,input-type = <1>;
101 linux,code = <KEY_CAMERA_FOCUS>;
102 debounce-interval = <15>;
106 label = "Camera Snapshot";
107 gpios = <&tlmm 113 GPIO_ACTIVE_LOW>;
108 linux,input-type = <1>;
109 linux,code = <KEY_CAMERA>;
110 debounce-interval = <15>;
114 label = "Volume Down";
115 gpios = <&pm660l_gpios 7 GPIO_ACTIVE_LOW>;
116 linux,input-type = <1>;
117 linux,code = <KEY_VOLUMEDOWN>;
119 debounce-interval = <15>;
124 #address-cells = <2>;
129 compatible = "ramoops";
130 reg = <0x0 0xffc00000 0x0 0x100000>;
131 record-size = <0x10000>;
132 console-size = <0x60000>;
133 ftrace-size = <0x10000>;
134 pmsg-size = <0x20000>;
139 debug_region@ffb00000 {
140 reg = <0x00 0xffb00000 0x00 0x100000>;
144 removed_region@85800000 {
145 reg = <0x00 0x85800000 0x00 0x3700000>;
151 * Until we hook up type-c detection, we
152 * have to stick with this. But it works.
154 extcon_usb: extcon-usb {
155 compatible = "linux,extcon-usb-gpio";
156 id-gpio = <&tlmm 58 GPIO_ACTIVE_HIGH>;
161 firmware-name = "adsp.mdt";
167 touchscreen: synaptics-rmi4-i2c@70 {
168 compatible = "syna,rmi4-i2c";
170 #address-cells = <1>;
172 interrupts-extended = <&tlmm 45 0x2008>;
174 pinctrl-names = "default";
175 pinctrl-0 = <&ts_int_active &ts_lcd_id_active>;
177 syna,reset-delay-ms = <200>;
178 syna,startup-delay-ms = <220>;
182 syna,nosleep-mode = <1>;
187 syna,sensor-type = <1>;
195 /* SMB1351 charger */
198 /* I2C3, 4, 5, 7 and 8 are disabled on this board. */
209 /* MSM serial console */
220 compatible = "qcom,pm8941-resin";
221 interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
224 linux,code = <KEY_VOLUMEUP>;
231 vdd-supply = <&vreg_l1b_0p925>;
232 vdda-pll-supply = <&vreg_l10a_1p8>;
233 vdda-phy-dpdm-supply = <&vreg_l7b_3p125>;
238 compatible = "qcom,rpm-pm660l-regulators";
240 vdd_s1-supply = <&vph_pwr>;
241 vdd_s2-supply = <&vph_pwr>;
242 vdd_s3_s4-supply = <&vph_pwr>;
243 vdd_s5-supply = <&vph_pwr>;
244 vdd_s6-supply = <&vph_pwr>;
246 vdd_l1_l9_l10-supply = <&vreg_s2b_1p05>;
247 vdd_l2-supply = <&vreg_bob>;
248 vdd_l3_l5_l7_l8-supply = <&vreg_bob>;
249 vdd_l4_l6-supply = <&vreg_bob>;
250 vdd_bob-supply = <&vph_pwr>;
253 regulator-min-microvolt = <1125000>;
254 regulator-max-microvolt = <1125000>;
255 regulator-enable-ramp-delay = <200>;
256 regulator-ramp-delay = <0>;
260 regulator-min-microvolt = <1050000>;
261 regulator-max-microvolt = <1050000>;
262 regulator-enable-ramp-delay = <200>;
263 regulator-ramp-delay = <0>;
267 * At least on Nile's configuration, S3B/S4B (VDD_CX) and
268 * S5B (VDD_MX) are managed only through RPM Power Domains.
269 * Trying to set a voltage on the main supply will create
270 * havoc and freeze the SoC.
271 * In any case, reference voltages for these regulators are:
278 regulator-min-microvolt = <920000>;
279 regulator-max-microvolt = <928000>;
280 regulator-enable-ramp-delay = <250>;
281 regulator-ramp-delay = <0>;
282 regulator-allow-set-load;
287 * This regulator supports 1.648 - 3.104V on this board
288 * but we set a max voltage of anything less than 2.7V
289 * to satisfy a condition in sdhci.c that will disable
290 * 3.3V SDHCI signaling, which happens to be not really
291 * supported on the Xperia Nile/Ganges platform.
293 regulator-min-microvolt = <1648000>;
294 regulator-max-microvolt = <2696000>;
295 regulator-enable-ramp-delay = <250>;
296 regulator-ramp-delay = <0>;
297 regulator-allow-set-load;
301 regulator-min-microvolt = <2800000>;
302 regulator-max-microvolt = <2800000>;
303 regulator-enable-ramp-delay = <250>;
304 regulator-ramp-delay = <0>;
305 regulator-min-microamp = <200>;
306 regulator-max-microamp = <600000>;
307 regulator-system-load = <100000>;
308 regulator-allow-set-load;
312 regulator-min-microvolt = <2944000>;
313 regulator-max-microvolt = <2952000>;
314 regulator-enable-ramp-delay = <250>;
315 regulator-ramp-delay = <0>;
317 regulator-min-microamp = <200>;
318 regulator-max-microamp = <600000>;
319 regulator-system-load = <570000>;
320 regulator-allow-set-load;
324 * Downstream specifies a range of 1721-3600mV,
325 * but the only assigned consumers are SDHCI2 VMMC
326 * and Coresight QPDI that both request pinned 2.95V.
327 * Tighten the range to 1.8-3.328 (closest to 3.3) to
328 * make the mmc driver happy.
331 regulator-min-microvolt = <1800000>;
332 regulator-max-microvolt = <3328000>;
333 regulator-enable-ramp-delay = <250>;
334 regulator-ramp-delay = <0>;
335 regulator-allow-set-load;
336 regulator-system-load = <800000>;
340 regulator-min-microvolt = <1704000>;
341 regulator-max-microvolt = <3312000>;
342 regulator-enable-ramp-delay = <250>;
343 regulator-ramp-delay = <0>;
347 regulator-min-microvolt = <2704000>;
348 regulator-max-microvolt = <3128000>;
349 regulator-enable-ramp-delay = <250>;
350 regulator-ramp-delay = <0>;
354 regulator-min-microvolt = <2800000>;
355 regulator-max-microvolt = <3400000>;
356 regulator-enable-ramp-delay = <250>;
357 regulator-ramp-delay = <0>;
360 /* L9B (870mV) is currently unused */
361 /* L10B (915mV) is currently unused */
364 regulator-min-microvolt = <3304000>;
365 regulator-max-microvolt = <3624000>;
366 regulator-enable-ramp-delay = <500>;
367 regulator-ramp-delay = <0>;
372 compatible = "qcom,rpm-pm660-regulators";
374 vdd_s1-supply = <&vph_pwr>;
375 vdd_s2-supply = <&vph_pwr>;
376 vdd_s3-supply = <&vph_pwr>;
377 vdd_s4-supply = <&vph_pwr>;
378 vdd_s5-supply = <&vph_pwr>;
379 vdd_s6-supply = <&vph_pwr>;
381 vdd_l1_l6_l7-supply = <&vreg_s5a_1p35>;
382 vdd_l2_l3-supply = <&vreg_s2b_1p05>;
383 vdd_l5-supply = <&vreg_s2b_1p05>;
384 vdd_l8_l9_l10_l11_l12_l13_l14-supply = <&vreg_s4a_2p04>;
385 vdd_l15_l16_l17_l18_l19-supply = <&vreg_bob>;
388 * S1A (FTAPC0), S2A (FTAPC1), S3A (HFAPC1) are managed
389 * by the Core Power Reduction hardened (CPRh) and the
390 * Operating State Manager (OSM) HW automatically.
394 regulator-min-microvolt = <2040000>;
395 regulator-max-microvolt = <2040000>;
396 regulator-enable-ramp-delay = <200>;
397 regulator-ramp-delay = <0>;
402 regulator-min-microvolt = <1224000>;
403 regulator-max-microvolt = <1350000>;
404 regulator-enable-ramp-delay = <200>;
405 regulator-ramp-delay = <0>;
409 regulator-min-microvolt = <504000>;
410 regulator-max-microvolt = <992000>;
411 regulator-enable-ramp-delay = <150>;
412 regulator-ramp-delay = <0>;
417 regulator-min-microvolt = <1226000>;
418 regulator-max-microvolt = <1250000>;
419 regulator-enable-ramp-delay = <250>;
420 regulator-ramp-delay = <0>;
421 regulator-allow-set-load;
425 regulator-min-microvolt = <944000>;
426 regulator-max-microvolt = <1008000>;
427 regulator-enable-ramp-delay = <250>;
428 regulator-ramp-delay = <0>;
432 regulator-min-microvolt = <944000>;
433 regulator-max-microvolt = <1008000>;
434 regulator-enable-ramp-delay = <250>;
435 regulator-ramp-delay = <0>;
439 regulator-min-microvolt = <800000>;
440 regulator-max-microvolt = <952000>;
441 regulator-enable-ramp-delay = <250>;
442 regulator-ramp-delay = <0>;
446 regulator-min-microvolt = <1304000>;
447 regulator-max-microvolt = <1368000>;
448 regulator-allow-set-load;
449 regulator-enable-ramp-delay = <250>;
450 regulator-ramp-delay = <0>;
454 regulator-min-microvolt = <1200000>;
455 regulator-max-microvolt = <1200000>;
456 regulator-enable-ramp-delay = <250>;
457 regulator-ramp-delay = <0>;
461 regulator-min-microvolt = <1800000>;
462 regulator-max-microvolt = <1800000>;
463 regulator-enable-ramp-delay = <250>;
464 regulator-ramp-delay = <0>;
465 regulator-system-load = <325000>;
466 regulator-allow-set-load;
470 regulator-min-microvolt = <1804000>;
471 regulator-max-microvolt = <1896000>;
472 regulator-enable-ramp-delay = <250>;
473 regulator-ramp-delay = <0>;
474 regulator-allow-set-load;
478 regulator-min-microvolt = <1800000>;
479 regulator-max-microvolt = <1944000>;
480 regulator-enable-ramp-delay = <250>;
481 regulator-ramp-delay = <0>;
482 regulator-allow-set-load;
486 regulator-min-microvolt = <1784000>;
487 regulator-max-microvolt = <1944000>;
488 regulator-enable-ramp-delay = <250>;
489 regulator-ramp-delay = <0>;
493 regulator-min-microvolt = <1800000>;
494 regulator-max-microvolt = <1944000>;
495 regulator-enable-ramp-delay = <250>;
496 regulator-ramp-delay = <0>;
499 /* This gives power to the LPDDR4: never turn it off! */
501 regulator-min-microvolt = <1800000>;
502 regulator-max-microvolt = <1944000>;
503 regulator-enable-ramp-delay = <250>;
504 regulator-ramp-delay = <0>;
510 regulator-min-microvolt = <1710000>;
511 regulator-max-microvolt = <1904000>;
512 regulator-enable-ramp-delay = <250>;
513 regulator-ramp-delay = <0>;
517 regulator-min-microvolt = <1648000>;
518 regulator-max-microvolt = <2952000>;
519 regulator-enable-ramp-delay = <250>;
520 regulator-ramp-delay = <0>;
523 /* L16A (2.70V) is unused */
526 regulator-min-microvolt = <1648000>;
527 regulator-max-microvolt = <2952000>;
528 regulator-enable-ramp-delay = <250>;
529 regulator-ramp-delay = <0>;
533 regulator-min-microvolt = <1800000>;
534 regulator-max-microvolt = <1800000>;
535 regulator-enable-ramp-delay = <250>;
536 regulator-ramp-delay = <10>;
537 regulator-min-microamp = <200>;
538 regulator-max-microamp = <50000>;
539 regulator-system-load = <10000>;
540 regulator-allow-set-load;
544 regulator-min-microvolt = <3312000>;
545 regulator-max-microvolt = <3400000>;
546 regulator-enable-ramp-delay = <250>;
547 regulator-ramp-delay = <0>;
548 regulator-allow-set-load;
557 /* SoMC Nile platform's eMMC doesn't support HS200 mode */
560 mmc-hs400-enhanced-strobe;
562 vmmc-supply = <&vreg_l4b_29p5>;
563 vqmmc-supply = <&vreg_l8a_1p8>;
569 vmmc-supply = <&vreg_l5b_29p5>;
570 vqmmc-supply = <&vreg_l2b_2p95>;
574 gpio-reserved-ranges = <8 4>;
576 ts_int_active: ts-int-active {
578 drive-strength = <8>;
582 ts_lcd_id_active: ts-lcd-id-active {
584 drive-strength = <8>;
588 imx300_vana_default: imx300-vana-default {
592 drive-strength = <2>;
595 imx219_vana_default: imx219-vana-default {
599 drive-strength = <2>;
602 cam_vdig_default: cam-vdig-default {
606 drive-strength = <2>;
615 dr_mode = "peripheral";
616 extcon = <&extcon_usb>;