regulator: axp20x: Add AXP15060 support
authorShengyu Qu <wiagn233@outlook.com>
Mon, 8 May 2023 11:14:47 +0000 (20:14 +0900)
committerJaehoon Chung <jh80.chung@samsung.com>
Mon, 24 Jul 2023 23:25:01 +0000 (08:25 +0900)
commit7def7eeb154fc76a0918a9be01ef7959499a24f9
tree42b2374d603e0fcfb54c05f5350c4751bbc5d000
parent877e413ab2a408c8086fd53fe72f2ad85188259b
regulator: axp20x: Add AXP15060 support

The AXP15060 is a typical I2C-controlled PMIC, seen on multiple boards
with different default register value. Current driver is tested on
Starfive Visionfive 2.

The RTCLDO is fixed, and cannot even be turned on or off. On top of
that, its voltage is customisable (either 1.8V or 3.3V). We pretend it's
a fixed 1.8V regulator since other AXP driver also do like this. Also,
BSP code ignores this regulator and it's not used according to VF2
schematic.

Describe the AXP15060's voltage settings and switch registers, how the
voltages are encoded, and connect this to the MFD device via its
regulator ID.

[1] https://lore.kernel.org/linux-sunxi/20230401001850.4988-1-andre.przywara@arm.com/

Signed-off-by: Shengyu Qu <wiagn233@outlook.com>
[Backported patch : https://lore.kernel.org/lkml/TY3P286MB2611DA5F918F90491A3AA02298609@TY3P286MB2611.JPNP286.PROD.OUTLOOK.COM/#Z31drivers:regulator:axp20x-regulator.c]
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
Change-Id: I24a8cc725d57bb07273df316e14d2eb05943d162
drivers/regulator/axp20x-regulator.c