Lines Matching refs:tstamp
61 void timestamp_now(timestamp_t *tstamp) in timestamp_now() argument
63 if (clock_gettime(CLOCK_MONOTONIC_RAW, tstamp)) in timestamp_now()
67 long long timestamp_diff_ms(timestamp_t *tstamp) in timestamp_diff_ms() argument
71 if (tstamp->tv_nsec > now.tv_nsec) { in timestamp_diff_ms()
72 diff.tv_sec = now.tv_sec - tstamp->tv_sec - 1; in timestamp_diff_ms()
73 diff.tv_nsec = (now.tv_nsec + 1000000000L) - tstamp->tv_nsec; in timestamp_diff_ms()
75 diff.tv_sec = now.tv_sec - tstamp->tv_sec; in timestamp_diff_ms()
76 diff.tv_nsec = now.tv_nsec - tstamp->tv_nsec; in timestamp_diff_ms()
302 timestamp_t tstamp; in test_pcm_time() local
473 timestamp_now(&tstamp); in test_pcm_time()
503 ms = timestamp_diff_ms(&tstamp); in test_pcm_time()