From: Guenter Roeck Date: Wed, 1 May 2013 21:26:00 +0000 (-0700) Subject: Replace SENSORS_LIMIT in lm75.h with clamp_val X-Git-Tag: nct6775-v1.0~1 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=56ac083245b98674d4e3e34e067b84a16041ffb6;p=groeck-nct6775 Replace SENSORS_LIMIT in lm75.h with clamp_val Signed-off-by: Guenter Roeck --- diff --git a/lm75.h b/lm75.h index e547a3e..4519e4d 100644 --- a/lm75.h +++ b/lm75.h @@ -36,7 +36,7 @@ REG: (0.5C/bit, two's complement) << 7 */ static inline u16 LM75_TEMP_TO_REG(long temp) { - int ntemp = SENSORS_LIMIT(temp, LM75_TEMP_MIN, LM75_TEMP_MAX); + int ntemp = clamp_val(temp, LM75_TEMP_MIN, LM75_TEMP_MAX); ntemp += (ntemp<0 ? -250 : 250); return (u16)((ntemp / 500) << 7); }