From: Svyatoslav Ryhel <clamor95@gmail.com>
To: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Cc: Iskren Chernev <me@iskren.info>,
Marek Szyprowski <m.szyprowski@samsung.com>,
Matheus Castello <matheus@castello.eng.br>,
Sebastian Reichel <sre@kernel.org>,
Rob Herring <robh+dt@kernel.org>,
linux-pm@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v1 1/4] dt-bindings: power: supply: maxim,max17040: update properties
Date: Wed, 8 Mar 2023 11:15:04 +0200 [thread overview]
Message-ID: <CAPVz0n1QDFyHiGAa7UOuuwPiSH+ELiYNeO9-fxPWrOWkWqEuHg@mail.gmail.com> (raw)
In-Reply-To: <95fa5f0f-cf53-7a37-2170-98b81c0982f1@linaro.org>
ср, 8 бер. 2023 р. о 11:04 Krzysztof Kozlowski
<krzysztof.kozlowski@linaro.org> пише:
>
> On 08/03/2023 09:44, Svyatoslav Ryhel wrote:
> > Add simple cell, status, health and temperature properties.
> >
> > Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
> > ---
> > .../bindings/power/supply/maxim,max17040.yaml | 37 +++++++++++++++++++
> > 1 file changed, 37 insertions(+)
> >
> > diff --git a/Documentation/devicetree/bindings/power/supply/maxim,max17040.yaml b/Documentation/devicetree/bindings/power/supply/maxim,max17040.yaml
> > index 3a529326ecbd..6f1c25b4729f 100644
> > --- a/Documentation/devicetree/bindings/power/supply/maxim,max17040.yaml
> > +++ b/Documentation/devicetree/bindings/power/supply/maxim,max17040.yaml
> > @@ -55,6 +55,20 @@ properties:
> > interrupts:
> > maxItems: 1
> >
> > + monitored-battery:
> > + $ref: /schemas/types.yaml#/definitions/phandle
> > + description: phandle to the battery node being monitored
> > +
> > + power-supplies: true
>
> This should be rather specific input name, e.g. vdd-supply.
>
it is not vdd it is actual charger device
> > +
> > + io-channels:
> > + items:
> > + - description: battery temperature
>
>
>
> max17040 does not have ADC temperature input... so is it system
> configuration?
>
yes, I own a device (LG Optimus Vu P895) which uses max17043
coupled with ADC thermal sensor
> > +
> > + io-channel-names:
> > + items:
> > + - const: temp
>
> Drop the names property, not needed for one item.
>
Alright, but driver patch expects temp name. I will look if this
is adjustable.
> > +
> > wakeup-source:
> > type: boolean
> > description: |
> > @@ -95,3 +109,26 @@ examples:
> > wakeup-source;
> > };
> > };
> > + - |
> > + #include <dt-bindings/interrupt-controller/irq.h>
> > + i2c0 {
> > + #address-cells = <1>;
> > + #size-cells = <0>;
> > +
> > + fuel-gauge@36 {
> > + compatible = "maxim,max17043";
> > + reg = <0x36>;
> > +
> > + interrupt-parent = <&gpio>;
> > + interrupts = <144 IRQ_TYPE_EDGE_FALLING>;
> > +
> > + monitored-battery = <&battery>;
> > + power-supplies = <&charger>;
>
> But here you suggests something else than VDD... The hardware does not
> take charger as input. It takes power supply - vdd.
>
Power system allows passing properties from other power devices.
In this case battery health and status are passed from charger.
> > +
> > + io-channels = <&adc 8>;
>
> Just add these to existing example.
>
Not sure if it is a good idea, as you wish.
> > + io-channel-names = "temp";
> > +
> > + maxim,alert-low-soc-level = <10>;
> > + wakeup-source;
> > + };
> > + };
>
> Best regards,
> Krzysztof
>
Best regards,
Svyatoslav R.
next prev parent reply other threads:[~2023-03-08 9:15 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-08 8:44 [PATCH v1 0/4] Add optional properties to MAX17040 Svyatoslav Ryhel
2023-03-08 8:44 ` [PATCH v1 1/4] dt-bindings: power: supply: maxim,max17040: update properties Svyatoslav Ryhel
2023-03-08 9:04 ` Krzysztof Kozlowski
2023-03-08 9:15 ` Svyatoslav Ryhel [this message]
2023-03-08 10:44 ` Krzysztof Kozlowski
2023-03-08 10:51 ` Svyatoslav Ryhel
2023-03-08 10:53 ` Krzysztof Kozlowski
2023-03-08 11:06 ` Svyatoslav Ryhel
2023-03-08 11:12 ` Krzysztof Kozlowski
2023-05-15 22:17 ` Sebastian Reichel
2023-03-08 8:44 ` [PATCH v1 2/4] power: max17040: add simple battery cell support Svyatoslav Ryhel
2023-05-15 22:21 ` Sebastian Reichel
2023-03-08 8:44 ` [PATCH v1 3/4] power: max17040: add passing props from supplier Svyatoslav Ryhel
2023-05-15 22:41 ` Sebastian Reichel
2023-03-08 8:44 ` [PATCH v1 4/4] power: max17040: get thermal data from adc if available Svyatoslav Ryhel
2023-03-08 9:08 ` Krzysztof Kozlowski
2023-03-08 9:23 ` Svyatoslav Ryhel
2023-03-08 10:46 ` Krzysztof Kozlowski
2023-03-09 0:24 ` kernel test robot
2023-03-09 0:24 ` kernel test robot
2023-03-09 0:45 ` kernel test robot
2023-05-15 22:39 ` 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=CAPVz0n1QDFyHiGAa7UOuuwPiSH+ELiYNeO9-fxPWrOWkWqEuHg@mail.gmail.com \
--to=clamor95@gmail.com \
--cc=devicetree@vger.kernel.org \
--cc=krzysztof.kozlowski@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=m.szyprowski@samsung.com \
--cc=matheus@castello.eng.br \
--cc=me@iskren.info \
--cc=robh+dt@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).