Lines Matching refs:temp
94 static int max17042_get_temperature(struct max17042_chip *chip, int *temp)
104 *temp = sign_extend32(data, 15);
107 *temp = *temp * 10 / 256;
176 int temp, vavg, vbatt, ret;
207 ret = max17042_get_temperature(chip, &temp);
211 if (temp < chip->pdata->temp_min) {
216 if (temp > chip->pdata->temp_max) {
447 int8_t temp;
456 temp = val->intval / 10;
458 if (temp >= (int8_t)(data >> 8))
459 temp = (int8_t)(data >> 8) - 1;
461 data = (data & 0xff00) + temp;
470 temp = val->intval / 10;
472 if (temp <= (int8_t)(data & 0xff))
473 temp = (int8_t)(data & 0xff) + 1;
475 data = (data & 0xff) + (temp << 8);
925 if (of_property_read_s32(np, "maxim,cold-temp", &pdata->temp_min))
927 if (of_property_read_s32(np, "maxim,over-heat-temp", &pdata->temp_max))