pm8921.dtsi (5c903b859aaced384c0cd01d515f3e43a115fd9e) pm8921.dtsi (2308f2df5b66c7ae5266c3d058fbb4c211de0e6a)
1// SPDX-License-Identifier: GPL-2.0
2
3&ssbi {
4 pm8921: pmic {
5 compatible = "qcom,pm8921";
6 #interrupt-cells = <2>;
7 interrupt-controller;
8 #address-cells = <1>;
9 #size-cells = <0>;
10
1// SPDX-License-Identifier: GPL-2.0
2
3&ssbi {
4 pm8921: pmic {
5 compatible = "qcom,pm8921";
6 #interrupt-cells = <2>;
7 interrupt-controller;
8 #address-cells = <1>;
9 #size-cells = <0>;
10
11 pm8921_gpio: gpio@150 {
12
13 compatible = "qcom,pm8921-gpio",
14 "qcom,ssbi-gpio";
15 reg = <0x150>;
16 interrupt-controller;
17 #interrupt-cells = <2>;
18 gpio-controller;
19 gpio-ranges = <&pm8921_gpio 0 0 44>;
20 #gpio-cells = <2>;
21
22 };
23
24 pm8921_mpps: mpps@50 {
25 compatible = "qcom,pm8921-mpp",
26 "qcom,ssbi-mpp";
27 reg = <0x50>;
28 gpio-controller;
29 #gpio-cells = <2>;
30 gpio-ranges = <&pm8921_mpps 0 0 12>;
31 interrupt-controller;
32 #interrupt-cells = <2>;
33 };
34
11 pwrkey@1c {
12 compatible = "qcom,pm8921-pwrkey";
13 reg = <0x1c>;
14 interrupt-parent = <&pm8921>;
15 interrupts = <50 IRQ_TYPE_EDGE_RISING>,
16 <51 IRQ_TYPE_EDGE_RISING>;
17 debounce = <15625>;
18 pull-up;

--- 12 unchanged lines hidden (view full) ---

31
32 rtc@11d {
33 compatible = "qcom,pm8921-rtc";
34 interrupt-parent = <&pm8921>;
35 interrupts = <39 IRQ_TYPE_EDGE_RISING>;
36 reg = <0x11d>;
37 allow-set-time;
38 };
35 pwrkey@1c {
36 compatible = "qcom,pm8921-pwrkey";
37 reg = <0x1c>;
38 interrupt-parent = <&pm8921>;
39 interrupts = <50 IRQ_TYPE_EDGE_RISING>,
40 <51 IRQ_TYPE_EDGE_RISING>;
41 debounce = <15625>;
42 pull-up;

--- 12 unchanged lines hidden (view full) ---

55
56 rtc@11d {
57 compatible = "qcom,pm8921-rtc";
58 interrupt-parent = <&pm8921>;
59 interrupts = <39 IRQ_TYPE_EDGE_RISING>;
60 reg = <0x11d>;
61 allow-set-time;
62 };
63
64 pm8921_xoadc: xoadc@197 {
65 compatible = "qcom,pm8921-adc";
66 reg = <0x197>;
67 interrupts-extended = <&pm8921 78 IRQ_TYPE_EDGE_RISING>;
68 #address-cells = <2>;
69 #size-cells = <0>;
70 #io-channel-cells = <2>;
71
72 vcoin: adc-channel@0 {
73 reg = <0x00 0x00>;
74 };
75
76 vbat: adc-channel@1 {
77 reg = <0x00 0x01>;
78 };
79
80 dcin: adc-channel@2 {
81 reg = <0x00 0x02>;
82 };
83
84 vph_pwr: adc-channel@4 {
85 reg = <0x00 0x04>;
86 };
87
88 batt_therm: adc-channel@8 {
89 reg = <0x00 0x08>;
90 };
91
92 batt_id: adc-channel@9 {
93 reg = <0x00 0x09>;
94 };
95
96 usb_vbus: adc-channel@a {
97 reg = <0x00 0x0a>;
98 };
99
100 die_temp: adc-channel@b {
101 reg = <0x00 0x0b>;
102 };
103
104 ref_625mv: adc-channel@c {
105 reg = <0x00 0x0c>;
106 };
107
108 ref_1250mv: adc-channel@d {
109 reg = <0x00 0x0d>;
110 };
111
112 chg_temp: adc-channel@e {
113 reg = <0x00 0x0e>;
114 };
115
116 ref_muxoff: adc-channel@f {
117 reg = <0x00 0x0f>;
118 };
119 };
39 };
40};
120 };
121};
122
123/ {
124 /*
125 * These channels from the ADC are simply hardware monitors.
126 * That is why the ADC is referred to as "HKADC" - HouseKeeping
127 * ADC.
128 */
129 iio-hwmon {
130 compatible = "iio-hwmon";
131 io-channels = <&pm8921_xoadc 0x00 0x01>, /* Battery */
132 <&pm8921_xoadc 0x00 0x02>, /* DC in (charger) */
133 <&pm8921_xoadc 0x00 0x04>, /* VPH the main system voltage */
134 <&pm8921_xoadc 0x00 0x0b>, /* Die temperature */
135 <&pm8921_xoadc 0x00 0x0c>, /* Reference voltage 1.25V */
136 <&pm8921_xoadc 0x00 0x0d>, /* Reference voltage 0.625V */
137 <&pm8921_xoadc 0x00 0x0e>; /* Charger temperature */
138 };
139};