power_supply: Add driver for the PMU on WM831x PMICs
Subsystems (2)
PATCH 1/1 power_supply: Add driver for the PMU on WM831x PMICs
The WM831x PMICs provide power path management from three sources:
a wall supply, USB and a battery with integrated charger. They also provide an additional backup supply with integrated for maintaining always on functionality such as the RTC and monitoring of power switches.
After some initial configuration at startup the device operates autonomously, the driver simply provides reporting of the current state.
---
This uses the new charger state feature of the power supply subsystem so won't build in the MFD tree as-is - unless Samuel is OK with the breakage it'd be better to go via the power tree, the dependency on the core driver will avoid build issues there.
I'm fairly sure Anton said that he'd applied it previously but it doesn't appear to have shown up in -next yet so I'm resending it.
drivers/power/Kconfig | 7 + drivers/power/Makefile | 1 + drivers/power/wm831x_power.c | 779 ++++++++++++++++++++++++++++++++++++++++ include/linux/mfd/wm831x/pmu.h | 189 ++++++++++ 4 files changed, 976 insertions(+), 0 deletions(-) create mode 100644 drivers/power/wm831x_power.c create mode 100644 include/linux/mfd/wm831x/pmu.h
drivers/power/Kconfig +7 -0
@@ -29,6 +29,13 @@ config APM_POWER Say Y here to enable support APM status emulation using battery class devices. +config WM831X_POWER + tristate "WM831X PMU support" + depends on MFD_WM831X + help + Say Y here to enable support for the power management unit + provided by Wolfson Microelectronics WM831x PMICs. + config WM8350_POWER tristate "WM8350 PMU support" depends on MFD_WM8350
drivers/power/Makefile +1 -0
@@ -16,6 +16,7 @@ obj-$(CONFIG_POWER_SUPPLY) += power_supply.o obj-$(CONFIG_PDA_POWER) += pda_power.o obj-$(CONFIG_APM_POWER) += apm_power.o +obj-$(CONFIG_WM831X_POWER) += wm831x_power.o obj-$(CONFIG_WM8350_POWER) += wm8350_power.o obj-$(CONFIG_BATTERY_DS2760) += ds2760_battery.o
drivers/power/wm831x_power.c new file +779 -0
779 lines not on this page · raw message
include/linux/mfd/wm831x/pmu.h new file +189 -0
189 lines not on this page · raw message
Signature · 1 line
1.6.3.3
On Sat, Sep 05, 2009 at 02:06:05PM +0100, Mark Brown wrote:
[...]
Quoted 2 lines
I'm fairly sure Anton said that he'd applied it previously but it doesn't appear to have shown up in -next yet so I'm resending it.
It's in battery-2.6.git since Friday, -next tree lags a little bit.
http://git.infradead.org/battery-2.6.git
Quoted 5 lines
drivers/power/Kconfig +0
-0
drivers/power/Kconfig config APM_POWER · line 37
Quoted 9 lines
drivers/power/Kconfig +6
-0@@ -29,6 +29,13 @@ config APM_POWER Say Y here to enable support APM status emulation using battery class devices. +config WM831X_POWER + tristate "WM831X PMU support" + depends on MFD_WM831X + help + Say Y here to enable support for the power management unit + provided by Wolfson Microelectronics WM831x PMICs.
FYI, I fixed whitespaces vs. tabs issue here. ;-)
Thanks!
Signature · 3 lines
Anton Vorontsov email: [email protected] irc://irc.freenode.net/bd2