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";
99 label = "Camera Focus";
100 gpios = <&tlmm 64 GPIO_ACTIVE_LOW>;
101 linux,input-type = <1>;
102 linux,code = <KEY_CAMERA_FOCUS>;
103 debounce-interval = <15>;
107 label = "Camera Snapshot";
108 gpios = <&tlmm 113 GPIO_ACTIVE_LOW>;
109 linux,input-type = <1>;
110 linux,code = <KEY_CAMERA>;
111 debounce-interval = <15>;
115 label = "Volume Down";
116 gpios = <&pm660l_gpios 7 GPIO_ACTIVE_LOW>;
117 linux,input-type = <1>;
118 linux,code = <KEY_VOLUMEDOWN>;
120 debounce-interval = <15>;
125 #address-cells = <2>;
130 compatible = "ramoops";
131 reg = <0x0 0xffc00000 0x0 0x100000>;
132 record-size = <0x10000>;
133 console-size = <0x60000>;
134 ftrace-size = <0x10000>;
135 pmsg-size = <0x20000>;
140 debug_region@ffb00000 {
141 reg = <0x00 0xffb00000 0x00 0x100000>;
145 removed_region@85800000 {
146 reg = <0x00 0x85800000 0x00 0x3700000>;
152 * Until we hook up type-c detection, we
153 * have to stick with this. But it works.
155 extcon_usb: extcon-usb {
156 compatible = "linux,extcon-usb-gpio";
157 id-gpio = <&tlmm 58 GPIO_ACTIVE_HIGH>;
164 /* Synaptics touchscreen */
170 /* SMB1351 charger */
173 /* I2C3, 4, 5, 7 and 8 are disabled on this board. */
184 /* MSM serial console */
195 compatible = "qcom,pm8941-resin";
196 interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
199 linux,code = <KEY_VOLUMEUP>;
206 vdd-supply = <&vreg_l1b_0p925>;
207 vdda-pll-supply = <&vreg_l10a_1p8>;
208 vdda-phy-dpdm-supply = <&vreg_l7b_3p125>;
213 compatible = "qcom,rpm-pm660l-regulators";
215 vdd_s1-supply = <&vph_pwr>;
216 vdd_s2-supply = <&vph_pwr>;
217 vdd_s3_s4-supply = <&vph_pwr>;
218 vdd_s5-supply = <&vph_pwr>;
219 vdd_s6-supply = <&vph_pwr>;
221 vdd_l1_l9_l10-supply = <&vreg_s2b_1p05>;
222 vdd_l2-supply = <&vreg_bob>;
223 vdd_l3_l5_l7_l8-supply = <&vreg_bob>;
224 vdd_l4_l6-supply = <&vreg_bob>;
225 vdd_bob-supply = <&vph_pwr>;
228 regulator-min-microvolt = <1125000>;
229 regulator-max-microvolt = <1125000>;
230 regulator-enable-ramp-delay = <200>;
231 regulator-ramp-delay = <0>;
235 regulator-min-microvolt = <1050000>;
236 regulator-max-microvolt = <1050000>;
237 regulator-enable-ramp-delay = <200>;
238 regulator-ramp-delay = <0>;
242 * At least on Nile's configuration, S3B/S4B (VDD_CX) and
243 * S5B (VDD_MX) are managed only through RPM Power Domains.
244 * Trying to set a voltage on the main supply will create
245 * havoc and freeze the SoC.
246 * In any case, reference voltages for these regulators are:
253 regulator-min-microvolt = <920000>;
254 regulator-max-microvolt = <928000>;
255 regulator-enable-ramp-delay = <250>;
256 regulator-ramp-delay = <0>;
257 regulator-allow-set-load;
262 * This regulator supports 1.648 - 3.104V on this board
263 * but we set a max voltage of anything less than 2.7V
264 * to satisfy a condition in sdhci.c that will disable
265 * 3.3V SDHCI signaling, which happens to be not really
266 * supported on the Xperia Nile/Ganges platform.
268 regulator-min-microvolt = <1648000>;
269 regulator-max-microvolt = <2696000>;
270 regulator-enable-ramp-delay = <250>;
271 regulator-ramp-delay = <0>;
272 regulator-allow-set-load;
276 regulator-min-microvolt = <2800000>;
277 regulator-max-microvolt = <2800000>;
278 regulator-enable-ramp-delay = <250>;
279 regulator-ramp-delay = <0>;
280 regulator-min-microamp = <200>;
281 regulator-max-microamp = <600000>;
282 regulator-system-load = <100000>;
283 regulator-allow-set-load;
287 regulator-min-microvolt = <2944000>;
288 regulator-max-microvolt = <2952000>;
289 regulator-enable-ramp-delay = <250>;
290 regulator-ramp-delay = <0>;
292 regulator-min-microamp = <200>;
293 regulator-max-microamp = <600000>;
294 regulator-system-load = <570000>;
295 regulator-allow-set-load;
299 * Downstream specifies a range of 1721-3600mV,
300 * but the only assigned consumers are SDHCI2 VMMC
301 * and Coresight QPDI that both request pinned 2.95V.
302 * Tighten the range to 1.8-3.328 (closest to 3.3) to
303 * make the mmc driver happy.
306 regulator-min-microvolt = <1800000>;
307 regulator-max-microvolt = <3328000>;
308 regulator-enable-ramp-delay = <250>;
309 regulator-ramp-delay = <0>;
310 regulator-allow-set-load;
314 regulator-min-microvolt = <1704000>;
315 regulator-max-microvolt = <3312000>;
316 regulator-enable-ramp-delay = <250>;
317 regulator-ramp-delay = <0>;
321 regulator-min-microvolt = <2704000>;
322 regulator-max-microvolt = <3128000>;
323 regulator-enable-ramp-delay = <250>;
324 regulator-ramp-delay = <0>;
328 regulator-min-microvolt = <2800000>;
329 regulator-max-microvolt = <3400000>;
330 regulator-enable-ramp-delay = <250>;
331 regulator-ramp-delay = <0>;
334 /* L9B (870mV) is currently unused */
335 /* L10B (915mV) is currently unused */
338 regulator-min-microvolt = <3304000>;
339 regulator-max-microvolt = <3624000>;
340 regulator-enable-ramp-delay = <500>;
341 regulator-ramp-delay = <0>;
346 compatible = "qcom,rpm-pm660-regulators";
348 vdd_s1-supply = <&vph_pwr>;
349 vdd_s2-supply = <&vph_pwr>;
350 vdd_s3-supply = <&vph_pwr>;
351 vdd_s4-supply = <&vph_pwr>;
352 vdd_s5-supply = <&vph_pwr>;
353 vdd_s6-supply = <&vph_pwr>;
355 vdd_l1_l6_l7-supply = <&vreg_s5a_1p35>;
356 vdd_l2_l3-supply = <&vreg_s2b_1p05>;
357 vdd_l5-supply = <&vreg_s2b_1p05>;
358 vdd_l8_l9_l10_l11_l12_l13_l14-supply = <&vreg_s4a_2p04>;
359 vdd_l15_l16_l17_l18_l19-supply = <&vreg_bob>;
362 * S1A (FTAPC0), S2A (FTAPC1), S3A (HFAPC1) are managed
363 * by the Core Power Reduction hardened (CPRh) and the
364 * Operating State Manager (OSM) HW automatically.
368 regulator-min-microvolt = <2040000>;
369 regulator-max-microvolt = <2040000>;
370 regulator-enable-ramp-delay = <200>;
371 regulator-ramp-delay = <0>;
376 regulator-min-microvolt = <1224000>;
377 regulator-max-microvolt = <1350000>;
378 regulator-enable-ramp-delay = <200>;
379 regulator-ramp-delay = <0>;
383 regulator-min-microvolt = <504000>;
384 regulator-max-microvolt = <992000>;
385 regulator-enable-ramp-delay = <150>;
386 regulator-ramp-delay = <0>;
391 regulator-min-microvolt = <1226000>;
392 regulator-max-microvolt = <1250000>;
393 regulator-enable-ramp-delay = <250>;
394 regulator-ramp-delay = <0>;
395 regulator-allow-set-load;
399 regulator-min-microvolt = <944000>;
400 regulator-max-microvolt = <1008000>;
401 regulator-enable-ramp-delay = <250>;
402 regulator-ramp-delay = <0>;
406 regulator-min-microvolt = <944000>;
407 regulator-max-microvolt = <1008000>;
408 regulator-enable-ramp-delay = <250>;
409 regulator-ramp-delay = <0>;
413 regulator-min-microvolt = <800000>;
414 regulator-max-microvolt = <952000>;
415 regulator-enable-ramp-delay = <250>;
416 regulator-ramp-delay = <0>;
420 regulator-min-microvolt = <1304000>;
421 regulator-max-microvolt = <1368000>;
422 regulator-allow-set-load;
423 regulator-enable-ramp-delay = <250>;
424 regulator-ramp-delay = <0>;
428 regulator-min-microvolt = <1200000>;
429 regulator-max-microvolt = <1200000>;
430 regulator-enable-ramp-delay = <250>;
431 regulator-ramp-delay = <0>;
435 regulator-min-microvolt = <1800000>;
436 regulator-max-microvolt = <1800000>;
437 regulator-enable-ramp-delay = <250>;
438 regulator-ramp-delay = <0>;
439 regulator-system-load = <325000>;
440 regulator-allow-set-load;
444 regulator-min-microvolt = <1804000>;
445 regulator-max-microvolt = <1896000>;
446 regulator-enable-ramp-delay = <250>;
447 regulator-ramp-delay = <0>;
448 regulator-allow-set-load;
452 regulator-min-microvolt = <1800000>;
453 regulator-max-microvolt = <1944000>;
454 regulator-enable-ramp-delay = <250>;
455 regulator-ramp-delay = <0>;
456 regulator-allow-set-load;
460 regulator-min-microvolt = <1784000>;
461 regulator-max-microvolt = <1944000>;
462 regulator-enable-ramp-delay = <250>;
463 regulator-ramp-delay = <0>;
467 regulator-min-microvolt = <1800000>;
468 regulator-max-microvolt = <1944000>;
469 regulator-enable-ramp-delay = <250>;
470 regulator-ramp-delay = <0>;
473 /* This gives power to the LPDDR4: never turn it off! */
475 regulator-min-microvolt = <1800000>;
476 regulator-max-microvolt = <1944000>;
477 regulator-enable-ramp-delay = <250>;
478 regulator-ramp-delay = <0>;
484 regulator-min-microvolt = <1710000>;
485 regulator-max-microvolt = <1904000>;
486 regulator-enable-ramp-delay = <250>;
487 regulator-ramp-delay = <0>;
491 regulator-min-microvolt = <1648000>;
492 regulator-max-microvolt = <2952000>;
493 regulator-enable-ramp-delay = <250>;
494 regulator-ramp-delay = <0>;
497 /* L16A (2.70V) is unused */
500 regulator-min-microvolt = <1648000>;
501 regulator-max-microvolt = <2952000>;
502 regulator-enable-ramp-delay = <250>;
503 regulator-ramp-delay = <0>;
507 regulator-min-microvolt = <1800000>;
508 regulator-max-microvolt = <1800000>;
509 regulator-enable-ramp-delay = <250>;
510 regulator-ramp-delay = <10>;
511 regulator-min-microamp = <200>;
512 regulator-max-microamp = <50000>;
513 regulator-system-load = <10000>;
514 regulator-allow-set-load;
518 regulator-min-microvolt = <3312000>;
519 regulator-max-microvolt = <3400000>;
520 regulator-enable-ramp-delay = <250>;
521 regulator-ramp-delay = <0>;
522 regulator-allow-set-load;
531 /* SoMC Nile platform's eMMC doesn't support HS200 mode */
534 mmc-hs400-enhanced-strobe;
536 vmmc-supply = <&vreg_l4b_29p5>;
537 vqmmc-supply = <&vreg_l8a_1p8>;
541 gpio-reserved-ranges = <8 4>;
543 imx300_vana_default: imx300-vana-default {
547 drive-strength = <2>;
550 imx219_vana_default: imx219-vana-default {
554 drive-strength = <2>;
557 cam_vdig_default: cam-vdig-default {
561 drive-strength = <2>;
570 dr_mode = "peripheral";
571 extcon = <&extcon_usb>;