Skip to content

Commit

Permalink
regulator: cpcap: Add basic regulator support
Browse files Browse the repository at this point in the history
Many Motorola phones like droid 4 are using a custom PMIC called CPCAP
or 6556002. This PMIC is used with several SoCs, I've noticed at least
omap3, omap4 and Tegra2 based Motorola phones and tablets using it.

Cc: devicetree@vger.kernel.org
Cc: Marcel Partap <mpartap@gmx.net>
Cc: Michael Scott <michael.scott@linaro.org>
Cc: Rob Herring <robh@kernel.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Tony Lindgren authored and Mark Brown committed Feb 4, 2017
1 parent d00b746 commit 0ad4c07
Show file tree
Hide file tree
Showing 4 changed files with 506 additions and 0 deletions.
34 changes: 34 additions & 0 deletions Documentation/devicetree/bindings/regulator/cpcap-regulator.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
Motorola CPCAP PMIC voltage regulators
------------------------------------

Requires node properties:
- "compatible" value one of:
"motorola,cpcap-regulator"
"motorola,mapphone-cpcap-regulator"

Required regulator properties:
- "regulator-name"
- "regulator-enable-ramp-delay"
- "regulator-min-microvolt"
- "regulator-max-microvolt"

Optional regulator properties:
- "regulator-boot-on"

See Documentation/devicetree/bindings/regulator/regulator.txt
for more details about the regulator properties.

Example:

cpcap_regulator: regulator {
compatible = "motorola,cpcap-regulator";

cpcap_regulators: regulators {
sw5: SW5 {
regulator-min-microvolt = <5050000>;
regulator-max-microvolt = <5050000>;
regulator-enable-ramp-delay = <50000>;
regulator-boot-on;
};
};
};
7 changes: 7 additions & 0 deletions drivers/regulator/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,13 @@ config REGULATOR_BCM590XX
BCM590xx PMUs. This will enable support for the software
controllable LDO/Switching regulators.

config REGULATOR_CPCAP
tristate "Motorola CPCAP regulator"
depends on MFD_CPCAP
help
Say y here for CPCAP regulator found on some Motorola phones
and tablets such as Droid 4.

config REGULATOR_DA903X
tristate "Dialog Semiconductor DA9030/DA9034 regulators"
depends on PMIC_DA903X
Expand Down
1 change: 1 addition & 0 deletions drivers/regulator/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ obj-$(CONFIG_REGULATOR_USERSPACE_CONSUMER) += userspace-consumer.o

obj-$(CONFIG_REGULATOR_88PM800) += 88pm800.o
obj-$(CONFIG_REGULATOR_88PM8607) += 88pm8607.o
obj-$(CONFIG_REGULATOR_CPCAP) += cpcap-regulator.o
obj-$(CONFIG_REGULATOR_AAT2870) += aat2870-regulator.o
obj-$(CONFIG_REGULATOR_AB3100) += ab3100.o
obj-$(CONFIG_REGULATOR_AB8500) += ab8500-ext.o ab8500.o
Expand Down
Loading

0 comments on commit 0ad4c07

Please sign in to comment.