lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Sat, 5 Jan 2013 18:52:47 -0800
From:	Anton Vorontsov <anton@...msg.org>
To:	Ramakrishna Pallala <ramakrishna.pallala@...el.com>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] power_supply: add watchdog and safety timer expiries
 under PROP_HEALTH_*

On Fri, Nov 30, 2012 at 01:57:46PM +0530, Ramakrishna Pallala wrote:
> As most of the charger chips come with two kinds of safety features
> related to timing.
> 1. Watchdog Timer (interms of seconds/mins)
> 2. Safety Timer (interms of hours)
> 
> This patch adds these to fault causes in POWER_SUPPLY_PROP_HEALTH_*
> enums so that whenever there is either watchdog timeout or safety timer
> timeout driver could notify the user space accurately about the fault
> and will also be helpful for debug.
> 
> Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@...el.com>

Applied, thanks a lot!

> ---
>  drivers/power/power_supply_sysfs.c |    3 ++-
>  include/linux/power_supply.h       |    2 ++
>  2 files changed, 4 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/power/power_supply_sysfs.c b/drivers/power/power_supply_sysfs.c
> index 40fa3b7..29178f7 100644
> --- a/drivers/power/power_supply_sysfs.c
> +++ b/drivers/power/power_supply_sysfs.c
> @@ -55,7 +55,8 @@ static ssize_t power_supply_show_property(struct device *dev,
>  	};
>  	static char *health_text[] = {
>  		"Unknown", "Good", "Overheat", "Dead", "Over voltage",
> -		"Unspecified failure", "Cold",
> +		"Unspecified failure", "Cold", "Watchdog timer expire",
> +		"Safety timer expire"
>  	};
>  	static char *technology_text[] = {
>  		"Unknown", "NiMH", "Li-ion", "Li-poly", "LiFe", "NiCd",
> diff --git a/include/linux/power_supply.h b/include/linux/power_supply.h
> index 35cdf2c..4e672e1 100644
> --- a/include/linux/power_supply.h
> +++ b/include/linux/power_supply.h
> @@ -54,6 +54,8 @@ enum {
>  	POWER_SUPPLY_HEALTH_OVERVOLTAGE,
>  	POWER_SUPPLY_HEALTH_UNSPEC_FAILURE,
>  	POWER_SUPPLY_HEALTH_COLD,
> +	POWER_SUPPLY_HEALTH_WATCHDOG_TIMER_EXPIRE,
> +	POWER_SUPPLY_HEALTH_SAFETY_TIMER_EXPIRE,
>  };
>  
>  enum {
> -- 
> 1.7.0.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