History log of /linux-master/include/linux/mfd/axp20x.h
Revision Date Author Comments
# 63eeabbc 11-May-2023 Aidan MacDonald <aidanmacdonald.0x0@gmail.com>

mfd: axp20x: Add support for AXP192

The AXP192 PMIC is similar to the AXP202/AXP209, but with different
regulators, additional GPIOs, and a different IRQ register layout.

Signed-off-by: Aidan MacDonald <aidanmacdonald.0x0@gmail.com>
Link: https://lore.kernel.org/r/20230511092609.76183-1-aidanmacdonald.0x0@gmail.com
Signed-off-by: Lee Jones <lee@kernel.org>


# 75c8cb2f 23-May-2023 Martin Botka <martin.botka@somainline.org>

mfd: axp20x: Add support for AXP313a PMIC

The AXP313a is a PMIC chip produced by X-Powers, it can be connected via
an I2C bus.
The name AXP1530 seems to appear as well, and this is what is used in
the BSP driver. From all we know it's the same chip, just a different
name. However we have only seen AXP313a chips in the wild, so go with
this name.

Compared to the other AXP PMICs it's a rather simple affair: just three
DCDC converters, three LDOs, and no battery charging support.

Describe the regmap and the MFD bits, along with the registers exposed
via I2C. Aside from the various regulators, also describe the power key
interrupts, and adjust the shutdown handler routine to use a different
register than the other PMICs.
Eventually advertise the device using the new compatible string.

Signed-off-by: Martin Botka <martin.botka@somainline.org>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Chen-Yu Tsai <wens@csie.org>
Link: https://lore.kernel.org/r/20230524000012.15028-2-andre.przywara@arm.com
Signed-off-by: Lee Jones <lee@kernel.org>


# e0f8ad2a 21-Apr-2023 Shengyu Qu <wiagn233@outlook.com>

mfd: axp20x: Add support for AXP15060 PMIC

The AXP15060 is a PMIC chip produced by X-Powers, and could be connected
via an I2C bus.

Describe the regmap and the MFD bits, along with the registers exposed
via I2C. Eventually advertise the device using a new compatible string
and add support for power off the system.

The driver would disable PEK function if IRQ is not configured in device
tree, since some boards (For example, Starfive Visionfive 2) didn't
connect IRQ line of PMIC to SOC.

GPIO function isn't enabled in this commit, since its configuration
operation is different from any existing AXP PMICs and needs
logic modification on existing driver. GPIO support might come in later
patches.

Signed-off-by: Shengyu Qu <wiagn233@outlook.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Lee Jones <lee@kernel.org>
Link: https://lore.kernel.org/r/TY3P286MB261162D57695AC8164ED50E298609@TY3P286MB2611.JPNP286.PROD.OUTLOOK.COM


# 8781ba7f 08-Dec-2022 Aren Moynihan <aren@peacevolution.org>

mfd: axp20x: Fix order of pek rise and fall events

The power button can get "stuck" if the rising edge and falling edge irq
are read in the same pass. This can often be triggered when resuming
from suspend if the power button is released before the kernel handles
the interrupt.

Swapping the order of the rise and fall events makes sure that the press
event is handled first, which prevents this situation.

Signed-off-by: Aren Moynihan <aren@peacevolution.org>
Reviewed-by: Samuel Holland <samuel@sholland.org>
Tested-by: Samuel Holland <samuel@sholland.org>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee@kernel.org>
Link: https://lore.kernel.org/r/20221208220225.635414-1-aren@peacevolution.org


# 3c15e00e 26-Nov-2020 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>

mfd/bus: sunxi-rsb: Make .remove() callback return void

The driver core ignores the return value of struct device_driver::remove
because there is only little that can be done. To simplify the quest to
make this function return void, let struct sunxi_rsb_driver::remove
return void, too. All users already unconditionally return 0, this
commit makes this obvious and ensures future users don't behave
differently. To simplify even further, make axp20x_device_remove()
return void instead of returning 0 unconditionally, too.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Reviewed-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# d2912cb1 04-Jun-2019 Thomas Gleixner <tglx@linutronix.de>

treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500

Based on 2 normalized pattern(s):

this program is free software you can redistribute it and or modify
it under the terms of the gnu general public license version 2 as
published by the free software foundation

this program is free software you can redistribute it and or modify
it under the terms of the gnu general public license version 2 as
published by the free software foundation #

extracted by the scancode license scanner the SPDX license identifier

GPL-2.0-only

