projects
/
linux-4.9.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
76c0295
)
drm/nouveau/therm: disable auto fan management if temperature is not available
author
Martin Peres
<martin.peres@labri.fr>
Thu, 14 Mar 2013 23:21:07 +0000
(
00:21
+0100)
committer
Ben Skeggs
<bskeggs@redhat.com>
Mon, 18 Mar 2013 01:15:27 +0000
(11:15 +1000)
Signed-off-by: Martin Peres <martin.peres@labri.fr>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/core/subdev/therm/base.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/nouveau/core/subdev/therm/base.c
b/drivers/gpu/drm/nouveau/core/subdev/therm/base.c
index 3f8083f41be8cee36dcb7dbada45037882ae13b7..d6a05589c9418b08cc01e401fe1a80a7a1257e66 100644
(file)
--- a/
drivers/gpu/drm/nouveau/core/subdev/therm/base.c
+++ b/
drivers/gpu/drm/nouveau/core/subdev/therm/base.c
@@
-149,6
+149,11
@@
nouveau_therm_fan_mode(struct nouveau_therm *therm, int mode)
(mode != NOUVEAU_THERM_CTRL_NONE && device->card_type >= NV_C0))
return -EINVAL;
+ /* do not allow automatic fan management if the thermal sensor is
+ * not available */
+ if (priv->mode == 2 && therm->temp_get(therm) < 0)
+ return -EINVAL;
+
if (priv->mode == mode)
return 0;