Lines Matching refs:temp
129 u16 temp[3]; /* Register values, word */ member
147 static inline u16 DS1621_TEMP_TO_REG(long temp, u8 zbits) in DS1621_TEMP_TO_REG() argument
149 temp = clamp_val(temp, DS1621_TEMP_MIN, DS1621_TEMP_MAX); in DS1621_TEMP_TO_REG()
150 temp = DIV_ROUND_CLOSEST(temp * (1 << (8 - zbits)), 1000) << zbits; in DS1621_TEMP_TO_REG()
151 return temp; in DS1621_TEMP_TO_REG()
214 for (i = 0; i < ARRAY_SIZE(data->temp); i++) in ds1621_update_client()
215 data->temp[i] = i2c_smbus_read_word_swapped(client, in ds1621_update_client()
220 if (data->temp[0] > data->temp[1]) /* input > min */ in ds1621_update_client()
222 if (data->temp[0] < data->temp[2]) /* input < max */ in ds1621_update_client()
243 DS1621_TEMP_FROM_REG(data->temp[attr->index])); in show_temp()
259 data->temp[attr->index] = DS1621_TEMP_TO_REG(val, data->zbits); in set_temp()
261 data->temp[attr->index]); in set_temp()