David Collins | bbed9aa | 2017-03-10 11:53:10 -0800 | [diff] [blame] | 1 | /* Copyright (c) 2016-2017, The Linux Foundation. All rights reserved. |
| 2 | * |
| 3 | * This program is free software; you can redistribute it and/or modify |
| 4 | * it under the terms of the GNU General Public License version 2 and |
| 5 | * only version 2 as published by the Free Software Foundation. |
| 6 | * |
| 7 | * This program is distributed in the hope that it will be useful, |
| 8 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 9 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 10 | * GNU General Public License for more details. |
| 11 | */ |
| 12 | |
| 13 | #include <dt-bindings/spmi/spmi.h> |
| 14 | #include <dt-bindings/interrupt-controller/irq.h> |
| 15 | |
| 16 | &spmi_bus { |
| 17 | qcom,pmi8998@2 { |
| 18 | compatible = "qcom,spmi-pmic"; |
| 19 | reg = <0x2 SPMI_USID>; |
| 20 | #address-cells = <2>; |
| 21 | #size-cells = <0>; |
| 22 | |
| 23 | pmi8998_revid: qcom,revid@100 { |
| 24 | compatible = "qcom,qpnp-revid"; |
| 25 | reg = <0x100 0x100>; |
| 26 | qcom,fab-id-valid; |
| 27 | }; |
| 28 | |
| 29 | qcom,power-on@800 { |
| 30 | compatible = "qcom,qpnp-power-on"; |
| 31 | reg = <0x800 0x100>; |
| 32 | }; |
| 33 | |
Ram Chandrasekar | 9920cf0 | 2017-04-21 17:38:51 -0600 | [diff] [blame] | 34 | pmi8998_tz: qcom,temp-alarm@2400 { |
David Collins | bbed9aa | 2017-03-10 11:53:10 -0800 | [diff] [blame] | 35 | compatible = "qcom,qpnp-temp-alarm"; |
| 36 | reg = <0x2400 0x100>; |
| 37 | interrupts = <0x2 0x24 0x0 IRQ_TYPE_EDGE_RISING>; |
| 38 | label = "pmi8998_tz"; |
Ram Chandrasekar | 9920cf0 | 2017-04-21 17:38:51 -0600 | [diff] [blame] | 39 | #thermal-sensor-cells = <0>; |
David Collins | bbed9aa | 2017-03-10 11:53:10 -0800 | [diff] [blame] | 40 | }; |
| 41 | |
Fenglin Wu | 5a50fc8 | 2017-03-22 12:27:31 +0800 | [diff] [blame] | 42 | pmi8998_gpios: pinctrl@c000 { |
| 43 | compatible = "qcom,spmi-gpio"; |
| 44 | reg = <0xc000 0xe00>; |
| 45 | interrupts = <0x2 0xc0 0 IRQ_TYPE_NONE>, |
| 46 | <0x2 0xc1 0 IRQ_TYPE_NONE>, |
| 47 | <0x2 0xc2 0 IRQ_TYPE_NONE>, |
| 48 | <0x2 0xc4 0 IRQ_TYPE_NONE>, |
| 49 | <0x2 0xc5 0 IRQ_TYPE_NONE>, |
| 50 | <0x2 0xc7 0 IRQ_TYPE_NONE>, |
| 51 | <0x2 0xc8 0 IRQ_TYPE_NONE>, |
| 52 | <0x2 0xc9 0 IRQ_TYPE_NONE>, |
| 53 | <0x2 0xca 0 IRQ_TYPE_NONE>, |
| 54 | <0x2 0xcb 0 IRQ_TYPE_NONE>, |
| 55 | <0x2 0xcd 0 IRQ_TYPE_NONE>; |
| 56 | interrupt-names = "pmi8998_gpio1", "pmi8998_gpio2", |
| 57 | "pmi8998_gpio3", "pmi8998_gpio5", |
| 58 | "pmi8998_gpio6", "pmi8998_gpio8", |
| 59 | "pmi8998_gpio9", "pmi8998_gpio10", |
| 60 | "pmi8998_gpio11", "pmi8998_gpio12", |
| 61 | "pmi8998_gpio14"; |
David Collins | bbed9aa | 2017-03-10 11:53:10 -0800 | [diff] [blame] | 62 | gpio-controller; |
| 63 | #gpio-cells = <2>; |
Fenglin Wu | 5a50fc8 | 2017-03-22 12:27:31 +0800 | [diff] [blame] | 64 | qcom,gpios-disallowed = <4 7 13>; |
David Collins | bbed9aa | 2017-03-10 11:53:10 -0800 | [diff] [blame] | 65 | }; |
| 66 | |
Harry Yang | 6711166 | 2017-04-05 15:14:52 -0700 | [diff] [blame] | 67 | qcom,qpnp-qnovo@1500 { |
| 68 | compatible = "qcom,qpnp-qnovo"; |
| 69 | reg = <0x1500 0x100>; |
| 70 | interrupts = <0x2 0x15 0x0 IRQ_TYPE_NONE>; |
| 71 | interrupt-names = "ptrain-done"; |
| 72 | qcom,pmic-revid = <&pmi8998_revid>; |
| 73 | }; |
| 74 | |
| 75 | pmi8998_charger: qcom,qpnp-smb2 { |
| 76 | compatible = "qcom,qpnp-smb2"; |
| 77 | #address-cells = <1>; |
| 78 | #size-cells = <1>; |
Ram Chandrasekar | 977f844 | 2017-05-11 13:48:53 -0600 | [diff] [blame] | 79 | #cooling-cells = <2>; |
Harry Yang | 6711166 | 2017-04-05 15:14:52 -0700 | [diff] [blame] | 80 | |
| 81 | qcom,pmic-revid = <&pmi8998_revid>; |
| 82 | |
| 83 | io-channels = <&pmi8998_rradc 8>, |
| 84 | <&pmi8998_rradc 10>, |
| 85 | <&pmi8998_rradc 3>, |
| 86 | <&pmi8998_rradc 4>; |
| 87 | io-channel-names = "charger_temp", |
| 88 | "charger_temp_max", |
| 89 | "usbin_i", |
| 90 | "usbin_v"; |
| 91 | |
| 92 | qcom,boost-threshold-ua = <100000>; |
| 93 | qcom,wipower-max-uw = <5000000>; |
| 94 | |
| 95 | qcom,thermal-mitigation |
| 96 | = <3000000 1500000 1000000 500000>; |
| 97 | |
| 98 | qcom,chgr@1000 { |
| 99 | reg = <0x1000 0x100>; |
| 100 | interrupts = |
| 101 | <0x2 0x10 0x0 IRQ_TYPE_EDGE_RISING>, |
| 102 | <0x2 0x10 0x1 IRQ_TYPE_EDGE_RISING>, |
| 103 | <0x2 0x10 0x2 IRQ_TYPE_EDGE_RISING>, |
| 104 | <0x2 0x10 0x3 IRQ_TYPE_EDGE_RISING>, |
| 105 | <0x2 0x10 0x4 IRQ_TYPE_EDGE_RISING>; |
| 106 | |
| 107 | interrupt-names = "chg-error", |
| 108 | "chg-state-change", |
| 109 | "step-chg-state-change", |
| 110 | "step-chg-soc-update-fail", |
| 111 | "step-chg-soc-update-request"; |
| 112 | }; |
| 113 | |
| 114 | qcom,otg@1100 { |
| 115 | reg = <0x1100 0x100>; |
| 116 | interrupts = <0x2 0x11 0x0 IRQ_TYPE_EDGE_BOTH>, |
| 117 | <0x2 0x11 0x1 IRQ_TYPE_EDGE_BOTH>, |
| 118 | <0x2 0x11 0x2 IRQ_TYPE_EDGE_BOTH>, |
| 119 | <0x2 0x11 0x3 IRQ_TYPE_EDGE_BOTH>; |
| 120 | |
| 121 | interrupt-names = "otg-fail", |
| 122 | "otg-overcurrent", |
| 123 | "otg-oc-dis-sw-sts", |
| 124 | "testmode-change-detect"; |
| 125 | }; |
| 126 | |
| 127 | qcom,bat-if@1200 { |
| 128 | reg = <0x1200 0x100>; |
| 129 | interrupts = |
| 130 | <0x2 0x12 0x0 IRQ_TYPE_EDGE_RISING>, |
| 131 | <0x2 0x12 0x1 IRQ_TYPE_EDGE_BOTH>, |
| 132 | <0x2 0x12 0x2 IRQ_TYPE_EDGE_BOTH>, |
| 133 | <0x2 0x12 0x3 IRQ_TYPE_EDGE_BOTH>, |
| 134 | <0x2 0x12 0x4 IRQ_TYPE_EDGE_BOTH>, |
| 135 | <0x2 0x12 0x5 IRQ_TYPE_EDGE_BOTH>; |
| 136 | |
| 137 | interrupt-names = "bat-temp", |
| 138 | "bat-ocp", |
| 139 | "bat-ov", |
| 140 | "bat-low", |
| 141 | "bat-therm-or-id-missing", |
| 142 | "bat-terminal-missing"; |
| 143 | }; |
| 144 | |
| 145 | qcom,usb-chgpth@1300 { |
| 146 | reg = <0x1300 0x100>; |
| 147 | interrupts = |
| 148 | <0x2 0x13 0x0 IRQ_TYPE_EDGE_BOTH>, |
| 149 | <0x2 0x13 0x1 IRQ_TYPE_EDGE_BOTH>, |
| 150 | <0x2 0x13 0x2 IRQ_TYPE_EDGE_BOTH>, |
| 151 | <0x2 0x13 0x3 IRQ_TYPE_EDGE_BOTH>, |
| 152 | <0x2 0x13 0x4 IRQ_TYPE_EDGE_BOTH>, |
| 153 | <0x2 0x13 0x5 IRQ_TYPE_EDGE_RISING>, |
| 154 | <0x2 0x13 0x6 IRQ_TYPE_EDGE_RISING>, |
| 155 | <0x2 0x13 0x7 IRQ_TYPE_EDGE_RISING>; |
| 156 | |
| 157 | interrupt-names = "usbin-collapse", |
| 158 | "usbin-lt-3p6v", |
| 159 | "usbin-uv", |
| 160 | "usbin-ov", |
| 161 | "usbin-plugin", |
| 162 | "usbin-src-change", |
| 163 | "usbin-icl-change", |
| 164 | "type-c-change"; |
| 165 | }; |
| 166 | |
| 167 | qcom,dc-chgpth@1400 { |
| 168 | reg = <0x1400 0x100>; |
| 169 | interrupts = |
| 170 | <0x2 0x14 0x0 IRQ_TYPE_EDGE_BOTH>, |
| 171 | <0x2 0x14 0x1 IRQ_TYPE_EDGE_BOTH>, |
| 172 | <0x2 0x14 0x2 IRQ_TYPE_EDGE_BOTH>, |
| 173 | <0x2 0x14 0x3 IRQ_TYPE_EDGE_BOTH>, |
| 174 | <0x2 0x14 0x4 IRQ_TYPE_EDGE_BOTH>, |
| 175 | <0x2 0x14 0x5 IRQ_TYPE_EDGE_BOTH>, |
| 176 | <0x2 0x14 0x6 IRQ_TYPE_EDGE_RISING>; |
| 177 | |
| 178 | interrupt-names = "dcin-collapse", |
| 179 | "dcin-lt-3p6v", |
| 180 | "dcin-uv", |
| 181 | "dcin-ov", |
| 182 | "dcin-plugin", |
| 183 | "div2-en-dg", |
| 184 | "dcin-icl-change"; |
| 185 | }; |
| 186 | |
| 187 | qcom,chgr-misc@1600 { |
| 188 | reg = <0x1600 0x100>; |
| 189 | interrupts = |
| 190 | <0x2 0x16 0x0 IRQ_TYPE_EDGE_RISING>, |
| 191 | <0x2 0x16 0x1 IRQ_TYPE_EDGE_RISING>, |
| 192 | <0x2 0x16 0x2 IRQ_TYPE_EDGE_BOTH>, |
| 193 | <0x2 0x16 0x3 IRQ_TYPE_EDGE_BOTH>, |
| 194 | <0x2 0x16 0x4 IRQ_TYPE_EDGE_BOTH>, |
| 195 | <0x2 0x16 0x5 IRQ_TYPE_EDGE_BOTH>, |
| 196 | <0x2 0x16 0x6 IRQ_TYPE_EDGE_FALLING>, |
| 197 | <0x2 0x16 0x7 IRQ_TYPE_EDGE_BOTH>; |
| 198 | |
| 199 | interrupt-names = "wdog-snarl", |
| 200 | "wdog-bark", |
| 201 | "aicl-fail", |
| 202 | "aicl-done", |
| 203 | "high-duty-cycle", |
| 204 | "input-current-limiting", |
| 205 | "temperature-change", |
| 206 | "switcher-power-ok"; |
| 207 | }; |
| 208 | }; |
| 209 | |
Jack Pham | af5edc8 | 2017-03-30 17:26:02 -0700 | [diff] [blame] | 210 | pmi8998_pdphy: qcom,usb-pdphy@1700 { |
| 211 | compatible = "qcom,qpnp-pdphy"; |
| 212 | reg = <0x1700 0x100>; |
| 213 | vdd-pdphy-supply = <&pm8998_l24>; |
Harry Yang | 4c05d3e4 | 2017-05-09 16:18:17 -0700 | [diff] [blame] | 214 | vbus-supply = <&ext_5v_boost>; |
Jack Pham | af5edc8 | 2017-03-30 17:26:02 -0700 | [diff] [blame] | 215 | vconn-supply = <&smb2_vconn>; |
| 216 | interrupts = <0x2 0x17 0x0 IRQ_TYPE_EDGE_RISING>, |
| 217 | <0x2 0x17 0x1 IRQ_TYPE_EDGE_RISING>, |
| 218 | <0x2 0x17 0x2 IRQ_TYPE_EDGE_RISING>, |
| 219 | <0x2 0x17 0x3 IRQ_TYPE_EDGE_RISING>, |
| 220 | <0x2 0x17 0x4 IRQ_TYPE_EDGE_RISING>, |
| 221 | <0x2 0x17 0x5 IRQ_TYPE_EDGE_RISING>, |
| 222 | <0x2 0x17 0x6 IRQ_TYPE_EDGE_RISING>; |
| 223 | |
| 224 | interrupt-names = "sig-tx", |
| 225 | "sig-rx", |
| 226 | "msg-tx", |
| 227 | "msg-rx", |
| 228 | "msg-tx-failed", |
| 229 | "msg-tx-discarded", |
| 230 | "msg-rx-discarded"; |
| 231 | |
| 232 | qcom,default-sink-caps = <5000 3000>, /* 5V @ 3A */ |
| 233 | <9000 3000>, /* 9V @ 3A */ |
| 234 | <12000 2250>; /* 12V @ 2.25A */ |
| 235 | }; |
| 236 | |
Ram Chandrasekar | 61ede0c | 2017-04-17 17:12:56 -0600 | [diff] [blame] | 237 | bcl_sensor: bcl@4200 { |
| 238 | compatible = "qcom,msm-bcl-lmh"; |
| 239 | reg = <0x4200 0xff>, |
| 240 | <0x4300 0xff>; |
| 241 | reg-names = "fg_user_adc", |
| 242 | "fg_lmh"; |
| 243 | interrupts = <0x2 0x42 0x0 IRQ_TYPE_NONE>, |
| 244 | <0x2 0x42 0x1 IRQ_TYPE_NONE>, |
| 245 | <0x2 0x42 0x2 IRQ_TYPE_NONE>, |
| 246 | <0x2 0x42 0x3 IRQ_TYPE_NONE>, |
| 247 | <0x2 0x42 0x4 IRQ_TYPE_NONE>; |
| 248 | interrupt-names = "bcl-high-ibat", |
| 249 | "bcl-very-high-ibat", |
| 250 | "bcl-low-vbat", |
| 251 | "bcl-very-low-vbat", |
| 252 | "bcl-crit-low-vbat"; |
| 253 | #thermal-sensor-cells = <1>; |
| 254 | }; |
| 255 | |
David Collins | bbed9aa | 2017-03-10 11:53:10 -0800 | [diff] [blame] | 256 | pmi8998_rradc: rradc@4500 { |
| 257 | compatible = "qcom,rradc"; |
| 258 | reg = <0x4500 0x100>; |
| 259 | #address-cells = <1>; |
| 260 | #size-cells = <0>; |
| 261 | #io-channel-cells = <1>; |
| 262 | qcom,pmic-revid = <&pmi8998_revid>; |
| 263 | }; |
Harry Yang | 6711166 | 2017-04-05 15:14:52 -0700 | [diff] [blame] | 264 | |
| 265 | pmi8998_fg: qpnp,fg { |
| 266 | compatible = "qcom,fg-gen3"; |
| 267 | #address-cells = <1>; |
| 268 | #size-cells = <1>; |
| 269 | qcom,pmic-revid = <&pmi8998_revid>; |
| 270 | io-channels = <&pmi8998_rradc 0>; |
| 271 | io-channel-names = "rradc_batt_id"; |
| 272 | qcom,rradc-base = <0x4500>; |
Subbaraman Narayanamurthy | 784bd5b | 2017-05-17 17:43:22 -0700 | [diff] [blame^] | 273 | qcom,fg-esr-timer-awake = <96 96>; |
| 274 | qcom,fg-esr-timer-asleep = <256 256>; |
| 275 | qcom,fg-esr-timer-charging = <0 96>; |
Harry Yang | 6711166 | 2017-04-05 15:14:52 -0700 | [diff] [blame] | 276 | qcom,cycle-counter-en; |
| 277 | status = "okay"; |
| 278 | |
| 279 | qcom,fg-batt-soc@4000 { |
| 280 | status = "okay"; |
| 281 | reg = <0x4000 0x100>; |
| 282 | interrupts = <0x2 0x40 0x0 IRQ_TYPE_EDGE_BOTH>, |
| 283 | <0x2 0x40 0x1 IRQ_TYPE_EDGE_BOTH>, |
| 284 | <0x2 0x40 0x2 |
| 285 | IRQ_TYPE_EDGE_RISING>, |
| 286 | <0x2 0x40 0x3 |
| 287 | IRQ_TYPE_EDGE_RISING>, |
| 288 | <0x2 0x40 0x4 IRQ_TYPE_EDGE_BOTH>, |
| 289 | <0x2 0x40 0x5 |
| 290 | IRQ_TYPE_EDGE_RISING>, |
| 291 | <0x2 0x40 0x6 IRQ_TYPE_EDGE_BOTH>, |
| 292 | <0x2 0x40 0x7 IRQ_TYPE_EDGE_BOTH>; |
| 293 | interrupt-names = "soc-update", |
| 294 | "soc-ready", |
| 295 | "bsoc-delta", |
| 296 | "msoc-delta", |
| 297 | "msoc-low", |
| 298 | "msoc-empty", |
| 299 | "msoc-high", |
| 300 | "msoc-full"; |
| 301 | }; |
| 302 | |
| 303 | qcom,fg-batt-info@4100 { |
| 304 | status = "okay"; |
| 305 | reg = <0x4100 0x100>; |
| 306 | interrupts = <0x2 0x41 0x0 IRQ_TYPE_EDGE_BOTH>, |
| 307 | <0x2 0x41 0x1 IRQ_TYPE_EDGE_BOTH>, |
| 308 | <0x2 0x41 0x2 IRQ_TYPE_EDGE_BOTH>, |
| 309 | <0x2 0x41 0x3 IRQ_TYPE_EDGE_BOTH>, |
| 310 | <0x2 0x41 0x6 IRQ_TYPE_EDGE_BOTH>; |
| 311 | interrupt-names = "vbatt-pred-delta", |
| 312 | "vbatt-low", |
| 313 | "esr-delta", |
| 314 | "batt-missing", |
| 315 | "batt-temp-delta"; |
| 316 | }; |
| 317 | |
| 318 | qcom,fg-memif@4400 { |
| 319 | status = "okay"; |
| 320 | reg = <0x4400 0x100>; |
| 321 | interrupts = <0x2 0x44 0x0 IRQ_TYPE_EDGE_BOTH>, |
| 322 | <0x2 0x44 0x1 IRQ_TYPE_EDGE_BOTH>, |
| 323 | <0x2 0x44 0x2 IRQ_TYPE_EDGE_BOTH>; |
| 324 | interrupt-names = "ima-rdy", |
| 325 | "mem-xcp", |
| 326 | "dma-grant"; |
| 327 | }; |
| 328 | }; |
David Collins | bbed9aa | 2017-03-10 11:53:10 -0800 | [diff] [blame] | 329 | }; |
| 330 | |
| 331 | qcom,pmi8998@3 { |
| 332 | compatible ="qcom,spmi-pmic"; |
| 333 | reg = <0x3 SPMI_USID>; |
| 334 | #address-cells = <2>; |
| 335 | #size-cells = <0>; |
| 336 | |
| 337 | pmi8998_pwm_1: pwm@b100 { |
| 338 | compatible = "qcom,qpnp-pwm"; |
| 339 | reg = <0xb100 0x100>, |
| 340 | <0xb042 0x7e>; |
| 341 | reg-names = "qpnp-lpg-channel-base", |
| 342 | "qpnp-lpg-lut-base"; |
| 343 | qcom,lpg-lut-size = <0x7e>; |
| 344 | qcom,channel-id = <1>; |
| 345 | qcom,supported-sizes = <6>, <9>; |
| 346 | qcom,ramp-index = <0>; |
| 347 | #pwm-cells = <2>; |
| 348 | status = "disabled"; |
| 349 | }; |
| 350 | |
| 351 | pmi8998_pwm_2: pwm@b200 { |
| 352 | compatible = "qcom,qpnp-pwm"; |
| 353 | reg = <0xb200 0x100>, |
| 354 | <0xb042 0x7e>; |
| 355 | reg-names = "qpnp-lpg-channel-base", |
| 356 | "qpnp-lpg-lut-base"; |
| 357 | qcom,lpg-lut-size = <0x7e>; |
| 358 | qcom,channel-id = <2>; |
| 359 | qcom,supported-sizes = <6>, <9>; |
| 360 | qcom,ramp-index = <1>; |
| 361 | #pwm-cells = <2>; |
| 362 | status = "disabled"; |
| 363 | }; |
| 364 | |
| 365 | pmi8998_pwm_3: pwm@b300 { |
| 366 | compatible = "qcom,qpnp-pwm"; |
| 367 | reg = <0xb300 0x100>, |
| 368 | <0xb042 0x7e>; |
| 369 | reg-names = "qpnp-lpg-channel-base", |
| 370 | "qpnp-lpg-lut-base"; |
| 371 | qcom,lpg-lut-size = <0x7e>; |
| 372 | qcom,channel-id = <3>; |
| 373 | qcom,supported-sizes = <6>, <9>; |
| 374 | qcom,ramp-index = <2>; |
| 375 | #pwm-cells = <2>; |
| 376 | }; |
| 377 | |
| 378 | pmi8998_pwm_4: pwm@b400 { |
| 379 | compatible = "qcom,qpnp-pwm"; |
| 380 | reg = <0xb400 0x100>, |
| 381 | <0xb042 0x7e>; |
| 382 | reg-names = "qpnp-lpg-channel-base", |
| 383 | "qpnp-lpg-lut-base"; |
| 384 | qcom,lpg-lut-size = <0x7e>; |
| 385 | qcom,channel-id = <4>; |
| 386 | qcom,supported-sizes = <6>, <9>; |
| 387 | qcom,ramp-index = <3>; |
| 388 | #pwm-cells = <2>; |
| 389 | }; |
| 390 | |
| 391 | pmi8998_pwm_5: pwm@b500 { |
| 392 | compatible = "qcom,qpnp-pwm"; |
| 393 | reg = <0xb500 0x100>, |
| 394 | <0xb042 0x7e>; |
| 395 | reg-names = "qpnp-lpg-channel-base", |
| 396 | "qpnp-lpg-lut-base"; |
| 397 | qcom,lpg-lut-size = <0x7e>; |
| 398 | qcom,channel-id = <5>; |
| 399 | qcom,supported-sizes = <6>, <9>; |
| 400 | qcom,ramp-index = <4>; |
| 401 | #pwm-cells = <2>; |
| 402 | }; |
| 403 | |
| 404 | pmi8998_pwm_6: pwm@b600 { |
| 405 | compatible = "qcom,qpnp-pwm"; |
| 406 | reg = <0xb600 0x100>, |
| 407 | <0xb042 0x7e>; |
| 408 | reg-names = "qpnp-lpg-channel-base", |
| 409 | "qpnp-lpg-lut-base"; |
| 410 | qcom,lpg-lut-size = <0x7e>; |
| 411 | qcom,channel-id = <6>; |
| 412 | qcom,supported-sizes = <6>, <9>; |
| 413 | qcom,ramp-index = <5>; |
| 414 | #pwm-cells = <2>; |
| 415 | status = "disabled"; |
| 416 | }; |
| 417 | |
| 418 | qcom,leds@d000 { |
| 419 | compatible = "qcom,leds-qpnp"; |
| 420 | reg = <0xd000 0x100>; |
| 421 | label = "rgb"; |
| 422 | status = "okay"; |
| 423 | |
| 424 | red_led: qcom,rgb_0 { |
| 425 | label = "rgb"; |
| 426 | qcom,id = <3>; |
| 427 | qcom,mode = "pwm"; |
| 428 | pwms = <&pmi8998_pwm_5 0 0>; |
| 429 | qcom,pwm-us = <1000>; |
| 430 | qcom,max-current = <12>; |
| 431 | qcom,default-state = "off"; |
| 432 | linux,name = "red"; |
| 433 | linux,default-trigger = "battery-charging"; |
| 434 | }; |
| 435 | |
| 436 | green_led: qcom,rgb_1 { |
| 437 | label = "rgb"; |
| 438 | qcom,id = <4>; |
| 439 | qcom,mode = "pwm"; |
| 440 | pwms = <&pmi8998_pwm_4 0 0>; |
| 441 | qcom,pwm-us = <1000>; |
| 442 | qcom,max-current = <12>; |
| 443 | qcom,default-state = "off"; |
| 444 | linux,name = "green"; |
| 445 | linux,default-trigger = "battery-full"; |
| 446 | }; |
| 447 | |
| 448 | blue_led: qcom,rgb_2 { |
| 449 | label = "rgb"; |
| 450 | qcom,id = <5>; |
| 451 | qcom,mode = "pwm"; |
| 452 | pwms = <&pmi8998_pwm_3 0 0>; |
| 453 | qcom,pwm-us = <1000>; |
| 454 | qcom,max-current = <12>; |
| 455 | qcom,default-state = "off"; |
| 456 | linux,name = "blue"; |
| 457 | linux,default-trigger = "boot-indication"; |
| 458 | }; |
| 459 | }; |
| 460 | |
| 461 | labibb: qpnp-labibb-regulator { |
| 462 | compatible = "qcom,qpnp-labibb-regulator"; |
| 463 | #address-cells = <1>; |
| 464 | #size-cells = <1>; |
| 465 | qcom,pmic-revid = <&pmi8998_revid>; |
| 466 | status = "disabled"; |
| 467 | |
| 468 | ibb_regulator: qcom,ibb@dc00 { |
| 469 | reg = <0xdc00 0x100>; |
| 470 | reg-names = "ibb_reg"; |
| 471 | regulator-name = "ibb_reg"; |
| 472 | |
| 473 | regulator-min-microvolt = <4600000>; |
| 474 | regulator-max-microvolt = <6000000>; |
| 475 | |
| 476 | qcom,qpnp-ibb-min-voltage = <1400000>; |
| 477 | qcom,qpnp-ibb-step-size = <100000>; |
| 478 | qcom,qpnp-ibb-slew-rate = <2000000>; |
| 479 | qcom,qpnp-ibb-use-default-voltage; |
| 480 | qcom,qpnp-ibb-init-voltage = <5500000>; |
| 481 | qcom,qpnp-ibb-init-amoled-voltage = <4000000>; |
| 482 | qcom,qpnp-ibb-init-lcd-voltage = <5500000>; |
| 483 | |
| 484 | qcom,qpnp-ibb-soft-start = <1000>; |
| 485 | |
| 486 | qcom,qpnp-ibb-lab-pwrup-delay = <8000>; |
| 487 | qcom,qpnp-ibb-lab-pwrdn-delay = <8000>; |
| 488 | qcom,qpnp-ibb-en-discharge; |
| 489 | |
| 490 | qcom,qpnp-ibb-full-pull-down; |
| 491 | qcom,qpnp-ibb-pull-down-enable; |
| 492 | qcom,qpnp-ibb-switching-clock-frequency = |
| 493 | <1480>; |
| 494 | qcom,qpnp-ibb-limit-maximum-current = <1550>; |
| 495 | qcom,qpnp-ibb-debounce-cycle = <16>; |
| 496 | qcom,qpnp-ibb-limit-max-current-enable; |
| 497 | qcom,qpnp-ibb-ps-enable; |
| 498 | }; |
| 499 | |
| 500 | lab_regulator: qcom,lab@de00 { |
| 501 | reg = <0xde00 0x100>; |
| 502 | reg-names = "lab"; |
| 503 | regulator-name = "lab_reg"; |
| 504 | |
| 505 | regulator-min-microvolt = <4600000>; |
| 506 | regulator-max-microvolt = <6000000>; |
| 507 | |
| 508 | interrupts = <0x3 0xde 0x0 |
| 509 | IRQ_TYPE_EDGE_RISING>; |
| 510 | interrupt-names = "lab-vreg-ok"; |
| 511 | qcom,qpnp-lab-min-voltage = <4600000>; |
| 512 | qcom,qpnp-lab-step-size = <100000>; |
| 513 | qcom,qpnp-lab-slew-rate = <5000>; |
| 514 | qcom,qpnp-lab-use-default-voltage; |
| 515 | qcom,qpnp-lab-init-voltage = <5500000>; |
| 516 | qcom,qpnp-lab-init-amoled-voltage = <4600000>; |
| 517 | qcom,qpnp-lab-init-lcd-voltage = <5500000>; |
| 518 | |
| 519 | qcom,qpnp-lab-soft-start = <800>; |
| 520 | |
| 521 | qcom,qpnp-lab-full-pull-down; |
| 522 | qcom,qpnp-lab-pull-down-enable; |
| 523 | qcom,qpnp-lab-switching-clock-frequency = |
| 524 | <1600>; |
| 525 | qcom,qpnp-lab-limit-maximum-current = <1600>; |
| 526 | qcom,qpnp-lab-limit-max-current-enable; |
| 527 | qcom,qpnp-lab-ps-threshold = <20>; |
| 528 | qcom,qpnp-lab-ps-enable; |
| 529 | qcom,qpnp-lab-nfet-size = <100>; |
| 530 | qcom,qpnp-lab-pfet-size = <100>; |
| 531 | qcom,qpnp-lab-max-precharge-time = <500>; |
| 532 | }; |
| 533 | }; |
| 534 | |
| 535 | pmi8998_wled: qcom,leds@d800 { |
| 536 | compatible = "qcom,qpnp-wled"; |
| 537 | reg = <0xd800 0x100>, |
| 538 | <0xd900 0x100>; |
| 539 | reg-names = "qpnp-wled-ctrl-base", |
| 540 | "qpnp-wled-sink-base"; |
| 541 | interrupts = <0x3 0xd8 0x1 IRQ_TYPE_EDGE_RISING>, |
| 542 | <0x3 0xd8 0x2 IRQ_TYPE_EDGE_RISING>; |
| 543 | interrupt-names = "ovp-irq", "sc-irq"; |
| 544 | linux,name = "wled"; |
| 545 | linux,default-trigger = "bkl-trigger"; |
| 546 | qcom,fdbk-output = "auto"; |
| 547 | qcom,vref-uv = <127500>; |
| 548 | qcom,switch-freq-khz = <800>; |
| 549 | qcom,ovp-mv = <29600>; |
| 550 | qcom,ilim-ma = <970>; |
| 551 | qcom,boost-duty-ns = <26>; |
| 552 | qcom,mod-freq-khz = <9600>; |
| 553 | qcom,dim-mode = "hybrid"; |
| 554 | qcom,hyb-thres = <625>; |
| 555 | qcom,sync-dly-us = <800>; |
| 556 | qcom,fs-curr-ua = <25000>; |
| 557 | qcom,cons-sync-write-delay-us = <1000>; |
| 558 | qcom,led-strings-list = [00 01 02 03]; |
| 559 | qcom,en-ext-pfet-sc-pro; |
| 560 | qcom,pmic-revid = <&pmi8998_revid>; |
| 561 | qcom,loop-auto-gm-en; |
Subbaraman Narayanamurthy | 1f92fc1 | 2017-03-30 15:41:45 -0700 | [diff] [blame] | 562 | status = "disabled"; |
David Collins | bbed9aa | 2017-03-10 11:53:10 -0800 | [diff] [blame] | 563 | }; |
| 564 | |
| 565 | flash_led: qcom,leds@d300 { |
| 566 | compatible = "qcom,qpnp-flash-led-v2"; |
| 567 | status = "okay"; |
| 568 | reg = <0xd300 0x100>; |
| 569 | label = "flash"; |
| 570 | interrupts = <0x3 0xd3 0x0 IRQ_TYPE_EDGE_RISING>, |
| 571 | <0x3 0xd3 0x3 IRQ_TYPE_EDGE_RISING>, |
| 572 | <0x3 0xd3 0x4 IRQ_TYPE_EDGE_RISING>; |
| 573 | interrupt-names = "led-fault-irq", |
| 574 | "all-ramp-down-done-irq", |
| 575 | "all-ramp-up-done-irq"; |
| 576 | qcom,hdrm-auto-mode; |
| 577 | qcom,short-circuit-det; |
| 578 | qcom,open-circuit-det; |
| 579 | qcom,vph-droop-det; |
| 580 | qcom,thermal-derate-en; |
| 581 | qcom,thermal-derate-current = <200 500 1000>; |
| 582 | qcom,isc-delay = <192>; |
| 583 | qcom,pmic-revid = <&pmi8998_revid>; |
| 584 | |
| 585 | pmi8998_flash0: qcom,flash_0 { |
| 586 | label = "flash"; |
| 587 | qcom,led-name = "led:flash_0"; |
| 588 | qcom,max-current = <1500>; |
| 589 | qcom,default-led-trigger = "flash0_trigger"; |
| 590 | qcom,id = <0>; |
| 591 | qcom,current-ma = <1000>; |
| 592 | qcom,duration-ms = <1280>; |
| 593 | qcom,ires-ua = <12500>; |
| 594 | qcom,hdrm-voltage-mv = <325>; |
| 595 | qcom,hdrm-vol-hi-lo-win-mv = <100>; |
| 596 | }; |
| 597 | |
| 598 | pmi8998_flash1: qcom,flash_1 { |
| 599 | label = "flash"; |
| 600 | qcom,led-name = "led:flash_1"; |
| 601 | qcom,max-current = <1500>; |
| 602 | qcom,default-led-trigger = "flash1_trigger"; |
| 603 | qcom,id = <1>; |
| 604 | qcom,current-ma = <1000>; |
| 605 | qcom,duration-ms = <1280>; |
| 606 | qcom,ires-ua = <12500>; |
| 607 | qcom,hdrm-voltage-mv = <325>; |
| 608 | qcom,hdrm-vol-hi-lo-win-mv = <100>; |
| 609 | }; |
| 610 | |
| 611 | pmi8998_flash2: qcom,flash_2 { |
| 612 | label = "flash"; |
| 613 | qcom,led-name = "led:flash_2"; |
| 614 | qcom,max-current = <750>; |
| 615 | qcom,default-led-trigger = "flash2_trigger"; |
| 616 | qcom,id = <2>; |
| 617 | qcom,current-ma = <500>; |
| 618 | qcom,duration-ms = <1280>; |
| 619 | qcom,ires-ua = <12500>; |
| 620 | qcom,hdrm-voltage-mv = <325>; |
| 621 | qcom,hdrm-vol-hi-lo-win-mv = <100>; |
| 622 | }; |
| 623 | |
| 624 | pmi8998_torch0: qcom,torch_0 { |
| 625 | label = "torch"; |
| 626 | qcom,led-name = "led:torch_0"; |
| 627 | qcom,max-current = <500>; |
| 628 | qcom,default-led-trigger = "torch0_trigger"; |
| 629 | qcom,id = <0>; |
| 630 | qcom,current-ma = <300>; |
| 631 | qcom,ires-ua = <12500>; |
| 632 | qcom,hdrm-voltage-mv = <325>; |
| 633 | qcom,hdrm-vol-hi-lo-win-mv = <100>; |
| 634 | }; |
| 635 | |
| 636 | pmi8998_torch1: qcom,torch_1 { |
| 637 | label = "torch"; |
| 638 | qcom,led-name = "led:torch_1"; |
| 639 | qcom,max-current = <500>; |
| 640 | qcom,default-led-trigger = "torch1_trigger"; |
| 641 | qcom,id = <1>; |
| 642 | qcom,current-ma = <300>; |
| 643 | qcom,ires-ua = <12500>; |
| 644 | qcom,hdrm-voltage-mv = <325>; |
| 645 | qcom,hdrm-vol-hi-lo-win-mv = <100>; |
| 646 | }; |
| 647 | |
| 648 | pmi8998_torch2: qcom,torch_2 { |
| 649 | label = "torch"; |
| 650 | qcom,led-name = "led:torch_2"; |
| 651 | qcom,max-current = <500>; |
| 652 | qcom,default-led-trigger = "torch2_trigger"; |
| 653 | qcom,id = <2>; |
| 654 | qcom,current-ma = <300>; |
| 655 | qcom,ires-ua = <12500>; |
| 656 | qcom,hdrm-voltage-mv = <325>; |
| 657 | qcom,hdrm-vol-hi-lo-win-mv = <100>; |
| 658 | }; |
| 659 | |
| 660 | pmi8998_switch0: qcom,led_switch_0 { |
| 661 | label = "switch"; |
| 662 | qcom,led-name = "led:switch_0"; |
| 663 | qcom,led-mask = <3>; |
| 664 | qcom,default-led-trigger = "switch0_trigger"; |
| 665 | }; |
| 666 | |
| 667 | pmi8998_switch1: qcom,led_switch_1 { |
| 668 | label = "switch"; |
| 669 | qcom,led-name = "led:switch_1"; |
| 670 | qcom,led-mask = <4>; |
| 671 | qcom,default-led-trigger = "switch1_trigger"; |
| 672 | }; |
| 673 | }; |
| 674 | }; |
| 675 | }; |
Ram Chandrasekar | 61ede0c | 2017-04-17 17:12:56 -0600 | [diff] [blame] | 676 | |
| 677 | &thermal_zones { |
| 678 | ibat-high { |
| 679 | polling-delay-passive = <0>; |
| 680 | polling-delay = <0>; |
| 681 | thermal-governor = "step_wise"; |
| 682 | thermal-sensors = <&bcl_sensor 0>; |
| 683 | |
| 684 | trips { |
| 685 | ibat_high: low-ibat { |
| 686 | temperature = <4200>; |
| 687 | hysteresis = <200>; |
| 688 | type = "passive"; |
| 689 | }; |
| 690 | }; |
| 691 | }; |
| 692 | ibat-vhigh { |
| 693 | polling-delay-passive = <0>; |
| 694 | polling-delay = <0>; |
| 695 | thermal-governor = "step_wise"; |
| 696 | thermal-sensors = <&bcl_sensor 1>; |
| 697 | |
| 698 | trips { |
| 699 | ibat_vhigh: ibat_vhigh { |
| 700 | temperature = <4300>; |
| 701 | hysteresis = <100>; |
| 702 | type = "passive"; |
| 703 | }; |
| 704 | }; |
| 705 | }; |
| 706 | vbat { |
| 707 | polling-delay-passive = <100>; |
| 708 | polling-delay = <0>; |
| 709 | thermal-governor = "low_limits_cap"; |
| 710 | thermal-sensors = <&bcl_sensor 2>; |
| 711 | tracks-low; |
| 712 | |
| 713 | trips { |
| 714 | low_vbat: low-vbat { |
| 715 | temperature = <3300>; |
| 716 | hysteresis = <100>; |
| 717 | type = "passive"; |
| 718 | }; |
| 719 | }; |
| 720 | cooling-maps { |
| 721 | vbat_cpu4 { |
| 722 | trip = <&low_vbat>; |
| 723 | cooling-device = <&CPU4 22 22>; |
| 724 | }; |
| 725 | vbat_cpu5 { |
| 726 | trip = <&low_vbat>; |
| 727 | cooling-device = <&CPU5 22 22>; |
| 728 | }; |
| 729 | vbat_map6 { |
| 730 | trip = <&low_vbat>; |
| 731 | cooling-device = <&CPU6 22 22>; |
| 732 | }; |
| 733 | vbat_map7 { |
| 734 | trip = <&low_vbat>; |
| 735 | cooling-device = <&CPU7 22 22>; |
| 736 | }; |
| 737 | }; |
| 738 | }; |
| 739 | vbat_low { |
| 740 | polling-delay-passive = <0>; |
| 741 | polling-delay = <0>; |
| 742 | thermal-governor = "low_limits_cap"; |
| 743 | thermal-sensors = <&bcl_sensor 3>; |
| 744 | tracks-low; |
| 745 | |
| 746 | trips { |
| 747 | low-vbat { |
| 748 | temperature = <3100>; |
| 749 | hysteresis = <0>; |
| 750 | type = "passive"; |
| 751 | }; |
| 752 | }; |
| 753 | }; |
| 754 | vbat_too_low { |
| 755 | polling-delay-passive = <0>; |
| 756 | polling-delay = <0>; |
| 757 | thermal-governor = "low_limits_cap"; |
| 758 | thermal-sensors = <&bcl_sensor 4>; |
| 759 | tracks-low; |
| 760 | |
| 761 | trips { |
| 762 | low-vbat { |
| 763 | temperature = <2900>; |
| 764 | hysteresis = <0>; |
| 765 | type = "passive"; |
| 766 | }; |
| 767 | }; |
| 768 | }; |
| 769 | soc { |
| 770 | polling-delay-passive = <100>; |
| 771 | polling-delay = <0>; |
| 772 | thermal-governor = "low_limits_cap"; |
| 773 | thermal-sensors = <&bcl_sensor 5>; |
| 774 | tracks-low; |
| 775 | |
| 776 | trips { |
| 777 | low_soc: low-soc { |
| 778 | temperature = <10>; |
| 779 | hysteresis = <0>; |
| 780 | type = "passive"; |
| 781 | }; |
| 782 | }; |
| 783 | cooling-maps { |
| 784 | soc_cpu4 { |
| 785 | trip = <&low_soc>; |
| 786 | cooling-device = <&CPU4 22 22>; |
| 787 | }; |
| 788 | soc_cpu5 { |
| 789 | trip = <&low_soc>; |
| 790 | cooling-device = <&CPU5 22 22>; |
| 791 | }; |
| 792 | soc_map6 { |
| 793 | trip = <&low_soc>; |
| 794 | cooling-device = <&CPU6 22 22>; |
| 795 | }; |
| 796 | soc_map7 { |
| 797 | trip = <&low_soc>; |
| 798 | cooling-device = <&CPU7 22 22>; |
| 799 | }; |
| 800 | }; |
| 801 | }; |
Ram Chandrasekar | 9920cf0 | 2017-04-21 17:38:51 -0600 | [diff] [blame] | 802 | |
| 803 | pmi8998_tz { |
| 804 | polling-delay-passive = <0>; |
| 805 | polling-delay = <0>; |
| 806 | thermal-sensors = <&pmi8998_tz>; |
| 807 | |
| 808 | trips { |
| 809 | pmi8998_trip0: pmi8998-trip0 { |
| 810 | temperature = <105000>; |
| 811 | hysteresis = <0>; |
| 812 | type = "passive"; |
| 813 | }; |
| 814 | pmi8998_trip1: pmi8998-trip1 { |
| 815 | temperature = <125000>; |
| 816 | hysteresis = <0>; |
| 817 | type = "passive"; |
| 818 | }; |
| 819 | pmi8998_trip2: pmi8998-trip2 { |
| 820 | temperature = <145000>; |
| 821 | hysteresis = <0>; |
| 822 | type = "critical"; |
| 823 | }; |
| 824 | }; |
| 825 | }; |
Ram Chandrasekar | 61ede0c | 2017-04-17 17:12:56 -0600 | [diff] [blame] | 826 | }; |