blob: 99369a0cdb6163ce827258f2ef2deeb2c888daff [file] [log] [blame]
Tom Rini53633a82024-02-29 12:33:36 -05001// SPDX-License-Identifier: BSD-3-Clause
2
3#include <dt-bindings/iio/qcom,spmi-vadc.h>
4#include <dt-bindings/input/input.h>
5#include <dt-bindings/input/linux-event-codes.h>
6#include <dt-bindings/interrupt-controller/irq.h>
7#include <dt-bindings/spmi/spmi.h>
8
9/ {
10 thermal-zones {
11 pm6125-thermal {
12 polling-delay-passive = <100>;
13 polling-delay = <0>;
14
15 thermal-sensors = <&pm6125_temp>;
16
17 trips {
18 trip0 {
19 temperature = <95000>;
20 hysteresis = <0>;
21 type = "passive";
22 };
23
24 trip1 {
25 temperature = <115000>;
26 hysteresis = <0>;
27 type = "hot";
28 };
29
30 trip2 {
31 temperature = <145000>;
32 hysteresis = <0>;
33 type = "critical";
34 };
35 };
36 };
37 };
38};
39
40&spmi_bus {
41 pmic@0 {
42 compatible = "qcom,pm6125", "qcom,spmi-pmic";
43 reg = <0x0 SPMI_USID>;
44 #address-cells = <1>;
45 #size-cells = <0>;
46
47 pm6125_pon: pon@800 {
48 compatible = "qcom,pm8998-pon";
49 reg = <0x800>;
50 mode-bootloader = <0x2>;
51 mode-recovery = <0x1>;
52
53 pon_pwrkey: pwrkey {
54 compatible = "qcom,pm8941-pwrkey";
55 interrupts = <0x0 0x8 0x0 IRQ_TYPE_EDGE_BOTH>;
56 debounce = <15625>;
57 linux,code = <KEY_POWER>;
58 bias-pull-up;
59 status = "disabled";
60 };
61
62 pon_resin: resin {
63 compatible = "qcom,pm8941-resin";
64 interrupts = <0x0 0x8 0x1 IRQ_TYPE_EDGE_BOTH>;
65 debounce = <15625>;
66 bias-pull-up;
67 status = "disabled";
68 };
69 };
70
71 pm6125_temp: temp-alarm@2400 {
72 compatible = "qcom,spmi-temp-alarm";
73 reg = <0x2400>;
74 interrupts = <0x0 0x24 0x0 IRQ_TYPE_EDGE_RISING>;
75 io-channels = <&pm6125_adc ADC5_DIE_TEMP>;
76 io-channel-names = "thermal";
77 #thermal-sensor-cells = <0>;
78 };
79
80 pm6125_adc: adc@3100 {
81 compatible = "qcom,spmi-adc5";
82 reg = <0x3100>;
83 #address-cells = <1>;
84 #size-cells = <0>;
85 interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>;
86 #io-channel-cells = <1>;
87
88 channel@0 {
89 reg = <ADC5_REF_GND>;
90 qcom,pre-scaling = <1 1>;
91 label = "ref_gnd";
92 };
93
94 channel@1 {
95 reg = <ADC5_1P25VREF>;
96 qcom,pre-scaling = <1 1>;
97 label = "vref_1p25";
98 };
99
100 channel@6 {
101 reg = <ADC5_DIE_TEMP>;
102 qcom,pre-scaling = <1 1>;
103 label = "die_temp";
104 };
105
106 channel@83 {
107 reg = <ADC5_VPH_PWR>;
108 qcom,pre-scaling = <1 3>;
109 label = "vph_pwr";
110 };
111
112 channel@85 {
113 reg = <ADC5_VCOIN>;
114 qcom,pre-scaling = <1 3>;
115 label = "vcoin";
116 };
117
118 channel@4c {
119 reg = <ADC5_XO_THERM_100K_PU>;
120 qcom,pre-scaling = <1 1>;
121 qcom,hw-settle-time = <200>;
122 qcom,ratiometric;
123 label = "xo_therm";
124 };
125 };
126
127 pm6125_adc_tm: adc-tm@3500 {
128 compatible = "qcom,spmi-adc-tm5";
129 reg = <0x3500>;
130 interrupts = <0x0 0x35 0x0 IRQ_TYPE_EDGE_RISING>;
131 #address-cells = <1>;
132 #size-cells = <0>;
133 #thermal-sensor-cells = <1>;
134 status = "disabled";
135 };
136
137 pm6125_rtc: rtc@6000 {
138 compatible = "qcom,pm8941-rtc";
139 reg = <0x6000>, <0x6100>;
140 reg-names = "rtc", "alarm";
141 interrupts = <0x0 0x61 0x1 IRQ_TYPE_EDGE_RISING>;
142 status = "disabled";
143 };
144
145 pm6125_gpios: gpio@c000 {
146 compatible = "qcom,pm6125-gpio", "qcom,spmi-gpio";
147 reg = <0xc000>;
148 gpio-controller;
149 gpio-ranges = <&pm6125_gpios 0 0 9>;
150 #gpio-cells = <2>;
151 interrupt-controller;
152 #interrupt-cells = <2>;
153 };
154 };
155
156 pmic@1 {
157 compatible = "qcom,pm6125", "qcom,spmi-pmic";
158 reg = <0x1 SPMI_USID>;
159 };
160};