diff options
Diffstat (limited to 'drivers/hwmon/max6642.c')
-rw-r--r-- | drivers/hwmon/max6642.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hwmon/max6642.c b/drivers/hwmon/max6642.c index 223461a6d70f..57d58cd32206 100644 --- a/drivers/hwmon/max6642.c +++ b/drivers/hwmon/max6642.c | |||
@@ -239,7 +239,7 @@ static ssize_t set_temp_max(struct device *dev, struct device_attribute *attr, | |||
239 | return err; | 239 | return err; |
240 | 240 | ||
241 | mutex_lock(&data->update_lock); | 241 | mutex_lock(&data->update_lock); |
242 | data->temp_high[attr2->nr] = SENSORS_LIMIT(temp_to_reg(val), 0, 255); | 242 | data->temp_high[attr2->nr] = clamp_val(temp_to_reg(val), 0, 255); |
243 | i2c_smbus_write_byte_data(client, attr2->index, | 243 | i2c_smbus_write_byte_data(client, attr2->index, |
244 | data->temp_high[attr2->nr]); | 244 | data->temp_high[attr2->nr]); |
245 | mutex_unlock(&data->update_lock); | 245 | mutex_unlock(&data->update_lock); |