Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f086d6a2 authored by Subbaraman Narayanamurthy's avatar Subbaraman Narayanamurthy
Browse files

dt-bindings: iio: update pm8350b ADC channel list



Add PM8350B_ADC7_ICHG_FB channel to read charging current for
PM8350B. Also, update qcom,spmi-vadc.h to add ADC7_ICHG_FB and
other relevant channels that are needed for reading input and
charging current for SMB139x charger pumps along with scale
function indices.

Change-Id: I4a1b53f328e1b394063cbf951f6ff978eb96d21e
Signed-off-by: default avatarSubbaraman Narayanamurthy <subbaram@codeaurora.org>
parent 38b1718d
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
/* SPDX-License-Identifier: GPL-2.0-only */
/*
 * Copyright (c) 2019 The Linux Foundation. All rights reserved.
 * Copyright (c) 2019-2020 The Linux Foundation. All rights reserved.
 */

#ifndef _DT_BINDINGS_QCOM_SPMI_VADC_PM8350B_H
@@ -33,6 +33,7 @@
#define PM8350B_ADC7_CC1_ID			(PM8350B_SID << 8 | 0x13)
#define PM8350B_ADC7_VREF_BAT_THERM		(PM8350B_SID << 8 | 0x15)
#define PM8350B_ADC7_IIN_FB			(PM8350B_SID << 8 | 0x17)
#define PM8350B_ADC7_ICHG_FB			(PM8350B_SID << 8 | 0xa1)

/* 30k pull-up1 */
#define PM8350B_ADC7_AMUX_THM1_30K_PU		(PM8350B_SID << 8 | 0x24)
+7 −1
Original line number Diff line number Diff line
/* SPDX-License-Identifier: GPL-2.0 */
/*
 * Copyright (c) 2012-2014,2018-2019 The Linux Foundation. All rights reserved.
 * Copyright (c) 2012-2014,2018-2020 The Linux Foundation. All rights reserved.
 */

#ifndef _DT_BINDINGS_QCOM_SPMI_VADC_H
@@ -245,6 +245,9 @@
#define ADC7_CC1_ID				0x13
#define ADC7_VREF_BAT_THERM			0x15
#define ADC7_IIN_FB				0x17
#define ADC7_ICHG_SMB				0x18
#define ADC7_IIN_SMB				0x19
#define ADC7_ICHG_FB				0xa1

/* 30k pull-up1 */
#define ADC7_AMUX_THM1_30K_PU			0x24
@@ -316,5 +319,8 @@
#define ADC_SCALE_HW_CALIB_PM5_SMB1398_TEMP	15
#define ADC_SCALE_HW_CALIB_THERM_100K_PU_PM7	16
#define ADC_SCALE_HW_CALIB_PMIC_THERM_PM7	17
#define ADC_SCALE_HW_CALIB_PM7_SMB_TEMP		18
#define ADC_SCALE_HW_CALIB_PM7_CHG_TEMP		19
#define ADC_SCALE_HW_CALIB_CUR_RAW		20

#endif /* _DT_BINDINGS_QCOM_SPMI_VADC_H */