summaryrefslogtreecommitdiff
path: root/drivers/hwmon/lm75.c
diff options
context:
space:
mode:
authorChristian Hohnstaedt <chohnstaedt@innominate.com>2007-08-16 13:40:10 +0400
committerMark M. Hoffman <mhoffman@lightlink.com>2007-10-10 06:56:29 +0400
commit5bfedac045082a97e20d47d876071279ef984d28 (patch)
treec6432db00589d4858ca1b4a04624dc74be5ba181 /drivers/hwmon/lm75.c
parentdcf3b5fb7fb6e1b56bfaf705e665b04870213768 (diff)
downloadlinux-5bfedac045082a97e20d47d876071279ef984d28.tar.xz
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 <chohnstaedt@innominate.com> Acked-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
Diffstat (limited to 'drivers/hwmon/lm75.c')
-rw-r--r--drivers/hwmon/lm75.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hwmon/lm75.c b/drivers/hwmon/lm75.c
index a40166ffad12..4fa32205e44c 100644
--- a/drivers/hwmon/lm75.c
+++ b/drivers/hwmon/lm75.c
@@ -95,7 +95,7 @@ static ssize_t set_temp(struct device *dev, struct device_attribute *da,
struct i2c_client *client = to_i2c_client(dev);
struct lm75_data *data = i2c_get_clientdata(client);
int nr = attr->index;
- unsigned long temp = simple_strtoul(buf, NULL, 10);
+ long temp = simple_strtol(buf, NULL, 10);
mutex_lock(&data->update_lock);
data->temp[nr] = LM75_TEMP_TO_REG(temp);