* [lm-sensors] [PATCH 1/3] hwmon: (max1668) Fix writing the minimum temperature
@ 2014-02-16 2:07 Guenter Roeck
2014-02-18 21:39 ` Jean Delvare
0 siblings, 1 reply; 2+ messages in thread
From: Guenter Roeck @ 2014-02-16 2:07 UTC (permalink / raw)
To: lm-sensors
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>
---
Candidate for -stable.
drivers/hwmon/max1668.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/hwmon/max1668.c b/drivers/hwmon/max1668.c
index a762635..029b65e 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] = 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);
--
1.7.9.7
_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [lm-sensors] [PATCH 1/3] hwmon: (max1668) Fix writing the minimum temperature
2014-02-16 2:07 [lm-sensors] [PATCH 1/3] hwmon: (max1668) Fix writing the minimum temperature Guenter Roeck
@ 2014-02-18 21:39 ` Jean Delvare
0 siblings, 0 replies; 2+ messages in thread
From: Jean Delvare @ 2014-02-18 21:39 UTC (permalink / raw)
To: lm-sensors
On Sat, 15 Feb 2014 18:07:59 -0800, Guenter Roeck wrote:
> 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>
> ---
> Candidate for -stable.
>
> drivers/hwmon/max1668.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/hwmon/max1668.c b/drivers/hwmon/max1668.c
> index a762635..029b65e 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] = 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);
>
Huh, bad bug, good catch.
Definitely good for -stable, even though it may not be the most popular
hwmon driver.
Reviewed-by: Jean Delvare <jdelvare@suse.de>
--
Jean Delvare
Suse L3 Support
_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-02-18 21:39 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-16 2:07 [lm-sensors] [PATCH 1/3] hwmon: (max1668) Fix writing the minimum temperature Guenter Roeck
2014-02-18 21:39 ` Jean Delvare
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.