/* Copyright (c) 2019-2020, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and * only version 2 as published by the Free Software Foundation. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. */ #include "sdxprairie-pmic-overlay.dtsi" #include "sdxprairie-mtp-audio-overlay.dtsi" &pmxprairie_vadc { vph_pwr { reg = ; label = "vph_pwr"; qcom,pre-scaling = <1 3>; }; xo_therm { reg = ; label = "xo_therm"; qcom,ratiometric; qcom,hw-settle-time = <200>; qcom,pre-scaling = <1 1>; }; pa_therm1 { reg = ; label = "pa_therm1"; qcom,ratiometric; qcom,hw-settle-time = <200>; qcom,pre-scaling = <1 1>; }; pa_therm2 { reg = ; label = "pa_therm2"; qcom,ratiometric; qcom,hw-settle-time = <200>; qcom,pre-scaling = <1 1>; }; sdx_case_therm { reg = ; label = "sdx_case_therm"; qcom,ratiometric; qcom,hw-settle-time = <200>; qcom,pre-scaling = <1 1>; }; ambient_therm { reg = ; label = "ambient_therm"; qcom,ratiometric; qcom,hw-settle-time = <200>; qcom,pre-scaling = <1 1>; }; }; &pmxprairie_adc_tm_iio { xo_therm { reg = ; qcom,ratiometric; qcom,hw-settle-time = <200>; }; pa_therm1 { reg = ; qcom,ratiometric; qcom,hw-settle-time = <200>; }; pa_therm2 { reg = ; qcom,ratiometric; qcom,hw-settle-time = <200>; }; sdx_case_therm { reg = ; qcom,ratiometric; qcom,hw-settle-time = <200>; }; ambient_therm { reg = ; qcom,ratiometric; qcom,hw-settle-time = <200>; }; }; &pm8150b_vadc { vph_pwr { reg = ; label = "vph_pwr"; qcom,pre-scaling = <1 3>; }; conn_therm { reg = ; label = "conn_therm"; qcom,ratiometric; qcom,hw-settle-time = <200>; qcom,pre-scaling = <1 1>; }; chg_sbux { reg = ; label = "chg_sbux"; qcom,pre-scaling = <1 3>; }; mid_chg_div6 { reg = ; label = "chg_mid"; qcom,pre-scaling = <1 6>; }; usb_in_i_uv { reg = ; label = "usb_in_i_uv"; qcom,pre-scaling = <1 1>; }; usb_in_v_div_16 { reg = ; label = "usb_in_v_div_16"; qcom,pre-scaling = <1 16>; }; }; &pm8150b_adc_tm { status = "disabled"; }; &thermal_zones { xo-therm-usr { polling-delay-passive = <0>; polling-delay = <0>; thermal-sensors = <&pmxprairie_adc_tm_iio ADC_XO_THERM_PU2>; thermal-governor = "user_space"; wake-capable-sensor; trips { active-config0 { temperature = <125000>; hysteresis = <1000>; type = "passive"; }; }; }; pa-therm1-usr { polling-delay-passive = <0>; polling-delay = <0>; thermal-sensors = <&pmxprairie_adc_tm_iio ADC_AMUX_THM1_PU2>; thermal-governor = "user_space"; wake-capable-sensor; trips { active-config0 { temperature = <125000>; hysteresis = <1000>; type = "passive"; }; }; }; pa-therm2-usr { polling-delay-passive = <0>; polling-delay = <0>; thermal-sensors = <&pmxprairie_adc_tm_iio ADC_AMUX_THM2_PU2>; thermal-governor = "user_space"; wake-capable-sensor; trips { active-config0 { temperature = <125000>; hysteresis = <1000>; type = "passive"; }; }; }; sdx-case-therm-usr { polling-delay-passive = <0>; polling-delay = <0>; thermal-sensors = <&pmxprairie_adc_tm_iio ADC_AMUX_THM3_PU2>; thermal-governor = "user_space"; wake-capable-sensor; trips { active-config0 { temperature = <125000>; hysteresis = <1000>; type = "passive"; }; }; }; ambient-therm-usr { polling-delay-passive = <0>; polling-delay = <0>; thermal-sensors = <&pmxprairie_adc_tm_iio ADC_GPIO1_PU2>; thermal-governor = "user_space"; wake-capable-sensor; trips { active-config0 { temperature = <125000>; hysteresis = <1000>; type = "passive"; }; }; }; }; &soc { sdxprairie_mtp_batterydata: qcom,battery-data { qcom,batt-id-range-pct = <15>; #include "fg-gen4-batterydata-alium-3600mah.dtsi" }; }; &pm8150b_charger { qcom,sec-charger-config = <0>; qcom,auto-recharge-soc = <98>; io-channels = <&pm8150b_vadc ADC_MID_CHG_DIV6>, <&pm8150b_vadc ADC_USB_IN_I>, <&pm8150b_vadc ADC_SBUx>, <&pm8150b_vadc ADC_VPH_PWR>, <&pm8150b_vadc ADC_CHG_TEMP>, <&pm8150b_vadc ADC_USB_IN_V_16>; io-channel-names = "mid_voltage", "usb_in_current", "sbux_res", "vph_voltage", "chg_temp", "usb_in_voltage"; qcom,battery-data = <&sdxprairie_mtp_batterydata>; qcom,step-charging-enable; qcom,wd-bark-time-secs = <16>; qcom,suspend-input-on-debug-batt; }; &pm8150b_fg { qcom,battery-data = <&sdxprairie_mtp_batterydata>; qcom,hold-soc-while-full; qcom,linearize-soc; qcom,five-pin-battery; /* ESR fast calibration */ qcom,fg-esr-timer-chg-fast = <0 7>; qcom,fg-esr-timer-dischg-fast = <0 7>; qcom,fg-esr-timer-chg-slow = <0 96>; qcom,fg-esr-timer-dischg-slow = <0 96>; qcom,fg-esr-cal-soc-thresh = <26 230>; qcom,fg-esr-cal-temp-thresh = <10 40>; };