has been chosen to replace the boilerplate/reference in 4122 file(s).

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Enrico Weigelt <info@metux.net>
Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org>
Reviewed-by: Allison Randal <allison@lohutok.net>
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190604081206.933168790@linutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 16aa70e9 11-Dec-2018 Olliver Schinagl <oliver@schinagl.nl>

mfd: axp20x: name voltage ramping define properly

The current axp20x names the ramping register 'scal' which probably
means scaling. Since the register really has nothing to do with
scaling, but really is the voltage ramp we rename it appropriately.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
Signed-off-by: Priit Laes <plaes@plaes.org>
Acked-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Mark Brown <broonie@kernel.org>


# 7693b564 20-Nov-2018 Oskari Lemmela <oskari@lemmela.net>

power: supply: add AC power supply driver for AXP813

AXP813 and AXP803 PMICs can control input current and minimum voltage.

Both of these values are configurable.

Signed-off-by: Oskari Lemmela <oskari@lemmela.net>
Reviewed-by: Quentin Schulz <quentin.schulz@bootlin.com>
Reviewed-by: Chen-Yu Tsai <wens@csie.org>
Acked-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>


# eef2b53a 28-Mar-2018 Chen-Yu Tsai <wens@csie.org>

mfd: axp20x: Correct AXP806 POK interrupt prefix

When AXP806 support was added, POK was incorrectly expanded to PWROK.
However, the datasheet lists them as POK[LSNP], which is the same as
on the AXP288. Furthermore, the registers associated with POK functions
are the same as the PEK on the other AXP PMICs. This suggests that
"POK" means "Power On Key", much like "PEK" means "Power Enable Key",
instead of "Power OK".

This patch changes the "PWROK" prefix to "POK" for these interrupts.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 531a469e 28-Mar-2018 Chen-Yu Tsai <wens@csie.org>

mfd: axp20x: Constify struct mfd_cell and struct resource

The axp20x driver has lots of mfd_cell and resource structs.
These can all be const-ified.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 1a3f6755 15-Jan-2018 Quentin Schulz <quentin.schulz@free-electrons.com>

iio: adc: axp20x_adc: add support for AXP813 ADC

The X-Powers AXP813 PMIC is really close to what is already done for
AXP20X/AXP22X.

There are two pairs of bits to set the rate (one for Voltage and Current
measurements and one for TS/GPIO0 voltage measurements) instead of one.

The register to set the ADC rates is different from the one for
AXP20X/AXP22X.

GPIO0 can be used as an ADC (measuring Volts) unlike for AXP22X.

The scales to apply to the different inputs are unlike the ones from
AXP20X and AXP22X.

Signed-off-by: Quentin Schulz <quentin.schulz@free-electrons.com>
Acked-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>


# 9bf317e9 30-Dec-2017 Hans de Goede <hdegoede@redhat.com>

extcon: axp288: Remove unused platform data

This is not used / set anywhere in the tree.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Chanwoo Choi <cw00.choi@samsung.com>
Acked-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>


# d81851c1 28-Sep-2017 Chen-Yu Tsai <wens@csie.org>

regulator: axp20x: Add support for AXP813 regulators

The AXP813 PMIC has 7 DC-DC buck regulators, 16 LDOs (including the
fixed RTC LDO and 2 GPIO LDOs), and 1 switchable. The drive-vbus
feature is also supported. All the hardware details are very similar
to the AXP803, with the following exceptions:

- Extra DCDC7 buck regulator, with the same range as DCDC6

- SWitch now has a separate supply pin, instead of being chained
internaly from DCDC1

- RTC LDO output voltage is now 1.8V

- FLDO3 is an LDO with switchable supplies, but unconfigurable output
voltage. The voltage is always half that of its supply.

Support for FLDO3 is currently unimplemented, as it requires runtime
switching of its supplies, something the regulator subsystem does not
support. It is not used in either the reference designs nor actually
produced boards available.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Tested-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Signed-off-by: Mark Brown <broonie@kernel.org>


# 7303733a 26-Jul-2017 Chen-Yu Tsai <wens@csie.org>

mfd: axp20x: Add support for AXP813 PMIC

The X-Powers AXP813 PMIC is normally used with Allwinner's A83T SoC.
It has the same range of functions as other X-Powers PMICs, such as
DC-DC buck converter and linear regulator outputs, AC-IN and VBUS
power supplies, power button trigger, GPIOs, ADCs, and a battery
charger.

Note that the IRQ table given in the datasheet is incorrect: in IRQ
enable/status registers 1, there are separate IRQs for ACIN and VBUS,
instead of bits [7:5] being the same as bits [4:2]. So it shares the
same IRQs as the AXP803, rather than the AXP288.

This patch adds basic mfd support for it, with only the power button
enabled.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 1dbe0ccb 18-May-2017 Icenowy Zheng <icenowy@aosc.io>

