Greg Kroah-Hartman | b244131 | 2017-11-01 15:07:57 +0100 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0 |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 2 | #include <dt-bindings/iio/qcom,spmi-vadc.h> |
| 3 | #include <dt-bindings/interrupt-controller/irq.h> |
Ivan T. Ivanov | c912789 | 2015-02-03 14:17:59 +0200 | [diff] [blame] | 4 | #include <dt-bindings/spmi/spmi.h> |
| 5 | |
| 6 | &spmi_bus { |
| 7 | |
Stephen Boyd | 134c544 | 2015-11-20 15:31:20 -0800 | [diff] [blame] | 8 | pm8941_0: pm8941@0 { |
| 9 | compatible = "qcom,pm8941", "qcom,spmi-pmic"; |
Ivan T. Ivanov | c912789 | 2015-02-03 14:17:59 +0200 | [diff] [blame] | 10 | reg = <0x0 SPMI_USID>; |
| 11 | #address-cells = <1>; |
| 12 | #size-cells = <0>; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 13 | |
| 14 | rtc@6000 { |
| 15 | compatible = "qcom,pm8941-rtc"; |
Stephen Boyd | 65d4e83 | 2015-11-25 14:27:36 -0800 | [diff] [blame] | 16 | reg = <0x6000>, |
| 17 | <0x6100>; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 18 | reg-names = "rtc", "alarm"; |
| 19 | interrupts = <0x0 0x61 0x1 IRQ_TYPE_EDGE_RISING>; |
| 20 | }; |
| 21 | |
| 22 | pwrkey@800 { |
| 23 | compatible = "qcom,pm8941-pwrkey"; |
Stephen Boyd | 65d4e83 | 2015-11-25 14:27:36 -0800 | [diff] [blame] | 24 | reg = <0x800>; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 25 | interrupts = <0x0 0x8 0 IRQ_TYPE_EDGE_BOTH>; |
| 26 | debounce = <15625>; |
| 27 | bias-pull-up; |
| 28 | }; |
| 29 | |
Stephen Boyd | 4ac5a20 | 2017-01-26 16:47:26 -0800 | [diff] [blame] | 30 | usb_id: misc@900 { |
| 31 | compatible = "qcom,pm8941-misc"; |
| 32 | reg = <0x900>; |
| 33 | interrupts = <0x0 0x9 0 IRQ_TYPE_EDGE_BOTH>; |
| 34 | interrupt-names = "usb_id"; |
| 35 | }; |
| 36 | |
| 37 | smbb: charger@1000 { |
Courtney Cavin | 982afd8 | 2015-07-30 10:53:57 -0700 | [diff] [blame] | 38 | compatible = "qcom,pm8941-charger"; |
Stephen Boyd | 65d4e83 | 2015-11-25 14:27:36 -0800 | [diff] [blame] | 39 | reg = <0x1000>; |
Courtney Cavin | 982afd8 | 2015-07-30 10:53:57 -0700 | [diff] [blame] | 40 | interrupts = <0x0 0x10 7 IRQ_TYPE_EDGE_BOTH>, |
| 41 | <0x0 0x10 5 IRQ_TYPE_EDGE_BOTH>, |
| 42 | <0x0 0x10 4 IRQ_TYPE_EDGE_BOTH>, |
| 43 | <0x0 0x12 1 IRQ_TYPE_EDGE_BOTH>, |
| 44 | <0x0 0x12 0 IRQ_TYPE_EDGE_BOTH>, |
| 45 | <0x0 0x13 2 IRQ_TYPE_EDGE_BOTH>, |
| 46 | <0x0 0x13 1 IRQ_TYPE_EDGE_BOTH>, |
| 47 | <0x0 0x14 1 IRQ_TYPE_EDGE_BOTH>; |
| 48 | interrupt-names = "chg-done", |
| 49 | "chg-fast", |
| 50 | "chg-trkl", |
| 51 | "bat-temp-ok", |
| 52 | "bat-present", |
| 53 | "chg-gone", |
| 54 | "usb-valid", |
| 55 | "dc-valid"; |
Bird, Tim | ffb35d4 | 2017-01-26 16:47:25 -0800 | [diff] [blame] | 56 | |
| 57 | usb-otg-in-supply = <&pm8941_5vs1>; |
| 58 | |
| 59 | chg_otg: otg-vbus { }; |
Courtney Cavin | 982afd8 | 2015-07-30 10:53:57 -0700 | [diff] [blame] | 60 | }; |
| 61 | |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 62 | pm8941_gpios: gpios@c000 { |
Stephen Boyd | 2ca9c2a4 | 2015-11-20 17:49:46 -0800 | [diff] [blame] | 63 | compatible = "qcom,pm8941-gpio", "qcom,spmi-gpio"; |
Stephen Boyd | 65d4e83 | 2015-11-25 14:27:36 -0800 | [diff] [blame] | 64 | reg = <0xc000>; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 65 | gpio-controller; |
| 66 | #gpio-cells = <2>; |
| 67 | interrupts = <0 0xc0 0 IRQ_TYPE_NONE>, |
| 68 | <0 0xc1 0 IRQ_TYPE_NONE>, |
| 69 | <0 0xc2 0 IRQ_TYPE_NONE>, |
| 70 | <0 0xc3 0 IRQ_TYPE_NONE>, |
| 71 | <0 0xc4 0 IRQ_TYPE_NONE>, |
| 72 | <0 0xc5 0 IRQ_TYPE_NONE>, |
| 73 | <0 0xc6 0 IRQ_TYPE_NONE>, |
| 74 | <0 0xc7 0 IRQ_TYPE_NONE>, |
| 75 | <0 0xc8 0 IRQ_TYPE_NONE>, |
| 76 | <0 0xc9 0 IRQ_TYPE_NONE>, |
| 77 | <0 0xca 0 IRQ_TYPE_NONE>, |
| 78 | <0 0xcb 0 IRQ_TYPE_NONE>, |
| 79 | <0 0xcc 0 IRQ_TYPE_NONE>, |
| 80 | <0 0xcd 0 IRQ_TYPE_NONE>, |
| 81 | <0 0xce 0 IRQ_TYPE_NONE>, |
| 82 | <0 0xcf 0 IRQ_TYPE_NONE>, |
| 83 | <0 0xd0 0 IRQ_TYPE_NONE>, |
| 84 | <0 0xd1 0 IRQ_TYPE_NONE>, |
| 85 | <0 0xd2 0 IRQ_TYPE_NONE>, |
| 86 | <0 0xd3 0 IRQ_TYPE_NONE>, |
| 87 | <0 0xd4 0 IRQ_TYPE_NONE>, |
| 88 | <0 0xd5 0 IRQ_TYPE_NONE>, |
| 89 | <0 0xd6 0 IRQ_TYPE_NONE>, |
| 90 | <0 0xd7 0 IRQ_TYPE_NONE>, |
| 91 | <0 0xd8 0 IRQ_TYPE_NONE>, |
| 92 | <0 0xd9 0 IRQ_TYPE_NONE>, |
| 93 | <0 0xda 0 IRQ_TYPE_NONE>, |
| 94 | <0 0xdb 0 IRQ_TYPE_NONE>, |
| 95 | <0 0xdc 0 IRQ_TYPE_NONE>, |
| 96 | <0 0xdd 0 IRQ_TYPE_NONE>, |
| 97 | <0 0xde 0 IRQ_TYPE_NONE>, |
| 98 | <0 0xdf 0 IRQ_TYPE_NONE>, |
| 99 | <0 0xe0 0 IRQ_TYPE_NONE>, |
| 100 | <0 0xe1 0 IRQ_TYPE_NONE>, |
| 101 | <0 0xe2 0 IRQ_TYPE_NONE>, |
| 102 | <0 0xe3 0 IRQ_TYPE_NONE>; |
Bhushan Shah | 73bae19 | 2016-07-29 11:39:07 +0530 | [diff] [blame] | 103 | |
| 104 | boost_bypass_n_pin: boost-bypass { |
| 105 | pins = "gpio21"; |
| 106 | function = "normal"; |
| 107 | }; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 108 | }; |
| 109 | |
| 110 | pm8941_mpps: mpps@a000 { |
Stephen Boyd | 2ca9c2a4 | 2015-11-20 17:49:46 -0800 | [diff] [blame] | 111 | compatible = "qcom,pm8941-mpp", "qcom,spmi-mpp"; |
Stephen Boyd | 65d4e83 | 2015-11-25 14:27:36 -0800 | [diff] [blame] | 112 | reg = <0xa000>; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 113 | gpio-controller; |
| 114 | #gpio-cells = <2>; |
| 115 | interrupts = <0 0xa0 0 IRQ_TYPE_NONE>, |
| 116 | <0 0xa1 0 IRQ_TYPE_NONE>, |
| 117 | <0 0xa2 0 IRQ_TYPE_NONE>, |
| 118 | <0 0xa3 0 IRQ_TYPE_NONE>, |
| 119 | <0 0xa4 0 IRQ_TYPE_NONE>, |
| 120 | <0 0xa5 0 IRQ_TYPE_NONE>, |
| 121 | <0 0xa6 0 IRQ_TYPE_NONE>, |
| 122 | <0 0xa7 0 IRQ_TYPE_NONE>; |
| 123 | }; |
| 124 | |
| 125 | pm8941_temp: temp-alarm@2400 { |
| 126 | compatible = "qcom,spmi-temp-alarm"; |
Stephen Boyd | 65d4e83 | 2015-11-25 14:27:36 -0800 | [diff] [blame] | 127 | reg = <0x2400>; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 128 | interrupts = <0 0x24 0 IRQ_TYPE_EDGE_RISING>; |
| 129 | io-channels = <&pm8941_vadc VADC_DIE_TEMP>; |
| 130 | io-channel-names = "thermal"; |
| 131 | #thermal-sensor-cells = <0>; |
| 132 | }; |
| 133 | |
| 134 | pm8941_vadc: vadc@3100 { |
| 135 | compatible = "qcom,spmi-vadc"; |
Stephen Boyd | 65d4e83 | 2015-11-25 14:27:36 -0800 | [diff] [blame] | 136 | reg = <0x3100>; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 137 | interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>; |
| 138 | #address-cells = <1>; |
| 139 | #size-cells = <0>; |
| 140 | #io-channel-cells = <1>; |
| 141 | |
Craig Tatlor | 296a364 | 2018-03-30 21:04:08 +0100 | [diff] [blame] | 142 | bat_temp { |
| 143 | reg = <VADC_LR_MUX1_BAT_THERM>; |
| 144 | }; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 145 | die_temp { |
| 146 | reg = <VADC_DIE_TEMP>; |
| 147 | }; |
| 148 | ref_625mv { |
| 149 | reg = <VADC_REF_625MV>; |
| 150 | }; |
| 151 | ref_1250v { |
| 152 | reg = <VADC_REF_1250MV>; |
| 153 | }; |
| 154 | ref_gnd { |
| 155 | reg = <VADC_GND_REF>; |
| 156 | }; |
| 157 | ref_vdd { |
| 158 | reg = <VADC_VDD_VADC>; |
| 159 | }; |
Craig Tatlor | 296a364 | 2018-03-30 21:04:08 +0100 | [diff] [blame] | 160 | vbat_sns { |
| 161 | reg = <VADC_VBAT_SNS>; |
| 162 | }; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 163 | }; |
| 164 | |
| 165 | pm8941_iadc: iadc@3600 { |
| 166 | compatible = "qcom,pm8941-iadc", "qcom,spmi-iadc"; |
Stephen Boyd | 65d4e83 | 2015-11-25 14:27:36 -0800 | [diff] [blame] | 167 | reg = <0x3600>; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 168 | interrupts = <0x0 0x36 0x0 IRQ_TYPE_EDGE_RISING>; |
| 169 | qcom,external-resistor-micro-ohms = <10000>; |
| 170 | }; |
Tim Bird | ccf97fe | 2015-07-16 16:55:33 -0700 | [diff] [blame] | 171 | |
| 172 | coincell@2800 { |
| 173 | compatible = "qcom,pm8941-coincell"; |
| 174 | reg = <0x2800>; |
| 175 | status = "disabled"; |
| 176 | }; |
Ivan T. Ivanov | c912789 | 2015-02-03 14:17:59 +0200 | [diff] [blame] | 177 | }; |
| 178 | |
Stephen Boyd | 134c544 | 2015-11-20 15:31:20 -0800 | [diff] [blame] | 179 | pm8941_1: pm8941@1 { |
| 180 | compatible = "qcom,pm8941", "qcom,spmi-pmic"; |
Ivan T. Ivanov | c912789 | 2015-02-03 14:17:59 +0200 | [diff] [blame] | 181 | reg = <0x1 SPMI_USID>; |
| 182 | #address-cells = <1>; |
| 183 | #size-cells = <0>; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 184 | |
Bjorn Andersson | 7026d15 | 2015-11-23 11:04:07 -0800 | [diff] [blame] | 185 | pm8941_wled: wled@d800 { |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 186 | compatible = "qcom,pm8941-wled"; |
Stephen Boyd | 65d4e83 | 2015-11-25 14:27:36 -0800 | [diff] [blame] | 187 | reg = <0xd800>; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 188 | label = "backlight"; |
| 189 | |
Bjorn Andersson | 7026d15 | 2015-11-23 11:04:07 -0800 | [diff] [blame] | 190 | status = "disabled"; |
Ivan T. Ivanov | 635ecad | 2015-04-20 10:45:36 +0300 | [diff] [blame] | 191 | }; |
Stephen Boyd | 4ac5a20 | 2017-01-26 16:47:26 -0800 | [diff] [blame] | 192 | |
| 193 | regulators { |
| 194 | compatible = "qcom,pm8941-regulators"; |
| 195 | interrupts = <0x1 0x83 0x2 0>, <0x1 0x84 0x2 0>; |
| 196 | interrupt-names = "ocp-5vs1", "ocp-5vs2"; |
| 197 | vin_5vs-supply = <&pm8941_5v>; |
| 198 | |
| 199 | pm8941_5v: s4 { |
| 200 | regulator-min-microvolt = <5000000>; |
| 201 | regulator-max-microvolt = <5000000>; |
| 202 | regulator-enable-ramp-delay = <500>; |
| 203 | }; |
| 204 | |
| 205 | pm8941_5vs1: 5vs1 { |
| 206 | regulator-enable-ramp-delay = <1000>; |
| 207 | regulator-pull-down; |
| 208 | regulator-over-current-protection; |
| 209 | qcom,ocp-max-retries = <10>; |
| 210 | qcom,ocp-retry-delay = <30>; |
| 211 | qcom,vs-soft-start-strength = <0>; |
| 212 | regulator-initial-mode = <1>; |
| 213 | }; |
| 214 | }; |
Ivan T. Ivanov | c912789 | 2015-02-03 14:17:59 +0200 | [diff] [blame] | 215 | }; |
| 216 | }; |