18ea4ffcaSStephen Boyd// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 28ea4ffcaSStephen Boyd/* Copyright 2018 Google LLC. */ 38ea4ffcaSStephen Boyd 443fb4431SMatthias Kaehlcke#include <dt-bindings/iio/qcom,spmi-vadc.h> 561020aa5SBjorn Andersson#include <dt-bindings/input/linux-event-codes.h> 68ea4ffcaSStephen Boyd#include <dt-bindings/interrupt-controller/irq.h> 743fb4431SMatthias Kaehlcke#include <dt-bindings/spmi/spmi.h> 81b9d8bd6SMatthias Kaehlcke#include <dt-bindings/thermal/thermal.h> 98ea4ffcaSStephen Boyd 101b9d8bd6SMatthias Kaehlcke/ { 111b9d8bd6SMatthias Kaehlcke thermal-zones { 123a786086SManivannan Sadhasivam pm8998-thermal { 131b9d8bd6SMatthias Kaehlcke polling-delay-passive = <250>; 141b9d8bd6SMatthias Kaehlcke polling-delay = <1000>; 151b9d8bd6SMatthias Kaehlcke 161b9d8bd6SMatthias Kaehlcke thermal-sensors = <&pm8998_temp>; 171b9d8bd6SMatthias Kaehlcke 181b9d8bd6SMatthias Kaehlcke trips { 191b9d8bd6SMatthias Kaehlcke pm8998_alert0: pm8998-alert0 { 201b9d8bd6SMatthias Kaehlcke temperature = <105000>; 211b9d8bd6SMatthias Kaehlcke hysteresis = <2000>; 221b9d8bd6SMatthias Kaehlcke type = "passive"; 231b9d8bd6SMatthias Kaehlcke }; 241b9d8bd6SMatthias Kaehlcke pm8998_crit: pm8998-crit { 251b9d8bd6SMatthias Kaehlcke temperature = <125000>; 261b9d8bd6SMatthias Kaehlcke hysteresis = <2000>; 271b9d8bd6SMatthias Kaehlcke type = "critical"; 281b9d8bd6SMatthias Kaehlcke }; 291b9d8bd6SMatthias Kaehlcke }; 301b9d8bd6SMatthias Kaehlcke }; 311b9d8bd6SMatthias Kaehlcke }; 321b9d8bd6SMatthias Kaehlcke}; 3361020aa5SBjorn Andersson 348ea4ffcaSStephen Boyd&spmi_bus { 358ea4ffcaSStephen Boyd pm8998_lsid0: pmic@0 { 368ea4ffcaSStephen Boyd compatible = "qcom,pm8998", "qcom,spmi-pmic"; 378ea4ffcaSStephen Boyd reg = <0x0 SPMI_USID>; 388ea4ffcaSStephen Boyd #address-cells = <1>; 398ea4ffcaSStephen Boyd #size-cells = <0>; 408ea4ffcaSStephen Boyd 4161020aa5SBjorn Andersson pm8998_pon: pon@800 { 426fd7c4daSJohn Stultz compatible = "qcom,pm8998-pon"; 4361020aa5SBjorn Andersson 4461020aa5SBjorn Andersson reg = <0x800>; 4561020aa5SBjorn Andersson mode-bootloader = <0x2>; 4661020aa5SBjorn Andersson mode-recovery = <0x1>; 4761020aa5SBjorn Andersson 4831a233a5SStephen Boyd pm8998_pwrkey: pwrkey { 4961020aa5SBjorn Andersson compatible = "qcom,pm8941-pwrkey"; 5061020aa5SBjorn Andersson interrupts = <0x0 0x8 0 IRQ_TYPE_EDGE_BOTH>; 5161020aa5SBjorn Andersson debounce = <15625>; 5261020aa5SBjorn Andersson bias-pull-up; 5361020aa5SBjorn Andersson linux,code = <KEY_POWER>; 5461020aa5SBjorn Andersson }; 5561020aa5SBjorn Andersson }; 5661020aa5SBjorn Andersson 57104e6415SMatthias Kaehlcke pm8998_temp: temp-alarm@2400 { 58104e6415SMatthias Kaehlcke compatible = "qcom,spmi-temp-alarm"; 59104e6415SMatthias Kaehlcke reg = <0x2400>; 60104e6415SMatthias Kaehlcke interrupts = <0x0 0x24 0x0 IRQ_TYPE_EDGE_RISING>; 617bfd90f5SMatthias Kaehlcke io-channels = <&pm8998_adc ADC5_DIE_TEMP>; 627bfd90f5SMatthias Kaehlcke io-channel-names = "thermal"; 63104e6415SMatthias Kaehlcke #thermal-sensor-cells = <0>; 64104e6415SMatthias Kaehlcke }; 65104e6415SMatthias Kaehlcke 6661020aa5SBjorn Andersson pm8998_coincell: coincell@2800 { 6761020aa5SBjorn Andersson compatible = "qcom,pm8941-coincell"; 6861020aa5SBjorn Andersson reg = <0x2800>; 6961020aa5SBjorn Andersson 7061020aa5SBjorn Andersson status = "disabled"; 7161020aa5SBjorn Andersson }; 7261020aa5SBjorn Andersson 7343fb4431SMatthias Kaehlcke pm8998_adc: adc@3100 { 7443fb4431SMatthias Kaehlcke compatible = "qcom,spmi-adc-rev2"; 7543fb4431SMatthias Kaehlcke reg = <0x3100>; 7643fb4431SMatthias Kaehlcke interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>; 7743fb4431SMatthias Kaehlcke #address-cells = <1>; 7843fb4431SMatthias Kaehlcke #size-cells = <0>; 7943fb4431SMatthias Kaehlcke #io-channel-cells = <1>; 80a789fd0bSMatthias Kaehlcke 81e77cc85eSVinod Koul adc-chan@6 { 82a789fd0bSMatthias Kaehlcke reg = <ADC5_DIE_TEMP>; 83a789fd0bSMatthias Kaehlcke label = "die_temp"; 84a789fd0bSMatthias Kaehlcke }; 8543fb4431SMatthias Kaehlcke }; 8643fb4431SMatthias Kaehlcke 874cc7c85cSBjorn Andersson pm8998_adc_tm: adc-tm@3400 { 884cc7c85cSBjorn Andersson compatible = "qcom,spmi-adc-tm-hc"; 894cc7c85cSBjorn Andersson reg = <0x3400>; 904cc7c85cSBjorn Andersson interrupts = <0x0 0x34 0x0 IRQ_TYPE_EDGE_RISING>; 914cc7c85cSBjorn Andersson #thermal-sensor-cells = <1>; 924cc7c85cSBjorn Andersson #address-cells = <1>; 934cc7c85cSBjorn Andersson #size-cells = <0>; 944cc7c85cSBjorn Andersson status = "disabled"; 954cc7c85cSBjorn Andersson }; 964cc7c85cSBjorn Andersson 9761020aa5SBjorn Andersson rtc@6000 { 9861020aa5SBjorn Andersson compatible = "qcom,pm8941-rtc"; 9961020aa5SBjorn Andersson reg = <0x6000>, <0x6100>; 10061020aa5SBjorn Andersson reg-names = "rtc", "alarm"; 10161020aa5SBjorn Andersson interrupts = <0x0 0x61 0x1 IRQ_TYPE_EDGE_RISING>; 10261020aa5SBjorn Andersson }; 10361020aa5SBjorn Andersson 104*c95243eeSKrzysztof Kozlowski pm8998_gpio: gpio@c000 { 1058ea4ffcaSStephen Boyd compatible = "qcom,pm8998-gpio", "qcom,spmi-gpio"; 1068ea4ffcaSStephen Boyd reg = <0xc000>; 1078ea4ffcaSStephen Boyd gpio-controller; 10899c70e72SBrian Masney gpio-ranges = <&pm8998_gpio 0 0 26>; 1098ea4ffcaSStephen Boyd #gpio-cells = <2>; 110a1738363SBrian Masney interrupt-controller; 111a1738363SBrian Masney #interrupt-cells = <2>; 1128ea4ffcaSStephen Boyd }; 1138ea4ffcaSStephen Boyd 1148ea4ffcaSStephen Boyd }; 1158ea4ffcaSStephen Boyd 1168ea4ffcaSStephen Boyd pm8998_lsid1: pmic@1 { 1178ea4ffcaSStephen Boyd compatible = "qcom,pm8998", "qcom,spmi-pmic"; 1188ea4ffcaSStephen Boyd reg = <0x1 SPMI_USID>; 1198ea4ffcaSStephen Boyd #address-cells = <1>; 1208ea4ffcaSStephen Boyd #size-cells = <0>; 1218ea4ffcaSStephen Boyd }; 1228ea4ffcaSStephen Boyd}; 123