-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
iio: adc: cpcap: Add minimal support for CPCAP PMIC ADC
On Motorola phones like droid 4 there is a custom CPCAP PMIC. This PMIC has ADCs that are used for battery charging and USB PHY VBUS and ID pin detection. Unfortunately the only documentation for this ADC seems to be the Motorola mapphone Linux kernel tree. I have tested that reading raw and scaled values works, but I have not used the timed sampling that the ADC seems to support. Let's add a minimal support for it so we can eventually provide IIO channels for the related battery charging and USB PHY drivers. Cc: devicetree@vger.kernel.org Cc: Marcel Partap <mpartap@gmx.net> Cc: Michael Scott <michael.scott@linaro.org> Cc: Sebastian Reichel <sre@kernel.org> Signed-off-by: Tony Lindgren <tony@atomide.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
- Loading branch information
Tony Lindgren
authored and
Jonathan Cameron
committed
Mar 30, 2017
1 parent
b71244b
commit 25ec249
Showing
4 changed files
with
1,037 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
Motorola CPCAP PMIC ADC binding | ||
|
||
Required properties: | ||
- compatible: Should be "motorola,cpcap-adc" or "motorola,mapphone-cpcap-adc" | ||
- interrupt-parent: The interrupt controller | ||
- interrupts: The interrupt number for the ADC device | ||
- interrupt-names: Should be "adcdone" | ||
- #io-channel-cells: Number of cells in an IIO specifier | ||
|
||
Example: | ||
|
||
cpcap_adc: adc { | ||
compatible = "motorola,mapphone-cpcap-adc"; | ||
interrupt-parent = <&cpcap>; | ||
interrupts = <8 IRQ_TYPE_NONE>; | ||
interrupt-names = "adcdone"; | ||
#io-channel-cells = <1>; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.