aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJiri Slaby <jirislaby@gmail.com>2009-07-11 13:42:37 +0200
committerGreg Kroah-Hartman <gregkh@suse.de>2009-07-30 14:40:16 -0700
commit9783772fe815ac811a3d73757a2f86ec9dceef00 (patch)
treeded7f677b756d5906c2cc4ba236420b39236c6f4
parent63510144577601e1747480a250c6c01aebeb704e (diff)
downloadlinux-linaro-stable-9783772fe815ac811a3d73757a2f86ec9dceef00.tar.gz
hwmon: (max6650) Fix lock imbalance
commit 025dc740d01f99ccba945df1f9ef9e06b1c15d96 upstream. Add omitted update_lock to one switch/case in set_div. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Acked-by: Hans J. Koch <hjk@linutronix.de> Signed-off-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/hwmon/max6650.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/hwmon/max6650.c b/drivers/hwmon/max6650.c
index f27af6a9da41..65cf25f9d2f2 100644
--- a/drivers/hwmon/max6650.c
+++ b/drivers/hwmon/max6650.c
@@ -407,6 +407,7 @@ static ssize_t set_div(struct device *dev, struct device_attribute *devattr,
data->count = 3;
break;
default:
+ mutex_unlock(&data->update_lock);
dev_err(&client->dev,
"illegal value for fan divider (%d)\n", div);
return -EINVAL;