From 794f5434942614e5e8f70b9d65b9275e11ad1510 Mon Sep 17 00:00:00 2001 From: Hans de Goede Date: Sun, 22 Jul 2007 20:15:31 +0200 Subject: [PATCH] hwmon: fscher control update bugfix Here is another small fscher bugfix for 2.6.23 merging, this was caught by Jean while reviewing my other bugfix. The driver was updating its copy of the control register as if it was clear to write, but its regular read/write. This patch fixes this. Signed-off-by: Hans de Goede Acked-by: Jean Delvare Signed-off-by: Mark M. Hoffman --- drivers/hwmon/fscher.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/hwmon/fscher.c b/drivers/hwmon/fscher.c index 19717752cf..f3aa188a5d 100644 --- a/drivers/hwmon/fscher.c +++ b/drivers/hwmon/fscher.c @@ -599,7 +599,7 @@ static ssize_t set_control(struct i2c_client *client, struct fscher_data *data, unsigned long v = simple_strtoul(buf, NULL, 10) & 0x01; mutex_lock(&data->update_lock); - data->global_control &= ~v; + data->global_control = v; fscher_write_value(client, reg, v); mutex_unlock(&data->update_lock); return count; -- 2.39.2