From 5bfedac045082a97e20d47d876071279ef984d28 Mon Sep 17 00:00:00 2001 From: Christian Hohnstaedt Date: Thu, 16 Aug 2007 11:40:10 +0200 Subject: hwmon: Allow writing of negative trigger temperatures - replace differing temperature variable types by long - use strtol() instead of strtoul() for conversion Signed-off-by: Christian Hohnstaedt Acked-by: Jean Delvare Signed-off-by: Mark M. Hoffman --- drivers/hwmon/lm75.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/hwmon/lm75.h') diff --git a/drivers/hwmon/lm75.h b/drivers/hwmon/lm75.h index af7dc650ee1..7c93454bb4e 100644 --- a/drivers/hwmon/lm75.h +++ b/drivers/hwmon/lm75.h @@ -33,7 +33,7 @@ /* TEMP: 0.001C/bit (-55C to +125C) REG: (0.5C/bit, two's complement) << 7 */ -static inline u16 LM75_TEMP_TO_REG(int temp) +static inline u16 LM75_TEMP_TO_REG(long temp) { int ntemp = SENSORS_LIMIT(temp, LM75_TEMP_MIN, LM75_TEMP_MAX); ntemp += (ntemp<0 ? -250 : 250); -- cgit v1.2.3