mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-27 06:30:56 +07:00
drm/nouveau/therm: check for sensor presence with requested mode, not current
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
This commit is contained in:
parent
cbc53c1679
commit
dcd9262b3b
@ -179,7 +179,7 @@ nouveau_therm_fan_mode(struct nouveau_therm *therm, int mode)
|
||||
|
||||
/* do not allow automatic fan management if the thermal sensor is
|
||||
* not available */
|
||||
if (priv->mode == NOUVEAU_THERM_CTRL_AUTO && therm->temp_get(therm) < 0)
|
||||
if (mode == NOUVEAU_THERM_CTRL_AUTO && therm->temp_get(therm) < 0)
|
||||
return -EINVAL;
|
||||
|
||||
if (priv->mode == mode)
|
||||
|
Loading…
Reference in New Issue
Block a user