1 // SPDX-License-Identifier: BSD-3-Clause
3 * Copyright (c) 2022, Lux Aliaga <they@mint.lgbt>
8 #include <dt-bindings/gpio/gpio.h>
9 #include <dt-bindings/input/input.h>
10 #include <dt-bindings/input/gpio-keys.h>
11 #include <dt-bindings/pinctrl/qcom,pmic-gpio.h>
12 #include "sm6125.dtsi"
13 #include "pm6125.dtsi"
16 model = "Xiaomi Mi A3";
17 compatible = "xiaomi,laurel-sprout", "qcom,sm6125";
18 chassis-type = "handset";
20 /* required for bootloader to select correct board */
21 qcom,msm-id = <394 0>; /* sm6125 v1 */
22 qcom,board-id = <11 0>;
29 framebuffer0: framebuffer@5c000000 {
30 compatible = "simple-framebuffer";
31 reg = <0 0x5c000000 0 (1560 * 720 * 4)>;
40 debug_mem: debug@ffb00000 {
41 reg = <0x0 0xffb00000 0x0 0xc0000>;
45 last_log_mem: lastlog@ffbc0000 {
46 reg = <0x0 0xffbc0000 0x0 0x80000>;
50 pstore_mem: ramoops@ffc00000 {
51 compatible = "ramoops";
52 reg = <0x0 0xffc40000 0x0 0xc0000>;
53 record-size = <0x1000>;
54 console-size = <0x40000>;
55 pmsg-size = <0x20000>;
58 cmdline_mem: memory@ffd00000 {
59 reg = <0x0 0xffd40000 0x0 0x1000>;
65 compatible = "linux,extcon-usb-gpio";
66 id-gpios = <&tlmm 102 GPIO_ACTIVE_HIGH>;
70 compatible = "gpio-keys";
72 pinctrl-0 = <&vol_up_n>;
73 pinctrl-names = "default";
77 gpios = <&pm6125_gpios 5 GPIO_ACTIVE_LOW>;
78 linux,code = <KEY_VOLUMEUP>;
79 debounce-interval = <15>;
87 polling-delay-passive = <0>;
89 thermal-sensors = <&pm6125_adc_tm 0>;
93 temperature = <125000>;
101 polling-delay-passive = <0>;
102 polling-delay = <5000>;
103 thermal-sensors = <&pm6125_adc_tm 1>;
107 temperature = <125000>;
115 polling-delay-passive = <0>;
117 thermal-sensors = <&pm6125_adc_tm 2>;
121 temperature = <125000>;
131 vdd-supply = <&vreg_l7a>;
132 vdda-pll-supply = <&vreg_l10a>;
133 vdda-phy-dpdm-supply = <&vreg_l15a>;
138 pinctrl-names = "default";
139 pinctrl-0 = <&camera_flash_therm &emmc_ufs_therm>;
142 reg = <ADC5_AMUX_THM1_100K_PU>;
144 qcom,hw-settle-time = <200>;
145 qcom,pre-scaling = <1 1>;
146 label = "rf_pa0_therm";
150 reg = <ADC5_AMUX_THM2_100K_PU>;
152 qcom,hw-settle-time = <200>;
153 qcom,pre-scaling = <1 1>;
154 label = "quiet_therm";
158 reg = <ADC5_GPIO1_100K_PU>;
160 qcom,hw-settle-time = <200>;
161 qcom,pre-scaling = <1 1>;
162 label = "camera_flash_therm";
166 reg = <ADC5_GPIO3_100K_PU>;
168 qcom,hw-settle-time = <200>;
169 qcom,pre-scaling = <1 1>;
170 label = "emmc_ufs_therm";
179 io-channels = <&pm6125_adc ADC5_AMUX_THM1_100K_PU>;
181 qcom,hw-settle-time-us = <200>;
186 io-channels = <&pm6125_adc ADC5_AMUX_THM2_100K_PU>;
188 qcom,hw-settle-time-us = <200>;
193 io-channels = <&pm6125_adc ADC5_XO_THERM_100K_PU>;
195 qcom,hw-settle-time-us = <200>;
200 camera_flash_therm: camera-flash-therm-state {
202 function = PMIC_GPIO_FUNC_NORMAL;
206 emmc_ufs_therm: emmc-ufs-therm-state {
208 function = PMIC_GPIO_FUNC_NORMAL;
212 vol_up_n: vol-up-n-state {
214 function = PMIC_GPIO_FUNC_NORMAL;
225 linux,code = <KEY_VOLUMEDOWN>;
231 compatible = "qcom,rpm-pm6125-regulators";
234 regulator-min-microvolt = <936000>;
235 regulator-max-microvolt = <1422000>;
239 regulator-min-microvolt = <1200000>;
240 regulator-max-microvolt = <1256000>;
244 regulator-min-microvolt = <1000000>;
245 regulator-max-microvolt = <1056000>;
249 regulator-min-microvolt = <1000000>;
250 regulator-max-microvolt = <1064000>;
254 regulator-min-microvolt = <872000>;
255 regulator-max-microvolt = <976000>;
256 regulator-allow-set-load;
260 regulator-min-microvolt = <1648000>;
261 regulator-max-microvolt = <2950000>;
262 regulator-allow-set-load;
266 regulator-min-microvolt = <576000>;
267 regulator-max-microvolt = <656000>;
271 regulator-min-microvolt = <872000>;
272 regulator-max-microvolt = <976000>;
276 regulator-min-microvolt = <400000>;
277 regulator-max-microvolt = <728000>;
281 regulator-min-microvolt = <1800000>;
282 regulator-max-microvolt = <1896000>;
286 regulator-min-microvolt = <1800000>;
287 regulator-max-microvolt = <1896000>;
288 regulator-allow-set-load;
292 regulator-min-microvolt = <1800000>;
293 regulator-max-microvolt = <1952000>;
294 regulator-allow-set-load;
298 regulator-min-microvolt = <1800000>;
299 regulator-max-microvolt = <1996000>;
303 regulator-min-microvolt = <1800000>;
304 regulator-max-microvolt = <1832000>;
308 regulator-min-microvolt = <1800000>;
309 regulator-max-microvolt = <1904000>;
313 regulator-min-microvolt = <3104000>;
314 regulator-max-microvolt = <3232000>;
318 regulator-min-microvolt = <1800000>;
319 regulator-max-microvolt = <1904000>;
323 regulator-min-microvolt = <1248000>;
324 regulator-max-microvolt = <1304000>;
328 regulator-min-microvolt = <1200000>;
329 regulator-max-microvolt = <1264000>;
330 regulator-allow-set-load;
334 regulator-min-microvolt = <1648000>;
335 regulator-max-microvolt = <2952000>;
339 regulator-min-microvolt = <1648000>;
340 regulator-max-microvolt = <2952000>;
344 regulator-min-microvolt = <2600000>;
345 regulator-max-microvolt = <2856000>;
349 regulator-min-microvolt = <2944000>;
350 regulator-max-microvolt = <2950000>;
351 regulator-allow-set-load;
355 regulator-min-microvolt = <3000000>;
356 regulator-max-microvolt = <3400000>;
360 regulator-min-microvolt = <2944000>;
361 regulator-max-microvolt = <2950000>;
362 regulator-allow-set-load;
371 drive-strength = <2>;
380 drive-strength = <2>;
386 cd-gpios = <&tlmm 98 GPIO_ACTIVE_HIGH>;
387 vmmc-supply = <&vreg_l22a>;
388 vqmmc-supply = <&vreg_l5a>;
395 gpio-reserved-ranges = <22 2>, <28 6>;
399 vcc-supply = <&vreg_l24a>;
400 vccq2-supply = <&vreg_l11a>;
401 vcc-max-microamp = <600000>;
402 vccq2-max-microamp = <600000>;
403 vdd-hba-supply = <&vreg_l18a>;
408 vdda-phy-supply = <&vreg_l4a>;
409 vdda-pll-supply = <&vreg_l10a>;
418 extcon = <&extcon_usb>;