mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Timon Baetz <timon.baetz@protonmail.com>
To: Sebastian Reichel <sre@kernel.org>
Cc: Geordan Neukum <gneukum1@gmail.com>,
	Timon Baetz <timon.baetz@protonmail.com>,
	linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH] power: supply: max17042_battery: Reorder power supply properties
Date: Thu, 19 Nov 2020 21:32:46 +0000	[thread overview]
Message-ID: <20201119213117.1385219-1-timon.baetz@protonmail.com> (raw)

Commit 21b01cc879cc ("power: supply: max17042_battery: Add support for
the TTE_NOW prop") added a new property (TIME_TO_EMPTY_NOW) at end of
max17042_battery_props.

Reorder max17042_battery_props to properly ignore CURRENT_NOW and
CURRENT_AVG when current sense is disabled.

Signed-off-by: Timon Baetz <timon.baetz@protonmail.com>
---
 drivers/power/supply/max17042_battery.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/power/supply/max17042_battery.c b/drivers/power/supply/max17042_battery.c
index f284547913d6..672c75639a37 100644
--- a/drivers/power/supply/max17042_battery.c
+++ b/drivers/power/supply/max17042_battery.c
@@ -85,9 +85,9 @@ static enum power_supply_property max17042_battery_props[] = {
 	POWER_SUPPLY_PROP_TEMP_MAX,
 	POWER_SUPPLY_PROP_HEALTH,
 	POWER_SUPPLY_PROP_SCOPE,
+	POWER_SUPPLY_PROP_TIME_TO_EMPTY_NOW,
 	POWER_SUPPLY_PROP_CURRENT_NOW,
 	POWER_SUPPLY_PROP_CURRENT_AVG,
-	POWER_SUPPLY_PROP_TIME_TO_EMPTY_NOW,
 };
 
 static int max17042_get_temperature(struct max17042_chip *chip, int *temp)
-- 
2.25.1



                 reply	other threads:[~2020-11-19 21:33 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20201119213117.1385219-1-timon.baetz@protonmail.com \
    --to=timon.baetz@protonmail.com \
    --cc=gneukum1@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.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

all inboxes | Powered by JetHome®