Browse Source

drm/nouveau/therm: disable temperature management if the sensor isn't readable

Signed-off-by: Martin Peres <martin.peres@labri.fr>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Martin Peres 12 years ago
parent
commit
bf55eb843d
1 changed files with 1 additions and 1 deletions
  1. 1 1
      drivers/gpu/drm/nouveau/core/subdev/therm/temp.c

+ 1 - 1
drivers/gpu/drm/nouveau/core/subdev/therm/temp.c

@@ -193,7 +193,7 @@ alarm_timer_callback(struct nouveau_alarm *alarm)
 					     NOUVEAU_THERM_THRS_SHUTDOWN);
 
 	/* schedule the next poll in one second */
-	if (list_empty(&alarm->head))
+	if (therm->temp_get(therm) >= 0 && list_empty(&alarm->head))
 		ptimer->alarm(ptimer, 1000 * 1000 * 1000, alarm);
 
 	spin_unlock_irqrestore(&priv->sensor.alarm_program_lock, flags);