diff options
author | Guenter Roeck <linux@roeck-us.net> | 2014-02-15 17:54:06 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-03-11 16:10:01 -0700 |
commit | 8d36299431351e5c3a893d9c1eae7579ebc57ad5 (patch) | |
tree | 0fff306be2a8ad2253553a8ef1bcbf61c5dad5c9 | |
parent | 564a4d6c3205fc001579c00a0ce19b665f860487 (diff) |
hwmon: (max1668) Fix writing the minimum temperature
commit 500a91571f0a5d0d3242d83802ea2fd1faccc66e upstream.
When trying to set the minimum temperature, the driver was erroneously
writing the maximum temperature into the chip.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Reviewed-by: Jean Delvare <jdelvare@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/hwmon/max1668.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hwmon/max1668.c b/drivers/hwmon/max1668.c index 335b183d7c0..f058886ca89 100644 --- a/drivers/hwmon/max1668.c +++ b/drivers/hwmon/max1668.c @@ -243,7 +243,7 @@ static ssize_t set_temp_min(struct device *dev, data->temp_min[index] = SENSORS_LIMIT(temp/1000, -128, 127); if (i2c_smbus_write_byte_data(client, MAX1668_REG_LIML_WR(index), - data->temp_max[index])) + data->temp_min[index])) count = -EIO; mutex_unlock(&data->update_lock); |