regulator: axp20x-regulator: add support for AXP803

AXP803 PMIC also have a series of regulators (DCDCs and LDOs)
controllable via I2C/RSB bus.

Add support for them.

Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Mark Brown <broonie@kernel.org>


# 1578353e 17-Apr-2017 Icenowy Zheng <icenowy@aosc.io>

mfd: axp20x: Support AXP803 variant

AXP803 is a new PMIC chip produced by X-Powers, usually paired with A64
via RSB bus. The PMIC itself is like AXP288, but with RSB support and
dedicated VBUS and ACIN.

Add support for it in the axp20x mfd driver.

Currently only power key function is supported.

Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# ed7311f0 20-Mar-2017 Quentin Schulz <quentin.schulz@free-electrons.com>

mfd: axp20x: Correct name of temperature data ADC registers

The registers 0x56 and 0x57 of AXP22X PMIC store the value of the
internal temperature of the PMIC.

This patch modifies the name of these registers from AXP22X_PMIC_ADC_H/L
to AXP22X_PMIC_TEMP_H/L so their purpose is clearer.

Signed-off-by: Quentin Schulz <quentin.schulz@free-electrons.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 178e8351 16-Dec-2016 Hans de Goede <hdegoede@redhat.com>

mfd: axp20x: Add a few missing defines for AXP288 specific registers

Add defines for the AXP288_POWER_REASON and AXP288_RT_BATT_V_H and
AXP288_RT_BATT_V_L and AXP288_BC_* registers. While at it also move the
AXP288_TS_ADC_H-AXP288_GP_ADC_L defines, which for some reason where
in a different place, together with the rest of the AXP288 specific
defines.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 59f10f7e 14-Dec-2016 Hans de Goede <hdegoede@redhat.com>

mfd: axp20x: Drop wrong AXP288_PMIC_ADC_EN define

The adc-enable register for the axp288 is 0x82, not 0x84.
0x82 is already defined as AXP20X_ADC_EN1 and that is what the
axp288_adc driver is actually using, so simply drop the wrong
AXP288_PMIC_ADC_EN define.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 0a5454c9 14-Dec-2016 Hans de Goede <hdegoede@redhat.com>

mfd: axp20x: Use IRQF_TRIGGER_LOW on the axp288

The interrupt line of the entire family of axp2xx pmics is active-low,
for devicetree enumerated irqs, this is dealt with in the devicetree.

ACPI irq resources have a flag field for this too, I tried using this
on my CUBE iwork8 Air tablet, but it does not contain the right data.

The dstd shows the irq listed as either ActiveLow or ActiveHigh,
depending on the OSID variable, which seems to be set by the
"OS IMAGE ID" in the BIOS/EFI setup screen.

Since the acpi-resource info is no good, simply pass in IRQF_TRIGGER_LOW
on the axp288.

Together with the other axp288 fixes in this series, this fixes the axp288
irq contineously triggering.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 34a23327 05-Dec-2016 Corentin Labbe <clabbe.montjoie@gmail.com>

mfd: axp20x: Correct a typo in axp20x_device_remove documentation

The documentation of axp20x_device_remove() have a typo and use
axp20x_device_probe() as name. This patch fix this typo.

Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 15df6d98 10-Jan-2017 Michal Suchanek <msuchanek@suse.de>

power: supply: axp20x_usb_power: fix warning on 64bit

Casting of_device_get_match_data return value to int causes warning on 64bit
architectures.

../drivers/power/supply/axp20x_usb_power.c: In function
'axp20x_usb_power_probe':
../drivers/power/supply/axp20x_usb_power.c:297:21: warning: cast from
pointer to integer of different size [-Wpointer-to-int-cast]

