Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1491211
| From | Krzysztof Kozlowski <krzk@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 2/2] power: supply: max17042_battery: add technology property support |
| Date | 2016-09-26 13:00 +0200 |
| Message-ID | <slBNE-2PA-9@gated-at.bofh.it> (permalink) |
| References | <slp06-3eH-13@gated-at.bofh.it> <slp06-3eH-25@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Sun, Sep 25, 2016 at 11:10:11PM +0200, Wolfgang Wiedmeyer wrote:
> This patch reports the battery technology as Li-ion.
>
> Signed-off-by: Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de>
> ---
> drivers/power/max17042_battery.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/power/max17042_battery.c b/drivers/power/max17042_battery.c
> index 20cb1fd..43cb5df 100644
> --- a/drivers/power/max17042_battery.c
> +++ b/drivers/power/max17042_battery.c
> @@ -92,6 +92,7 @@ static enum power_supply_property max17042_battery_props[] = {
> POWER_SUPPLY_PROP_TEMP_MIN,
> POWER_SUPPLY_PROP_TEMP_MAX,
> POWER_SUPPLY_PROP_HEALTH,
> + POWER_SUPPLY_PROP_TECHNOLOGY,
> POWER_SUPPLY_PROP_CURRENT_NOW,
> POWER_SUPPLY_PROP_CURRENT_AVG,
> };
> @@ -296,6 +297,9 @@ static int max17042_get_property(struct power_supply *psy,
> if (ret < 0)
> return ret;
> break;
> + case POWER_SUPPLY_PROP_TECHNOLOGY:
> + val->intval = POWER_SUPPLY_TECHNOLOGY_LION;
How can you be sure it is always Li-Ion? For wearables and mobiles, rather yes, but
the driver is also used in other devices. Technically, specs are saying
it might be used also with Li-Poly applications.
Best regards,
Krzysztof
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 2/2] power: supply: max17042_battery: add technology property support Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de> - 2016-09-25 23:20 +0200
Re: [PATCH 2/2] power: supply: max17042_battery: add technology property support Krzysztof Kozlowski <krzk@kernel.org> - 2016-09-26 13:00 +0200
Re: [PATCH 2/2] power: supply: max17042_battery: add technology property support Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de> - 2016-09-26 15:00 +0200
Re: [PATCH 2/2] power: supply: max17042_battery: add technology property support Krzysztof Kozlowski <krzk@kernel.org> - 2016-09-26 18:40 +0200
csiph-web