linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Artur Rojek <contact@artur-rojek.eu>
To: Rob Herring <robh@kernel.org>
Cc: Sebastian Reichel <sre@kernel.org>,
	Jonathan Cameron <jic23@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	linux-pm@vger.kernel.org, linux-iio@vger.kernel.org,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	Paul Cercueil <paul@crapouillou.net>
Subject: Re: [PATCH 4/7] dt-bindings: power: supply: Add docs for Ingenic JZ47xx SoCs battery.
Date: Thu, 28 Feb 2019 21:22:15 +0100	[thread overview]
Message-ID: <ed7c6a70b6fe77fff440710fc72506d6@artur-rojek.eu> (raw)
In-Reply-To: <20190228184822.GA17624@bogus>

Hi Rob,

thanks for the review.

On 2019-02-28 19:48, Rob Herring wrote:
> On Sun, Feb 17, 2019 at 03:29:13PM +0100, Artur Rojek wrote:
>> Add documentation for the ingenic-battery driver, used on JZ47xx SoCs.
>> 
>> Signed-off-by: Artur Rojek <contact@artur-rojek.eu>
>> ---
>>  .../bindings/power/supply/ingenic,battery.txt | 31 
>> +++++++++++++++++++
>>  1 file changed, 31 insertions(+)
>>  create mode 100644 
>> Documentation/devicetree/bindings/power/supply/ingenic,battery.txt
>> 
>> diff --git 
>> a/Documentation/devicetree/bindings/power/supply/ingenic,battery.txt 
>> b/Documentation/devicetree/bindings/power/supply/ingenic,battery.txt
>> new file mode 100644
>> index 000000000000..66430bf73815
>> --- /dev/null
>> +++ 
>> b/Documentation/devicetree/bindings/power/supply/ingenic,battery.txt
>> @@ -0,0 +1,31 @@
>> +* Ingenic JZ47xx battery bindings
>> +
>> +Required properties:
>> +
>> +- compatible: Must be "ingenic,jz4740-battery".
>> +- io-channels: phandle and IIO specifier pair to the IIO device.
>> +  Format described in iio-bindings.txt.
>> +- monitored-battery: phandle to a "simple-battery" compatible node.
>> +
>> +The "monitored-battery" property must be a phandle to a node using 
>> the format
>> +described in battery.txt, with the following properties being 
>> required:
>> +
>> +- voltage-min-design-microvolt: Drained battery voltage.
>> +- voltage-max-design-microvolt: Fully charged battery voltage.
>> +
>> +Example:
>> +
>> +#include <dt-bindings/iio/adc/ingenic,adc.h>
>> +
>> +simple_battery: battery {
>> +	compatible = "simple-battery";
>> +	voltage-min-design-microvolt = <3600000>;
>> +	voltage-max-design-microvolt = <4200000>;
>> +};
>> +
>> +ingenic_battery {
>> +	compatible = "ingenic,jz4740-battery";
>> +	io-channels = <&adc INGENIC_ADC_BATTERY>;
>> +	io-channel-names = "battery";
>> +	monitored-battery = <&simple_battery>;
> 
> Isn't this just an ADC monitored battery? What's specific to JZ4740?
> 
> Maybe a generic binding is appropriate here?
This isn't quite a generic driver; see Jonathan's reply to patch 5/7.

- Artur
> 
> Rob


  parent reply	other threads:[~2019-02-28 20:22 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-17 14:29 [PATCH 1/7] iio: inkern: API for reading available iio channel attribute values Artur Rojek
2019-02-17 14:29 ` [PATCH 2/7] power: supply: core: Add a field to support battery max voltage Artur Rojek
2019-02-17 14:29 ` [PATCH 3/7] dt-bindings: power: supply: Add voltage-max-design-microvolt property Artur Rojek
2019-02-17 14:29 ` [PATCH 4/7] dt-bindings: power: supply: Add docs for Ingenic JZ47xx SoCs battery Artur Rojek
2019-02-28 18:48   ` Rob Herring
2019-02-28 18:56     ` Paul Cercueil
2019-02-28 20:22     ` Artur Rojek [this message]
2019-02-17 14:29 ` [PATCH 5/7] power: supply: add Ingenic JZ47xx battery driver Artur Rojek
2019-02-20 11:14   ` Jonathan Cameron
2019-02-20 15:24     ` Artur Rojek
2019-02-21 19:18     ` Artur Rojek
2019-03-03 16:53       ` Jonathan Cameron
2019-02-17 14:37 ` [PATCH 1/7] iio: inkern: API for reading available iio channel attribute values Artur Rojek
2019-02-20 11:14 ` Jonathan Cameron

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=ed7c6a70b6fe77fff440710fc72506d6@artur-rojek.eu \
    --to=contact@artur-rojek.eu \
    --cc=devicetree@vger.kernel.org \
    --cc=jic23@kernel.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=paul@crapouillou.net \
    --cc=robh@kernel.org \
    --cc=sre@kernel.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;
as well as URLs for NNTP newsgroup(s).