Lines Matching refs:tmp

155 	unsigned int tmp;  in max17055_channel_get()  local
160 tmp = priv->voltage * 1250 / 16; in max17055_channel_get()
161 valp->val1 = tmp / 1000000; in max17055_channel_get()
162 valp->val2 = tmp % 1000000; in max17055_channel_get()
165 tmp = priv->ocv * 1250 / 16; in max17055_channel_get()
166 valp->val1 = tmp / 1000000; in max17055_channel_get()
167 valp->val2 = tmp % 1000000; in max17055_channel_get()
185 tmp = capacity_to_ma(config->rsense_mohms, priv->full_cap); in max17055_channel_get()
186 set_millis(valp, tmp); in max17055_channel_get()
189 tmp = capacity_to_ma(config->rsense_mohms, priv->remaining_cap); in max17055_channel_get()
190 set_millis(valp, tmp); in max17055_channel_get()
198 tmp = priv->time_to_empty * 5625 / 60; in max17055_channel_get()
199 set_millis(valp, tmp); in max17055_channel_get()
208 tmp = priv->time_to_full * 5625 / 60; in max17055_channel_get()
209 set_millis(valp, tmp); in max17055_channel_get()
217 tmp = capacity_to_ma(config->rsense_mohms, priv->design_cap); in max17055_channel_get()
218 set_millis(valp, tmp); in max17055_channel_get()
432 int16_t tmp; in max17055_gauge_init() local
441 if (max17055_reg_read(dev, STATUS, &tmp)) { in max17055_gauge_init()
445 if (!(tmp & STATUS_POR)) { in max17055_gauge_init()
451 tmp = FSTAT_DNR; in max17055_gauge_init()
452 while (tmp & FSTAT_DNR) { in max17055_gauge_init()
453 ret = max17055_reg_read(dev, FSTAT, &tmp); in max17055_gauge_init()
464 if (max17055_reg_read(dev, STATUS, &tmp)) { in max17055_gauge_init()
468 tmp &= ~STATUS_POR; in max17055_gauge_init()
469 return max17055_reg_write(dev, STATUS, tmp); in max17055_gauge_init()