Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ca4ac2f4 authored by Henrique de Moraes Holschuh's avatar Henrique de Moraes Holschuh Committed by Len Brown
Browse files

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: default avatarHenrique de Moraes Holschuh <hmh@hmh.eng.br>
Signed-off-by: default avatarLen Brown <len.brown@intel.com>
parent 4985cd0a
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -2888,10 +2888,11 @@ 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();
		}
	}

	mutex_unlock(&fan_mutex);
	return (rc)? rc : count;