summaryrefslogtreecommitdiffstats
path: root/drivers/power/supply/Kconfig
diff options
context:
space:
mode:
authorQuentin Schulz <quentin.schulz@free-electrons.com>2017-04-18 09:34:17 +0200
committerSebastian Reichel <sre@kernel.org>2017-05-01 11:52:23 +0200
commit46c202b5f25fb6fbd4af60ded133fa745b3601b3 (patch)
treecb424e2f6f5c9e042d6b8a326ff99fba2d7e3c94 /drivers/power/supply/Kconfig
parent7221675c70d147f2ae6f044697dff046f3805224 (diff)
downloadop-kernel-dev-46c202b5f25fb6fbd4af60ded133fa745b3601b3.zip
op-kernel-dev-46c202b5f25fb6fbd4af60ded133fa745b3601b3.tar.gz
power: supply: add battery driver for AXP20X and AXP22X PMICs
The X-Powers AXP20X and AXP22X PMICs can have a battery as power supply. This patch adds the battery power supply driver to get various data from the PMIC, such as the battery status (charging, discharging, full, dead), current max limit, current current, battery capacity (in percentage), voltage max and min limits, current voltage and battery capacity (in Ah). This battery driver uses the AXP20X/AXP22X ADC driver as PMIC data provider. Signed-off-by: Quentin Schulz <quentin.schulz@free-electrons.com> Acked-by: Jonathan Cameron <jic23@kernel.org> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Acked-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk>
Diffstat (limited to 'drivers/power/supply/Kconfig')
-rw-r--r--drivers/power/supply/Kconfig12
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/power/supply/Kconfig b/drivers/power/supply/Kconfig
index da92275..4b718e9 100644
--- a/drivers/power/supply/Kconfig
+++ b/drivers/power/supply/Kconfig
@@ -238,6 +238,18 @@ config CHARGER_AXP20X
This driver can also be built as a module. If so, the module will be
called axp20x_ac_power.
+config BATTERY_AXP20X
+ tristate "X-Powers AXP20X battery driver"
+ depends on MFD_AXP20X
+ depends on AXP20X_ADC
+ depends on IIO
+ help
+ Say Y here to enable support for X-Powers AXP20X PMICs' battery power
+ supply.
+
+ This driver can also be built as a module. If so, the module will be
+ called axp20x_battery.
+
config AXP288_CHARGER
tristate "X-Powers AXP288 Charger"
depends on MFD_AXP20X && EXTCON_AXP288
OpenPOWER on IntegriCloud