[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aM0UBoynaX7ln2Tw@git-send.richtek.com>
Date: Fri, 19 Sep 2025 16:27:50 +0800
From: ChiYuan Huang <cy_huang@...htek.com>
To: Sebastian Reichel <sebastian.reichel@...labora.com>
CC: Krzysztof Kozlowski <krzk+dt@...nel.org>, Rob Herring <robh@...nel.org>,
Conor Dooley <conor+dt@...nel.org>, <devicetree@...r.kernel.org>,
<linux-pm@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH RESEND v2 2/3] power: supply: rt9756: Add Richtek RT9756
smart cap divider charger
On Fri, Sep 19, 2025 at 01:43:02AM +0200, Sebastian Reichel wrote:
Hi, Sebastian:
> Hi,
>
> On Thu, Aug 14, 2025 at 03:31:07PM +0800, cy_huang@...htek.com wrote:
> > From: ChiYuan Huang <cy_huang@...htek.com>
> >
> > Add support for RT9756 smart cap divider charger.
> >
> > The RT9759 is a high efficiency and high charge current charger. The
> > maximum charge current is up to 8A. It integrates a dual-phase charge
> > pump core with ADC monitoring.
> >
> > Signed-off-by: ChiYuan Huang <cy_huang@...htek.com>
> > ---
>
> Sorry for the delay. This looks mostly good, but I really don't like
> the custom properties for the battery voltage and current. Instead
> of handling via custom properties, register a second power_supply
> device with POWER_SUPPLY_TYPE_BATTERY and use the normal
> POWER_SUPPLY_PROP_VOLTAGE_NOW and POWER_SUPPLY_PROP_CURRENT_NOW
> properties. Having custom properties for the watchdog and the
> operating mode is fine with me, as these two things are quite
> specific to the RT9756 chips.
>
> While you are at it, you can also add this constant property for
> the battery device:
>
> POWER_SUPPLY_PROP_TECHNOLOGY = POWER_SUPPLY_TECHNOLOGY_LION
>
> Also the charger's power_supply_config should set the
> .supplied_to, listing the battery device, so that the kernel
> is aware of the link between those two devices.
>
Essentianly, these two attributes are only used for battery monitoring
from charger side perspective.
As you know, RT9756 is a charger, not fuelgauge. To register a second
power supply seems weird. If what you cares is the keyword 'battery',
I can change it to 'vout'. What do you think?
Regards,
ChiYuan.
> Greetings,
>
> -- Sebastian
Powered by blists - more mailing lists