Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 358256
b: refs/heads/master
c: 3600ad5
h: refs/heads/master
v: v3
  • Loading branch information
Martin Peres authored and Ben Skeggs committed Feb 20, 2013
1 parent f52d7ee commit 192b0b3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f1aa4a1de5e13b794a7e31efc0b3ddcda6926c56
refs/heads/master: 3600ad5e1b343f2c259901f736c717f5bc4deb50
7 changes: 7 additions & 0 deletions trunk/drivers/gpu/drm/nouveau/core/subdev/therm/temp.c
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,18 @@ static void
nouveau_therm_temp_safety_checks(struct nouveau_therm *therm)
{
struct nouveau_therm_priv *priv = (void *)therm;
struct nvbios_therm_sensor *s = &priv->bios_sensor;

if (!priv->bios_sensor.slope_div)
priv->bios_sensor.slope_div = 1;
if (!priv->bios_sensor.offset_den)
priv->bios_sensor.offset_den = 1;

/* enforce a minimum hysteresis on thresholds */
s->thrs_fan_boost.hysteresis = max_t(u8, s->thrs_fan_boost.hysteresis, 2);
s->thrs_down_clock.hysteresis = max_t(u8, s->thrs_down_clock.hysteresis, 2);
s->thrs_critical.hysteresis = max_t(u8, s->thrs_critical.hysteresis, 2);
s->thrs_shutdown.hysteresis = max_t(u8, s->thrs_shutdown.hysteresis, 2);
}

/* must be called with alarm_program_lock taken ! */
Expand Down

0 comments on commit 192b0b3

Please sign in to comment.