Fixes: 0dcc70ca8644 ("power: supply: axp20x_usb_power: use of_device_id
data field instead of device_is_compatible")
Signed-off-by: Michal Suchanek <msuchanek@suse.de>
Signed-off-by: Sebastian Reichel <sre@kernel.org>


# 888f9743 14-Dec-2016 Hans de Goede <hdegoede@redhat.com>

power: supply: axp288_fuel_gauge: Drop platform_data dependency

When the axp288_faul_gauge driver was originally merged, it was
merged with a dependency on some other driver providing platform
data for it.

However the battery-data-framework which should provide that data
never got merged, resulting in x86 tablets / laptops with an axp288
having no working battery monitor, as before this commit the driver
would simply return -ENODEV if there is no platform data.

This commit removes the dependency on the platform_data instead
checking that the firmware has initialized the fuel-gauge and
reading the info back from the pmic.

What is missing from the read-back info is the table to map raw adc
values to temperature, so this commit drops the temperature and
temperature limits properties. The min voltage, charge design and
model name info is also missing. Note that none of these are really
important for userspace to have.

All other functionality is preserved and actually made available
by this commit.

BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=88471
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Sebastian Reichel <sre@kernel.org>


# eac53b36 21-Dec-2016 Hans de Goede <hdegoede@redhat.com>

power: supply: axp288_charger: Drop platform_data dependency

When the axp288_charger driver was originally merged, it was merged with
a dependency on some other driver providing platform data for it.

However the battery-data-framework which should provide that data never
got merged, so the axp288_charger as merged upstream has never worked,
its probe method simply always returns -ENODEV.

This commit removes the dependency on the platform_data instead reading
back the charging current and charging voltage that the firmware has set
and using those values as the maximum values the user may set.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Sebastian Reichel <sre@kernel.org>


# 34d9030b 10-Nov-2016 Chen-Yu Tsai <wens@csie.org>

mfd: axp20x: Add address extension registers for AXP806 regmap

The AXP806 supports either master/standalone or slave mode.
Slave mode allows sharing the serial bus, even with multiple
AXP806 which all have the same hardware address.

This is done with extra "serial interface address extension",
or AXP806_BUS_ADDR_EXT, and "register address extension", or
AXP806_REG_ADDR_EXT, registers. The former is read-only, with
1 bit customizable at the factory, and 1 bit depending on the
state of an external pin. The latter is writable. Only when
the these device addressing bits (in the upper 4 bits of the
registers) match, will the device respond to operations on
its other registers.

Add these 2 registers to the regmap so we can access them.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 3f89586b 01-Jul-2016 Icenowy Zheng <icenowy@aosc.xyz>

mfd: axp20x: Add adc volatile ranges for axp22x

AXP22x has also some different register map than axp20x, they're also
added here.

Signed-off-by: Icenowy Zheng <icenowy@aosc.xyz>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 8824ee85 27-Aug-2016 Chen-Yu Tsai <wens@csie.org>

mfd: axp20x: Add support for AXP806 PMIC

The X-Powers AXP806 is a new PMIC that is paired with Allwinner's A80
SoC, along with a master AXP809 PMIC.

This PMIC has a new register layout, and supports some functions not
seen in other X-Powers PMICs, such as master-slave mode, or having
multiple AXP806 PMICs on the same bus with address space extension,
or supporting both I2C and RSB mode. I2C has not been tested.

This patch adds support for the interrupts of the PMIC. A regulator
sub-device is enabled, but actual regulator support will come in a
later patch.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 20147f0d 29-Mar-2016 Chen-Yu Tsai <wens@csie.org>

mfd: axp20x: Add support for AXP809 PMIC

The X-Powers AXP809 is a new PMIC that is paired with Allwinner's A80
SoC, along with a slave AXP806 PMIC.

This PMIC is quite similar to the earlier AXP223, though the interrupts
and regulator have changed a bit.

This patch adds support for the interrupts and power button of the PMIC.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 02071f0f 11-Feb-2016 Chen-Yu Tsai <wens@csie.org>

mfd: axp20x: Add support for RSB based AXP223 PMIC

The AXP223 is a new PMIC commonly paired with Allwinner A23/A33 SoCs.
It is functionally identical to AXP221; only the regulator default
voltage/status and the external host interface are different.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 4fd41151 11-Feb-2016 Chen-Yu Tsai <wens@csie.org>

mfd: axp20x: Split the driver into core and i2c bits

The axp20x driver assumes the device is i2c based. This is not the
case with later chips, which use a proprietary 2 wire serial bus
by Allwinner called "Reduced Serial Bus".

This patch follows the example of mfd/wm831x and splits it into
an interface independent core, and an i2c specific glue layer.
MFD_AXP20X and the new MFD_AXP20X_I2C are changed to tristate
symbols, allowing the driver to be built as modules.

Whitespace and other style errors in the moved i2c specific code
have been fixed. Included but unused header files are removed as
well.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 69fb4dca 01-Aug-2015 Hans de Goede <hdegoede@redhat.com>

power: Add an axp20x-usb-power driver

This adds a driver for the usb power_supply bits of the axp20x PMICs.

I initially started writing my own driver, before coming aware of
Bruno Prémont's excellent earlier RFC with a driver for this.

My driver was lacking CURRENT_MAX and VOLTAGE_MIN support Bruno's
drvier has, so I've copied the code for those from his driver.

Note that the AC-power-supply and battery charger bits will need separate
drivers. Each one needs its own devictree child-node so that other
devicetree nodes can reference the right power-supply, and thus each one
will get its own mfd-cell / platform_device and platform-driver.

Cc: Bruno Prémont <bonbons@linux-vserver.org>
Acked-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Bruno Prémont <bonbons@linux-vserver.org>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Sebastian Reichel <sre@kernel.org>


# 553ed4b5 08-Aug-2015 Bruno Prémont <bonbons@linux-vserver.org>

mfd: axp20x: Add missing registers, and mark more registers volatile

Add an extra set of registers which is necessary tu support the PMICs
battery charger function, and mark registers which contain status bits,
gpio status, and adc readings as volatile.

Signed-off-by: Bruno Prémont <bonbons@linux-vserver.org>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# d8d79f8f 11-Jul-2015 Michal Suchanek <hramrach@gmail.com>

mfd: axp20x: Add axp152 support

The axp152 is a stripped down version of the axp202 pmic with the battery
charging function removed as it is intended for top-set boxes.

Signed-off-by: Michal Suchanek <hramrach@gmail.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 843735b7 04-May-2015 Ramakrishna Pallala <ramakrishna.pallala@intel.com>

power: axp288_charger: axp288 charger driver

This patch adds new power supply charger driver support
for X-Power AXP288 PMIC integrated charger.

This driver interfaces with the axp20x mfd driver as a cell
and listens to extcon cable events for setting up charging.

Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
Acked-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Sebastian Reichel <sre@kernel.org>


# f0312378 30-Apr-2015 Ramakrishna Pallala <ramakrishna.pallala@intel.com>

extcon: axp288: Add axp288 extcon driver support

This patch adds the extcon support for AXP288 PMIC which
has the BC1.2 charger detection capability. Additionally
it also adds the USB mux switching support b/w SOC and PMIC
based on GPIO control.

Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
Acked-by: Lee Jones <lee.jones@linaro.org>
[cw00.choi: Modify the log message to keep the consistent log message pattern]
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>


# f05be589 09-Apr-2015 Boris Brezillon <bbrezillon@kernel.org>

mfd: axp20x: Add AXP22x PMIC support

Add support for the AXP22x PMIC devices to the existing AXP20x driver.
This includes the AXP221 and AXP223, which are identical except for
the external data bus. Only AXP221 is added for now. AXP223 will be
added after it's Reduced Serial Bus (RSB) interface is supported.

AXP22x defines a new set of registers, power supplies and regulators,
but most of the API is similar to the AXP20x ones.

A new irq chip definition is used, even though the available interrupts
on AXP22x is a subset of those on AXP20x. This is done so the interrupt
numbers match those on the datasheet.

This patch only enables the interrupts, system power-off function, and PEK
sub-device. The regulator driver must first support different variants
before we enable it from the mfd driver.

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
[wens@csie.org: fix interrupts and move regulators to separate patch]
Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# 774e0b41 07-Jan-2015 Todd E Brandt <todd.e.brandt@linux.intel.com>

mfd: axp20x: Add support for fuel gauge cell driver

mfd/axp20x: add support for fuel gauge cell

Register definitions and platform data structure
for fuel gauge cell devices.

Signed-off-by: Todd Brandt <todd.e.brandt@intel.com>
Acked-by: Jacob Pan <jacob.jun.pan@linux.intel.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# af7e9069 06-Oct-2014 Jacob Pan <jacob.jun.pan@linux.intel.com>

mfd: axp20x: Extend axp20x to support axp288 pmic

X-Powers AXP288 is a customized PMIC for Intel Baytrail-CR platforms. Similar
to AXP202/209, AXP288 comes with USB charger, more LDO and BUCK channels, and
AD converters. It also provides extended status and interrupt reporting
capabilities than the devices currently supported in axp20x.c.

In addition to feature extension, this patch also adds ACPI binding for
enumeration.

This consolidated driver should support more X-Powers' PMICs in both device
tree and ACPI enumerated platforms.

Signed-off-by: Jacob Pan <jacob.jun.pan@linux.intel.com>
Reviewed-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Reviewed-by: Jonathan Cameron <jic23@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>


# cfb61a41 01-May-2014 Carlo Caione <carlo@caione.org>

mfd: AXP20x: Add mfd driver for AXP20x PMIC

This patch introduces the preliminary support for PMICs X-Powers AXP202
and AXP209. The AXP209 and AXP202 are the PMUs (Power Management Unit)
used by A10, A13 and A20 SoCs and developed by X-Powers, a sister company
of Allwinner.

The core enables support for two subsystems:
- PEK (Power Enable Key)
- Regulators

Signed-off-by: Carlo Caione <carlo@caione.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>