1c66ec88fSEmmanuel Vadot// SPDX-License-Identifier: GPL-2.0 2c66ec88fSEmmanuel Vadot#include <dt-bindings/iio/qcom,spmi-vadc.h> 3c66ec88fSEmmanuel Vadot#include <dt-bindings/input/linux-event-codes.h> 46be33864SEmmanuel Vadot#include <dt-bindings/interrupt-controller/irq.h> 5c66ec88fSEmmanuel Vadot#include <dt-bindings/spmi/spmi.h> 6c66ec88fSEmmanuel Vadot 7c66ec88fSEmmanuel Vadot&spmi_bus { 8c66ec88fSEmmanuel Vadot 96be33864SEmmanuel Vadot pm8916_0: pmic@0 { 10c66ec88fSEmmanuel Vadot compatible = "qcom,pm8916", "qcom,spmi-pmic"; 11c66ec88fSEmmanuel Vadot reg = <0x0 SPMI_USID>; 12c66ec88fSEmmanuel Vadot #address-cells = <1>; 13c66ec88fSEmmanuel Vadot #size-cells = <0>; 14c66ec88fSEmmanuel Vadot 15c66ec88fSEmmanuel Vadot pon@800 { 16c66ec88fSEmmanuel Vadot compatible = "qcom,pm8916-pon"; 17c66ec88fSEmmanuel Vadot reg = <0x800>; 18c66ec88fSEmmanuel Vadot mode-bootloader = <0x2>; 19c66ec88fSEmmanuel Vadot mode-recovery = <0x1>; 20c66ec88fSEmmanuel Vadot 21c66ec88fSEmmanuel Vadot pwrkey { 22c66ec88fSEmmanuel Vadot compatible = "qcom,pm8941-pwrkey"; 23c66ec88fSEmmanuel Vadot interrupts = <0x0 0x8 0 IRQ_TYPE_EDGE_BOTH>; 24c66ec88fSEmmanuel Vadot debounce = <15625>; 25c66ec88fSEmmanuel Vadot bias-pull-up; 26c66ec88fSEmmanuel Vadot linux,code = <KEY_POWER>; 27c66ec88fSEmmanuel Vadot }; 28c66ec88fSEmmanuel Vadot 296be33864SEmmanuel Vadot pm8916_resin: resin { 306be33864SEmmanuel Vadot compatible = "qcom,pm8941-resin"; 316be33864SEmmanuel Vadot interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>; 326be33864SEmmanuel Vadot debounce = <15625>; 336be33864SEmmanuel Vadot bias-pull-up; 346be33864SEmmanuel Vadot status = "disabled"; 356be33864SEmmanuel Vadot }; 366be33864SEmmanuel Vadot 37c66ec88fSEmmanuel Vadot watchdog { 38c66ec88fSEmmanuel Vadot compatible = "qcom,pm8916-wdt"; 39c66ec88fSEmmanuel Vadot interrupts = <0x0 0x8 6 IRQ_TYPE_EDGE_RISING>; 40c66ec88fSEmmanuel Vadot timeout-sec = <60>; 41c66ec88fSEmmanuel Vadot }; 42c66ec88fSEmmanuel Vadot }; 43c66ec88fSEmmanuel Vadot 44*8d13bc63SEmmanuel Vadot pm8916_charger: charger@1000 { 45*8d13bc63SEmmanuel Vadot compatible = "qcom,pm8916-lbc"; 46*8d13bc63SEmmanuel Vadot reg = <0x1000>, <0x1200>, <0x1300>, <0x1600>; 47*8d13bc63SEmmanuel Vadot reg-names = "chgr", "bat_if", "usb", "misc"; 48*8d13bc63SEmmanuel Vadot 49*8d13bc63SEmmanuel Vadot interrupts = <0x0 0x10 0 IRQ_TYPE_EDGE_BOTH>, 50*8d13bc63SEmmanuel Vadot <0x0 0x10 5 IRQ_TYPE_EDGE_BOTH>, 51*8d13bc63SEmmanuel Vadot <0x0 0x10 6 IRQ_TYPE_EDGE_BOTH>, 52*8d13bc63SEmmanuel Vadot <0x0 0x10 7 IRQ_TYPE_EDGE_BOTH>, 53*8d13bc63SEmmanuel Vadot <0x0 0x12 0 IRQ_TYPE_EDGE_BOTH>, 54*8d13bc63SEmmanuel Vadot <0x0 0x12 1 IRQ_TYPE_EDGE_BOTH>, 55*8d13bc63SEmmanuel Vadot <0x0 0x13 0 IRQ_TYPE_EDGE_BOTH>, 56*8d13bc63SEmmanuel Vadot <0x0 0x13 1 IRQ_TYPE_EDGE_BOTH>, 57*8d13bc63SEmmanuel Vadot <0x0 0x13 2 IRQ_TYPE_EDGE_BOTH>, 58*8d13bc63SEmmanuel Vadot <0x0 0x13 4 IRQ_TYPE_EDGE_BOTH>; 59*8d13bc63SEmmanuel Vadot interrupt-names = "vbat_det", 60*8d13bc63SEmmanuel Vadot "fast_chg", 61*8d13bc63SEmmanuel Vadot "chg_fail", 62*8d13bc63SEmmanuel Vadot "chg_done", 63*8d13bc63SEmmanuel Vadot "bat_pres", 64*8d13bc63SEmmanuel Vadot "temp_ok", 65*8d13bc63SEmmanuel Vadot "coarse_det", 66*8d13bc63SEmmanuel Vadot "usb_vbus", 67*8d13bc63SEmmanuel Vadot "chg_gone", 68*8d13bc63SEmmanuel Vadot "overtemp"; 69*8d13bc63SEmmanuel Vadot 70*8d13bc63SEmmanuel Vadot status = "disabled"; 71*8d13bc63SEmmanuel Vadot }; 72*8d13bc63SEmmanuel Vadot 73fac71e4eSEmmanuel Vadot pm8916_usbin: usb-detect@1300 { 748cc087a1SEmmanuel Vadot compatible = "qcom,pm8941-misc"; 758cc087a1SEmmanuel Vadot reg = <0x1300>; 768cc087a1SEmmanuel Vadot interrupts = <0x0 0x13 1 IRQ_TYPE_EDGE_BOTH>; 778cc087a1SEmmanuel Vadot interrupt-names = "usb_vbus"; 788cc087a1SEmmanuel Vadot status = "disabled"; 798cc087a1SEmmanuel Vadot }; 808cc087a1SEmmanuel Vadot 816be33864SEmmanuel Vadot pm8916_temp: temp-alarm@2400 { 826be33864SEmmanuel Vadot compatible = "qcom,spmi-temp-alarm"; 836be33864SEmmanuel Vadot reg = <0x2400>; 846be33864SEmmanuel Vadot interrupts = <0 0x24 0 IRQ_TYPE_EDGE_RISING>; 856be33864SEmmanuel Vadot io-channels = <&pm8916_vadc VADC_DIE_TEMP>; 866be33864SEmmanuel Vadot io-channel-names = "thermal"; 876be33864SEmmanuel Vadot #thermal-sensor-cells = <0>; 886be33864SEmmanuel Vadot }; 896be33864SEmmanuel Vadot 906be33864SEmmanuel Vadot pm8916_vadc: adc@3100 { 916be33864SEmmanuel Vadot compatible = "qcom,spmi-vadc"; 926be33864SEmmanuel Vadot reg = <0x3100>; 936be33864SEmmanuel Vadot interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>; 946be33864SEmmanuel Vadot #address-cells = <1>; 956be33864SEmmanuel Vadot #size-cells = <0>; 966be33864SEmmanuel Vadot #io-channel-cells = <1>; 976be33864SEmmanuel Vadot 98aa1a8ff2SEmmanuel Vadot channel@0 { 996be33864SEmmanuel Vadot reg = <VADC_USBIN>; 1006be33864SEmmanuel Vadot qcom,pre-scaling = <1 10>; 1016be33864SEmmanuel Vadot }; 102aa1a8ff2SEmmanuel Vadot channel@7 { 1036be33864SEmmanuel Vadot reg = <VADC_VSYS>; 1046be33864SEmmanuel Vadot qcom,pre-scaling = <1 3>; 1056be33864SEmmanuel Vadot }; 106aa1a8ff2SEmmanuel Vadot channel@8 { 1076be33864SEmmanuel Vadot reg = <VADC_DIE_TEMP>; 1086be33864SEmmanuel Vadot }; 109aa1a8ff2SEmmanuel Vadot channel@9 { 1106be33864SEmmanuel Vadot reg = <VADC_REF_625MV>; 1116be33864SEmmanuel Vadot }; 112aa1a8ff2SEmmanuel Vadot channel@a { 1136be33864SEmmanuel Vadot reg = <VADC_REF_1250MV>; 1146be33864SEmmanuel Vadot }; 115aa1a8ff2SEmmanuel Vadot channel@e { 1166be33864SEmmanuel Vadot reg = <VADC_GND_REF>; 1176be33864SEmmanuel Vadot }; 118aa1a8ff2SEmmanuel Vadot channel@f { 1196be33864SEmmanuel Vadot reg = <VADC_VDD_VADC>; 1206be33864SEmmanuel Vadot }; 1216be33864SEmmanuel Vadot }; 1226be33864SEmmanuel Vadot 123*8d13bc63SEmmanuel Vadot pm8916_bms: battery@4000 { 124*8d13bc63SEmmanuel Vadot compatible = "qcom,pm8916-bms-vm"; 125*8d13bc63SEmmanuel Vadot reg = <0x4000>; 126*8d13bc63SEmmanuel Vadot interrupts = <0x0 0x40 0 IRQ_TYPE_EDGE_RISING>, 127*8d13bc63SEmmanuel Vadot <0x0 0x40 1 IRQ_TYPE_EDGE_RISING>, 128*8d13bc63SEmmanuel Vadot <0x0 0x40 2 IRQ_TYPE_EDGE_RISING>, 129*8d13bc63SEmmanuel Vadot <0x0 0x40 3 IRQ_TYPE_EDGE_RISING>, 130*8d13bc63SEmmanuel Vadot <0x0 0x40 4 IRQ_TYPE_EDGE_RISING>, 131*8d13bc63SEmmanuel Vadot <0x0 0x40 5 IRQ_TYPE_EDGE_RISING>; 132*8d13bc63SEmmanuel Vadot interrupt-names = "cv_leave", 133*8d13bc63SEmmanuel Vadot "cv_enter", 134*8d13bc63SEmmanuel Vadot "ocv_good", 135*8d13bc63SEmmanuel Vadot "ocv_thr", 136*8d13bc63SEmmanuel Vadot "fifo", 137*8d13bc63SEmmanuel Vadot "state_chg"; 138*8d13bc63SEmmanuel Vadot 139*8d13bc63SEmmanuel Vadot status = "disabled"; 140*8d13bc63SEmmanuel Vadot }; 141*8d13bc63SEmmanuel Vadot 1426be33864SEmmanuel Vadot rtc@6000 { 1436be33864SEmmanuel Vadot compatible = "qcom,pm8941-rtc"; 144cb7aa33aSEmmanuel Vadot reg = <0x6000>, <0x6100>; 145cb7aa33aSEmmanuel Vadot reg-names = "rtc", "alarm"; 1466be33864SEmmanuel Vadot interrupts = <0x0 0x61 0x1 IRQ_TYPE_EDGE_RISING>; 147c66ec88fSEmmanuel Vadot }; 148c66ec88fSEmmanuel Vadot 149c66ec88fSEmmanuel Vadot pm8916_mpps: mpps@a000 { 1508cc087a1SEmmanuel Vadot compatible = "qcom,pm8916-mpp", "qcom,spmi-mpp"; 151c66ec88fSEmmanuel Vadot reg = <0xa000>; 152c66ec88fSEmmanuel Vadot gpio-controller; 153c66ec88fSEmmanuel Vadot #gpio-cells = <2>; 1548cc087a1SEmmanuel Vadot gpio-ranges = <&pm8916_mpps 0 0 4>; 1558cc087a1SEmmanuel Vadot interrupt-controller; 1568cc087a1SEmmanuel Vadot #interrupt-cells = <2>; 157c66ec88fSEmmanuel Vadot }; 158c66ec88fSEmmanuel Vadot 1598bab661aSEmmanuel Vadot pm8916_gpios: gpio@c000 { 160b97ee269SEmmanuel Vadot compatible = "qcom,pm8916-gpio", "qcom,spmi-gpio"; 1616be33864SEmmanuel Vadot reg = <0xc000>; 1626be33864SEmmanuel Vadot gpio-controller; 163b97ee269SEmmanuel Vadot gpio-ranges = <&pm8916_gpios 0 0 4>; 1646be33864SEmmanuel Vadot #gpio-cells = <2>; 165b97ee269SEmmanuel Vadot interrupt-controller; 166b97ee269SEmmanuel Vadot #interrupt-cells = <2>; 167c66ec88fSEmmanuel Vadot }; 168c66ec88fSEmmanuel Vadot }; 169c66ec88fSEmmanuel Vadot 1706be33864SEmmanuel Vadot pm8916_1: pmic@1 { 171c66ec88fSEmmanuel Vadot compatible = "qcom,pm8916", "qcom,spmi-pmic"; 172c66ec88fSEmmanuel Vadot reg = <0x1 SPMI_USID>; 173c66ec88fSEmmanuel Vadot #address-cells = <1>; 174c66ec88fSEmmanuel Vadot #size-cells = <0>; 175c66ec88fSEmmanuel Vadot 176b97ee269SEmmanuel Vadot pm8916_pwm: pwm { 177b97ee269SEmmanuel Vadot compatible = "qcom,pm8916-pwm"; 178b97ee269SEmmanuel Vadot 179b97ee269SEmmanuel Vadot #pwm-cells = <2>; 180b97ee269SEmmanuel Vadot 181b97ee269SEmmanuel Vadot status = "disabled"; 182b97ee269SEmmanuel Vadot }; 183b97ee269SEmmanuel Vadot 184c66ec88fSEmmanuel Vadot pm8916_vib: vibrator@c000 { 185c66ec88fSEmmanuel Vadot compatible = "qcom,pm8916-vib"; 186c66ec88fSEmmanuel Vadot reg = <0xc000>; 187c66ec88fSEmmanuel Vadot status = "disabled"; 188c66ec88fSEmmanuel Vadot }; 189c66ec88fSEmmanuel Vadot 190f126890aSEmmanuel Vadot pm8916_codec: audio-codec@f000 { 191c66ec88fSEmmanuel Vadot compatible = "qcom,pm8916-wcd-analog-codec"; 1926be33864SEmmanuel Vadot reg = <0xf000>; 193c66ec88fSEmmanuel Vadot interrupt-parent = <&spmi_bus>; 194c66ec88fSEmmanuel Vadot interrupts = <0x1 0xf0 0x0 IRQ_TYPE_NONE>, 195c66ec88fSEmmanuel Vadot <0x1 0xf0 0x1 IRQ_TYPE_NONE>, 196c66ec88fSEmmanuel Vadot <0x1 0xf0 0x2 IRQ_TYPE_NONE>, 197c66ec88fSEmmanuel Vadot <0x1 0xf0 0x3 IRQ_TYPE_NONE>, 198c66ec88fSEmmanuel Vadot <0x1 0xf0 0x4 IRQ_TYPE_NONE>, 199c66ec88fSEmmanuel Vadot <0x1 0xf0 0x5 IRQ_TYPE_NONE>, 200c66ec88fSEmmanuel Vadot <0x1 0xf0 0x6 IRQ_TYPE_NONE>, 201c66ec88fSEmmanuel Vadot <0x1 0xf0 0x7 IRQ_TYPE_NONE>, 202c66ec88fSEmmanuel Vadot <0x1 0xf1 0x0 IRQ_TYPE_NONE>, 203c66ec88fSEmmanuel Vadot <0x1 0xf1 0x1 IRQ_TYPE_NONE>, 204c66ec88fSEmmanuel Vadot <0x1 0xf1 0x2 IRQ_TYPE_NONE>, 205c66ec88fSEmmanuel Vadot <0x1 0xf1 0x3 IRQ_TYPE_NONE>, 206c66ec88fSEmmanuel Vadot <0x1 0xf1 0x4 IRQ_TYPE_NONE>, 207c66ec88fSEmmanuel Vadot <0x1 0xf1 0x5 IRQ_TYPE_NONE>; 208c66ec88fSEmmanuel Vadot interrupt-names = "cdc_spk_cnp_int", 209c66ec88fSEmmanuel Vadot "cdc_spk_clip_int", 210c66ec88fSEmmanuel Vadot "cdc_spk_ocp_int", 211c66ec88fSEmmanuel Vadot "mbhc_ins_rem_det1", 212c66ec88fSEmmanuel Vadot "mbhc_but_rel_det", 213c66ec88fSEmmanuel Vadot "mbhc_but_press_det", 214c66ec88fSEmmanuel Vadot "mbhc_ins_rem_det", 215c66ec88fSEmmanuel Vadot "mbhc_switch_int", 216c66ec88fSEmmanuel Vadot "cdc_ear_ocp_int", 217c66ec88fSEmmanuel Vadot "cdc_hphr_ocp_int", 218c66ec88fSEmmanuel Vadot "cdc_hphl_ocp_det", 219c66ec88fSEmmanuel Vadot "cdc_ear_cnp_int", 220c66ec88fSEmmanuel Vadot "cdc_hphr_cnp_int", 221c66ec88fSEmmanuel Vadot "cdc_hphl_cnp_int"; 222c66ec88fSEmmanuel Vadot #sound-dai-cells = <1>; 223f126890aSEmmanuel Vadot status = "disabled"; 224c66ec88fSEmmanuel Vadot }; 225c66ec88fSEmmanuel Vadot }; 226c66ec88fSEmmanuel Vadot}; 227