mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-06 01:49:46 +00:00
hwmon: (max1668) Fix writing the minimum temperature
commit 500a91571f 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>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
cda6b481a4
commit
00b29b3d14
@@ -243,7 +243,7 @@ static ssize_t set_temp_min(struct device *dev,
|
||||
data->temp_min[index] = clamp_val(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);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user