summaryrefslogtreecommitdiffstats
path: root/drivers/misc/thinkpad_acpi.c
diff options
context:
space:
mode:
authorHenrique de Moraes Holschuh <hmh@hmh.eng.br>2007-04-28 03:00:11 +0200
committerLen Brown <len.brown@intel.com>2007-04-29 03:41:18 +0200
commitca4ac2f48a4502bbbfcb47b86312273c28194f53 (patch)
treea0403f74925a04b785903d6c8eb4b3432ae46b52 /drivers/misc/thinkpad_acpi.c
parentACPI: thinkpad-acpi: do not arm fan watchdog if it would not work (diff)
downloadlinux-ca4ac2f48a4502bbbfcb47b86312273c28194f53.tar.xz
linux-ca4ac2f48a4502bbbfcb47b86312273c28194f53.zip
ACPI: thinkpad-acpi: fix a fan watchdog invocation
The fan control watchdog was being called in one place even when the fan control operation had failed. Fix it. Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br> Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/misc/thinkpad_acpi.c')
-rw-r--r--drivers/misc/thinkpad_acpi.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/misc/thinkpad_acpi.c b/drivers/misc/thinkpad_acpi.c
index f824259fa611..b85f0960e608 100644
--- a/drivers/misc/thinkpad_acpi.c
+++ b/drivers/misc/thinkpad_acpi.c
@@ -2888,9 +2888,10 @@ static ssize_t fan_pwm1_store(struct device *dev,
if (!rc && (status &
(TP_EC_FAN_AUTO | TP_EC_FAN_FULLSPEED)) == 0) {
rc = fan_set_level(newlevel);
- if (!rc)
+ if (!rc) {
fan_update_desired_level(newlevel);
- fan_watchdog_reset();
+ fan_watchdog_reset();
+ }
}
mutex_unlock(&fan_mutex);