linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: Tobias Schramm <t.schramm@manjaro.org>
Cc: Sebastian Reichel <sre@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	linux-pm@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [RESEND 2/2] dt-bindings: power: supply: cw2015_battery: add device tree binding documentation
Date: Tue, 14 Jan 2020 20:01:55 -0600	[thread overview]
Message-ID: <20200115020155.GA7802@bogus> (raw)
In-Reply-To: <20200109113955.2882-3-t.schramm@manjaro.org>

On Thu, Jan 09, 2020 at 12:39:55PM +0100, Tobias Schramm wrote:
> This patch adds the ds binding document for the cw2015 Fuel Gauge.

ds?

> 
> Signed-off-by: Tobias Schramm <t.schramm@manjaro.org>
> ---
>  .../bindings/power/supply/cw2015_battery.txt  | 37 +++++++++++++++++++
>  1 file changed, 37 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/power/supply/cw2015_battery.txt

Please make this a DT schema. See 
Documentation/devicetree/writing-schema.rst.

> 
> diff --git a/Documentation/devicetree/bindings/power/supply/cw2015_battery.txt b/Documentation/devicetree/bindings/power/supply/cw2015_battery.txt
> new file mode 100644
> index 000000000000..e847391268f3
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/power/supply/cw2015_battery.txt
> @@ -0,0 +1,37 @@
> +cw2015_battery
> +~~~~~~~~~~~~~~~~
> +
> +The cellwise CW2015 is a shuntless single/multi-cell battery fuel gauge.
> +
> +Required properties :
> + - compatible : "cellwise,cw2015"
> + - cellwise,bat-config-info : Binary battery info blob
> +
> +Optional properties :
> + - cellwise,monitor-interval : Measurement interval in seconds

Use standard unit suffix.

> + - cellwise,voltage-divider : Voltage divider for multi-cell packs,
> +   specified as two integer values <high side>, <low side> in ohms.

Use standard unit suffix (-ohms).

> + - cellwise,virtual-power : Default to disconnected battery state (gauge in pack mode)
> + - cellwise,design-capacity : Design capacity of the battery cell in milliampere hours

I think we have a standard property for this. Properties of the battery 
should be in a battery node.

> + - cellwise,alert-level : Low battery alarm level in percent
> +
> +Example:
> +	cw2015@62 {
> +		status = "okay";

Don't show status in examples.

> +		compatible = "cellwise,cw201x";
> +		reg = <0x62>;
> +		cellwise,bat-config-info = <
> +			0x17 0x67 0x80 0x73 0x6E 0x6C 0x6B 0x63
> +			0x77 0x51 0x5C 0x58 0x50 0x4C 0x48 0x36
> +			0x15 0x0C 0x0C 0x19 0x5B 0x7D 0x6F 0x69
> +			0x69 0x5B 0x0C 0x29 0x20 0x40 0x52 0x59
> +			0x57 0x56 0x54 0x4F 0x3B 0x1F 0x7F 0x17
> +			0x06 0x1A 0x30 0x5A 0x85 0x93 0x96 0x2D
> +			0x48 0x77 0x9C 0xB3 0x80 0x52 0x94 0xCB
> +			0x2F 0x00 0x64 0xA5 0xB5 0x11 0xF0 0x11
> +		>;
> +		cellwise,monitor-interval = <5>;
> +		cellwise,virtual-power;
> +		cellwise,design-capacity = <9800>;
> +		power-supplies = <&mains_charger>, <&usb_charger>;

Not documented.

> +	}
> -- 
> 2.24.1
> 

      reply	other threads:[~2020-01-15  2:02 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-09 11:39 [RESEND 0/2] power: supply: add support for CW2015 fuel gauge Tobias Schramm
2020-01-09 11:39 ` [RESEND 1/2] power: supply: add CW2015 Fuel Gauge driver Tobias Schramm
2020-01-14  2:06   ` Sebastian Reichel
2020-01-14  7:17     ` Tobias Schramm
2020-01-09 11:39 ` [RESEND 2/2] dt-bindings: power: supply: cw2015_battery: add device tree binding documentation Tobias Schramm
2020-01-15  2:01   ` Rob Herring [this message]

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=20200115020155.GA7802@bogus \
    --to=robh@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=sre@kernel.org \
    --cc=t.schramm@manjaro.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).