From: Quentin Schulz <quentin.schulz@free-electrons.com>
To: Sebastian Reichel <sre@kernel.org>
Cc: mark.rutland@arm.com, thomas.petazzoni@free-electrons.com,
devicetree@vger.kernel.org, lars@metafoo.de,
linux-pm@vger.kernel.org, liam@networkimprov.net,
linux-sunxi@googlegroups.com, linux@armlinux.org.uk,
linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org,
bonbons@linux-vserver.org, robh+dt@kernel.org, icenowy@aosc.xyz,
pmeerw@pmeerw.net, knaack.h@gmx.de,
maxime.ripard@free-electrons.com, wens@csie.org,
lee.jones@linaro.org, jic23@kernel.org,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v4 11/18] dt-bindings: power: supply: add AXP20X/AXP22X battery DT binding
Date: Wed, 15 Mar 2017 23:41:07 +0100 [thread overview]
Message-ID: <761e35fc-932a-953c-cfad-7e967ea3d126@free-electrons.com> (raw)
In-Reply-To: <20170315222852.z2qrwoexcsjt7vs6@earth>
[-- Attachment #1.1: Type: text/plain, Size: 3409 bytes --]
Hi,
On 15/03/2017 23:28, Sebastian Reichel wrote:
> Hi,
>
> On Wed, Mar 15, 2017 at 11:55:30AM +0100, Quentin Schulz wrote:
>> The X-Powers AXP20X and AXP22X PMICs can have a battery as power supply.
>>
>> This patch adds the DT binding documentation for the battery power
>> supply which gets various data from the PMIC, such as the battery status
>> (charging, discharging, full, dead), current max limit, current current,
>> battery capacity (in percentage), voltage max and min limits, current
>> voltage and battery capacity (in Ah).
>>
>> 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>
>
> I suggest to do "s/battery-power-supply/battery-fuel-gauge/g"
>
The IP is way more than a simple fuel gauge, you have info about the
voltage, current, you can set different things, even though you have the
percentage of the battery returned by the PMIC.
Does it really make sense to rename it that way?
Thanks,
Quentin
>> ---
>>
>> v4:
>> - added monitored-battery optional property,
>> - added example with battery,
>>
>> v3:
>> - removed constant charge current property, now should use the WIP
>> battery framework,
>>
>> v2:
>> - changed DT node name from ac_power_supply to ac-power-supply,
>
> ac-power-supply?
>
> -- Sebastian
>
>> - removed io-channels and io-channel-names from DT (the IIO mapping is
>> done in the IIO ADC driver now),
>> - added x-powers,constant-charge-current property to set the maximal
>> default constant current charge of the battery,
>> .../bindings/power/supply/axp20x_battery.txt | 30 ++++++++++++++++++++++
>> 1 file changed, 30 insertions(+)
>> create mode 100644 Documentation/devicetree/bindings/power/supply/axp20x_battery.txt
>>
>> diff --git a/Documentation/devicetree/bindings/power/supply/axp20x_battery.txt b/Documentation/devicetree/bindings/power/supply/axp20x_battery.txt
>> new file mode 100644
>> index 0000000..89cb7a2
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/power/supply/axp20x_battery.txt
>> @@ -0,0 +1,30 @@
>> +AXP20x and AXP22x battery power supply
>> +
>> +Required Properties:
>> + - compatible, one of:
>> + "x-powers,axp209-battery-power-supply"
>> + "x-powers,axp221-battery-power-supply"
>> +
>> +Optional properties:
>> + - monitored-battery, phandle to a fixed battery
>> +
>> +This node is a subnode of the axp20x/axp22x PMIC.
>> +
>> +The AXP20X and AXP22X can read the battery voltage, charge and discharge
>> +currents of the battery by reading ADC channels from the AXP20X/AXP22X
>> +ADC.
>> +
>> +Example:
>> +
>> +battery: battery {
>> + compatible = "fixed-battery";
>> + voltage-min-design-microvolt = <3200000>;
>> + constant-charge-microamp = <300000>;
>> +};
>> +
>> +&axp209 {
>> + battery_power_supply: battery-power-supply {
>> + compatible = "x-powers,axp209-battery-power-supply";
>> + monitored-battery = <&battery>;
>> + }
>> +};
>> --
>> 2.9.3
>>
>>
>>
>> _______________________________________________
>> linux-arm-kernel mailing list
>> linux-arm-kernel@lists.infradead.org
>> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
--
Quentin Schulz, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 801 bytes --]
next prev parent reply other threads:[~2017-03-15 22:41 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-15 10:55 [PATCH v4 00/18] add support for AXP20X and AXP22X power supply drivers Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 01/18] dt-bindings: power: battery: add constant-charge-current property Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 02/18] power: supply: power_supply_core: add constant-charge-current optional property Quentin Schulz
2017-03-15 22:24 ` Sebastian Reichel
2017-03-15 10:55 ` [PATCH v4 03/18] mfd: axp20x: correct name of temperature data ADC registers Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 04/18] iio: adc: add support for X-Powers AXP20X and AXP22X PMICs ADCs Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 05/18] mfd: axp20x: add ADC cells for AXP20X and AXP22X PMICs Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 06/18] mfd: axp20x: add AC power supply cells for " Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 07/18] ARM: dtsi: axp209: add AC power supply subnode Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 08/18] ARM: dtsi: axp22x: " Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 09/18] ARM: dts: sun8i: sina33: enable ACIN " Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 10/18] ARM: sun5i: chip: " Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 11/18] dt-bindings: power: supply: add AXP20X/AXP22X battery DT binding Quentin Schulz
2017-03-15 22:28 ` Sebastian Reichel
2017-03-15 22:41 ` Quentin Schulz [this message]
2017-03-15 23:02 ` Sebastian Reichel
2017-03-15 10:55 ` [PATCH v4 12/18] mfd: axp20x: add CHRG_CTRL1/2/3 to writeable regs for AXP20X/AXP22X Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 13/18] power: supply: add battery driver for AXP20X and AXP22X PMICs Quentin Schulz
2017-03-15 22:38 ` Sebastian Reichel
2017-03-15 10:55 ` [PATCH v4 14/18] mfd: axp20x: add MFD cells for AXP20X and AXP22X battery driver Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 15/18] ARM: dtsi: axp209: add battery power supply subnode Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 16/18] ARM: dtsi: axp22x: " Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 17/18] ARM: dts: sun8i: sina33: enable " Quentin Schulz
2017-03-15 10:55 ` [PATCH v4 18/18] ARM: sun5i: chip: " Quentin Schulz
2017-03-15 12:14 ` [PATCH v4 00/18] add support for AXP20X and AXP22X power supply drivers Lee Jones
2017-03-15 13:18 ` Quentin Schulz
2017-03-15 22:46 ` Sebastian Reichel
2017-03-20 11:34 ` Quentin Schulz
2017-03-20 19:11 ` Sebastian Reichel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=761e35fc-932a-953c-cfad-7e967ea3d126@free-electrons.com \
--to=quentin.schulz@free-electrons.com \
--cc=bonbons@linux-vserver.org \
--cc=devicetree@vger.kernel.org \
--cc=icenowy@aosc.xyz \
--cc=jic23@kernel.org \
--cc=knaack.h@gmx.de \
--cc=lars@metafoo.de \
--cc=lee.jones@linaro.org \
--cc=liam@networkimprov.net \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux-sunxi@googlegroups.com \
--cc=linux@armlinux.org.uk \
--cc=mark.rutland@arm.com \
--cc=maxime.ripard@free-electrons.com \
--cc=pmeerw@pmeerw.net \
--cc=robh+dt@kernel.org \
--cc=sre@kernel.org \
--cc=thomas.petazzoni@free-electrons.com \
--cc=wens@csie.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox