From 2704f0e69f9e191c6f5873ebfc878e4be1893ef8 Mon Sep 17 00:00:00 2001 From: Pavel Machek Date: Tue, 11 Jul 2006 22:56:14 +0100 Subject: [PATCH] [ARM] 3725/1: sharpsl_pm: warn about wrong temperature Patch from Pavel Machek Also warn users about charging in unsuitable temperature. Signed-off-by: Pavel Machek Acked-by: Richard Purdie Acked-by: Richard Purdie Signed-off-by: Russell King --- arch/arm/common/sharpsl_pm.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/arm/common/sharpsl_pm.c b/arch/arm/common/sharpsl_pm.c index 045e37e07330..59b5ddec480f 100644 --- a/arch/arm/common/sharpsl_pm.c +++ b/arch/arm/common/sharpsl_pm.c @@ -412,8 +412,10 @@ static int sharpsl_check_battery_temp(void) val = get_select_val(buff); dev_dbg(sharpsl_pm.dev, "Temperature: %d\n", val); - if (val > sharpsl_pm.machinfo->charge_on_temp) + if (val > sharpsl_pm.machinfo->charge_on_temp) { + printk(KERN_WARNING "Not charging: temperature out of limits.\n"); return -1; + } return 0; }