diff options
Diffstat (limited to 'drivers/hwmon/via686a.c')
-rw-r--r-- | drivers/hwmon/via686a.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/hwmon/via686a.c b/drivers/hwmon/via686a.c index 05ddc88e7dd2..60e94879f415 100644 --- a/drivers/hwmon/via686a.c +++ b/drivers/hwmon/via686a.c | |||
@@ -198,7 +198,7 @@ static inline u8 FAN_TO_REG(long rpm, int div) | |||
198 | but the function is very linear in the useful range (0-80 deg C), so | 198 | but the function is very linear in the useful range (0-80 deg C), so |
199 | we'll just use linear interpolation for 10-bit readings.) So, tempLUT | 199 | we'll just use linear interpolation for 10-bit readings.) So, tempLUT |
200 | is the temp at via register values 0-255: */ | 200 | is the temp at via register values 0-255: */ |
201 | static const long tempLUT[] = | 201 | static const s16 tempLUT[] = |
202 | { -709, -688, -667, -646, -627, -607, -589, -570, -553, -536, -519, | 202 | { -709, -688, -667, -646, -627, -607, -589, -570, -553, -536, -519, |
203 | -503, -487, -471, -456, -442, -428, -414, -400, -387, -375, | 203 | -503, -487, -471, -456, -442, -428, -414, -400, -387, -375, |
204 | -362, -350, -339, -327, -316, -305, -295, -285, -275, -265, | 204 | -362, -350, -339, -327, -316, -305, -295, -285, -275, -265, |
@@ -270,7 +270,7 @@ static inline u8 TEMP_TO_REG(long val) | |||
270 | } | 270 | } |
271 | 271 | ||
272 | /* for 8-bit temperature hyst and over registers */ | 272 | /* for 8-bit temperature hyst and over registers */ |
273 | #define TEMP_FROM_REG(val) (tempLUT[(val)] * 100) | 273 | #define TEMP_FROM_REG(val) ((long)tempLUT[val] * 100) |
274 | 274 | ||
275 | /* for 10-bit temperature readings */ | 275 | /* for 10-bit temperature readings */ |
276 | static inline long TEMP_FROM_REG10(u16 val) | 276 | static inline long TEMP_FROM_REG10(u16 val) |