linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] test_power: Fix battery_current initial value
@ 2020-07-29 12:14 lh lin
  2020-07-29 20:38 ` Sebastian Reichel
  0 siblings, 1 reply; 2+ messages in thread
From: lh lin @ 2020-07-29 12:14 UTC (permalink / raw)
  To: Sebastian Reichel, linux-pm, linux-kernel, linux-arm-kernel
  Cc: YJ Chiang, Lecopzer Chen, LH Lin

From: LH Lin <lh.lin@mediatek.com>

Since default battery_status is POWER_SUPPLY_STATUS_DISCHARGING,
we should change default battery_current to a negative value.

Signed-off-by: LH Lin <lh.lin@mediatek.com>
---
 drivers/power/supply/test_power.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/power/supply/test_power.c b/drivers/power/supply/test_power.c
index 65c23ef6408d..4f29f0f096f5 100644
--- a/drivers/power/supply/test_power.c
+++ b/drivers/power/supply/test_power.c
@@ -34,7 +34,7 @@ static int battery_technology		= POWER_SUPPLY_TECHNOLOGY_LION;
 static int battery_capacity		= 50;
 static int battery_voltage		= 3300;
 static int battery_charge_counter	= -1000;
-static int battery_current		= 1600;
+static int battery_current		= -1600;
 
 static bool module_initialized;
 
-- 
2.18.0

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] test_power: Fix battery_current initial value
  2020-07-29 12:14 [PATCH] test_power: Fix battery_current initial value lh lin
@ 2020-07-29 20:38 ` Sebastian Reichel
  0 siblings, 0 replies; 2+ messages in thread
From: Sebastian Reichel @ 2020-07-29 20:38 UTC (permalink / raw)
  To: lh lin; +Cc: linux-pm, linux-kernel, linux-arm-kernel, YJ Chiang, Lecopzer Chen

[-- Attachment #1: Type: text/plain, Size: 1002 bytes --]

Hi,

On Wed, Jul 29, 2020 at 08:14:00PM +0800, lh lin wrote:
> From: LH Lin <lh.lin@mediatek.com>
> 
> Since default battery_status is POWER_SUPPLY_STATUS_DISCHARGING,
> we should change default battery_current to a negative value.
> 
> Signed-off-by: LH Lin <lh.lin@mediatek.com>
> ---

Thanks, queued.

-- Sebastian

>  drivers/power/supply/test_power.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/power/supply/test_power.c b/drivers/power/supply/test_power.c
> index 65c23ef6408d..4f29f0f096f5 100644
> --- a/drivers/power/supply/test_power.c
> +++ b/drivers/power/supply/test_power.c
> @@ -34,7 +34,7 @@ static int battery_technology		= POWER_SUPPLY_TECHNOLOGY_LION;
>  static int battery_capacity		= 50;
>  static int battery_voltage		= 3300;
>  static int battery_charge_counter	= -1000;
> -static int battery_current		= 1600;
> +static int battery_current		= -1600;
>  
>  static bool module_initialized;
>  
> -- 
> 2.18.0

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-07-29 20:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-29 12:14 [PATCH] test_power: Fix battery_current initial value lh lin
2020-07-29 20:38 ` Sebastian Reichel

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).