Lines Matching defs:counter
117 * until clock counter is programmed.
122 * N: number of reference clock counts for which the counter runs
165 int err, c1, c2, c3, c4, counter;
177 dev_err_once(ts->dev, "ch%u: counter invalid\n", tsc->id);
182 counter = FIELD_GET(TSENSOR_SENSOR0_TS_STATUS1_CURRENT_COUNT, val);
185 * This shouldn't happen with a valid counter status, nevertheless
189 if (counter == 0xffff) {
190 dev_err_once(ts->dev, "ch%u: counter overflow\n", tsc->id);
195 * temperature = a * counter + b
198 c1 = DIV_ROUND_CLOSEST(ts->calib.a * counter + ts->calib.b, 1000000);
258 dev_err_ratelimited(ts->dev, "ch%u: counter overflowed\n", id);
368 /* program LEVEL2 counter threshold */
374 /* program LEVEL3 counter threshold */
382 * breaches and counter overflow condition.
455 /* get calibrated counter values for 25C/90C thresholds */
459 /* and calibrated temperatures corresponding to the counter values */