Skip to content
Commit 4da5f2d6 authored by Evgeny Boger's avatar Evgeny Boger Committed by Jonathan Cameron
Browse files

iio:adc:axp20x: add support for NTC thermistor



Most AXPxxx-based reference designs place a 10k NTC thermistor on a
TS pin. When appropriately configured, AXP PMICs will inject fixed
current (80uA by default) into TS pin and measure the voltage across a
thermistor. The PMIC itself will by default compare this voltage with
predefined thresholds  and disable battery charging whenever
the battery is too hot or too cold.

Alternatively, the TS pin can be configured as general-purpose
ADC input. This mode is not supported by the driver.

This patch allows reading the voltage on the TS pin. It can be then
either processed by userspace or used by kernel consumer like hwmon
ntc thermistor driver.

Signed-off-by: default avatarEvgeny Boger <boger@wirenboard.com>
Acked-by: default avatarMaxime Ripard <maxime@cerno.tech>
Reviewed-by: default avatarQuentin Schulz <foss+kernel@0leil.net>
Link: https://lore.kernel.org/r/20211118141233.247907-2-boger@wirenboard.com


Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent a91f82d9
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment