/tools/testing/selftests/timers/ |
D | leap-a-day.c | 73 if (a.tv_sec < b.tv_sec) in in_order() 75 if (a.tv_sec > b.tv_sec) in in_order() 87 ts.tv_sec++; in timespec_add() 149 if (tx.time.tv_sec < next_leap) { in sigalarm() 153 tx.time.tv_sec, in sigalarm() 162 tx.time.tv_sec, in sigalarm() 256 next_leap = ts.tv_sec; in main() 262 tv.tv_sec = next_leap - 10; in main() 265 printf("Setting time to %s", ctime(&tv.tv_sec)); in main() 310 its1.it_value.tv_sec = next_leap; in main() [all …]
|
D | inconsistency-check.c | 94 if ((unsigned long)a.tv_sec < (unsigned long)b.tv_sec) in in_order() 96 if ((unsigned long)a.tv_sec > (unsigned long)b.tv_sec) in in_order() 114 now = then = list[0].tv_sec; in consistency_test() 140 printf("%lu:%lu\n", list[i].tv_sec, in consistency_test() 145 delta = list[inconsistent].tv_sec * NSEC_PER_SEC; in consistency_test() 147 delta -= list[inconsistent+1].tv_sec * NSEC_PER_SEC; in consistency_test() 157 now = list[0].tv_sec; in consistency_test()
|
D | nanosleep.c | 93 if (a.tv_sec < b.tv_sec) in in_order() 95 if (a.tv_sec > b.tv_sec) in in_order() 107 ts.tv_sec++; in timespec_add() 130 rel.tv_sec = 0; in nanosleep_test()
|
D | alarmtimer-suspend.c | 100 long long ret = NSEC_PER_SEC * b.tv_sec + b.tv_nsec; in timespec_sub() 102 ret -= NSEC_PER_SEC * a.tv_sec + a.tv_nsec; in timespec_sub() 119 printf("ALARM(%i): %ld:%ld latency: %lld ns ", alarmcount, ts.tv_sec, in sigalarm() 163 start_time.tv_sec, start_time.tv_nsec); in main() 166 its1.it_value.tv_sec += SUSPEND_SECS; in main() 167 its1.it_interval.tv_sec = SUSPEND_SECS; in main()
|
D | valid-adjtimex.c | 215 tmx.time.tv_sec = offset / NSEC_PER_SEC; in set_offset() 219 tmx.time.tv_sec -= 1; in set_offset() 223 tmx.time.tv_sec = offset / USEC_PER_SEC; in set_offset() 227 tmx.time.tv_sec -= 1; in set_offset() 234 printf("(sec: %ld usec: %ld) ", tmx.time.tv_sec, tmx.time.tv_usec); in set_offset() 250 tmx.time.tv_sec = sec; in set_bad_offset() 254 printf("Invalid (sec: %ld usec: %ld) did not fail! ", tmx.time.tv_sec, tmx.time.tv_usec); in set_bad_offset()
|
D | leapcrash.c | 91 next_leap = ts.tv_sec; in main() 99 tv.tv_sec = next_leap - 2; in main() 109 while (tx.time.tv_sec < next_leap + 1) { in main()
|
D | set-timer-lat.c | 99 long long ret = NSEC_PER_SEC * b.tv_sec + b.tv_nsec; in timespec_sub() 101 ret -= NSEC_PER_SEC * a.tv_sec + a.tv_nsec; in timespec_sub() 156 its1.it_value.tv_sec += TIMER_SECS; in do_timer() 158 its1.it_value.tv_sec = TIMER_SECS; in do_timer() 161 its1.it_interval.tv_sec = TIMER_SECS; in do_timer()
|
D | nsleep-lat.c | 95 ts.tv_sec++; in timespec_add() 103 long long ret = NSEC_PER_SEC * b.tv_sec + b.tv_nsec; in timespec_sub() 105 ret -= NSEC_PER_SEC * a.tv_sec + a.tv_nsec; in timespec_sub() 115 target.tv_sec = ns/NSEC_PER_SEC; in nanosleep_lat_test()
|
D | posix_timers.c | 68 diff += (end.tv_sec - start.tv_sec) * USECS_PER_SEC; in check_diff() 83 .it_value.tv_sec = DELAY, in check_itimer() 145 .it_value.tv_sec = DELAY, in check_timer_create()
|
D | mqueue-lat.c | 53 long long ret = NSEC_PER_SEC * b.tv_sec + b.tv_nsec; in timespec_sub() 55 ret -= NSEC_PER_SEC * a.tv_sec + a.tv_nsec; in timespec_sub() 64 ts.tv_sec++; in timespec_add()
|
D | threadtest.c | 64 if ((b->tv_sec <= a->tv_sec) && in checklist() 78 printf("%lu:%lu\n", list[j].tv_sec, list[j].tv_nsec); in checklist()
|
D | raw_skew.c | 60 return ts.tv_sec * NSEC_PER_SEC + ts.tv_nsec; in ts_to_nsec() 67 ts.tv_sec = ns/NSEC_PER_SEC; in nsec_to_ts()
|
/tools/testing/selftests/networking/timestamping/ |
D | timestamping.c | 149 (long)now.tv_sec, (long)now.tv_usec, in sendpacket() 167 (long)now.tv_sec, (long)now.tv_usec, in printpacket() 184 (long)stamp->tv_sec, in printpacket() 192 (long)stamp->tv_sec, in printpacket() 201 (long)stamp->tv_sec, in printpacket() 207 (long)stamp->tv_sec, in printpacket() 265 (long)tv.tv_sec, in printpacket() 273 (long)ts.tv_sec, in printpacket() 475 next.tv_sec = (next.tv_sec + 1) / 5 * 5; in main() 485 delta_us = (long)(next.tv_sec - now.tv_sec) * 1000000 + in main() [all …]
|
D | txtimestamp.c | 83 if (!(cur->tv_sec | cur->tv_nsec)) in __print_timestamp() 87 name, cur->tv_sec, cur->tv_nsec / 1000, in __print_timestamp() 90 if ((ts_prev.tv_sec | ts_prev.tv_nsec)) { in __print_timestamp() 93 cur_ms = (long) cur->tv_sec * 1000 * 1000; in __print_timestamp() 96 prev_ms = (long) ts_prev.tv_sec * 1000 * 1000; in __print_timestamp() 112 ts.tv_sec = tv.tv_sec; in print_timestamp_usr()
|
/tools/testing/selftests/mqueue/ |
D | mq_perf_tests.c | 353 nsec = ((middle.tv_sec - start.tv_sec) * 1000000000) + \ 357 send_total.tv_sec++; \ 360 nsec = ((end.tv_sec - middle.tv_sec) * 1000000000) + \ 364 recv_total.tv_sec++; \ 452 send_total.tv_sec = 0; in perf_test_thread() 454 recv_total.tv_sec = 0; in perf_test_thread() 459 send_total.tv_sec, send_total.tv_nsec); in perf_test_thread() 460 nsec = ((unsigned long long)send_total.tv_sec * 1000000000 + in perf_test_thread() 464 recv_total.tv_sec, recv_total.tv_nsec); in perf_test_thread() 465 nsec = ((unsigned long long)recv_total.tv_sec * 1000000000 + in perf_test_thread() [all …]
|
/tools/testing/selftests/powerpc/benchmarks/ |
D | gettimeofday.c | 23 …printf("time = %.6f\n", tv_end.tv_sec - tv_start.tv_sec + (tv_end.tv_usec - tv_start.tv_usec) * 1e… in test_gettimeofday()
|
D | mmap_bench.c | 33 …printf("time = %.6f\n", ts_end.tv_sec - ts_start.tv_sec + (ts_end.tv_nsec - ts_start.tv_nsec) / 1e… in test_mmap()
|
D | futex_bench.c | 34 …printf("time = %.6f\n", ts_end.tv_sec - ts_start.tv_sec + (ts_end.tv_nsec - ts_start.tv_nsec) / 1e… in test_futex()
|
/tools/testing/selftests/ptp/ |
D | testptp.c | 307 tx.time.tv_sec = adjtime; in main() 321 ts.tv_sec, ts.tv_nsec, ctime(&ts.tv_sec)); in main() 344 ts.tv_sec = seconds; in main() 409 timeout.it_value.tv_sec = oneshot; in main() 429 timeout.it_interval.tv_sec = periodic; in main() 430 timeout.it_value.tv_sec = periodic; in main() 448 perout_request.start.sec = ts.tv_sec + 2; in main()
|
/tools/power/cpupower/utils/idle_monitor/ |
D | cpupower-monitor.c | 57 temp.tv_sec = end.tv_sec - start.tv_sec - 1; in timespec_diff_us() 60 temp.tv_sec = end.tv_sec - start.tv_sec; in timespec_diff_us() 63 return (temp.tv_sec * 1000000) + (temp.tv_nsec / 1000); in timespec_diff_us()
|
/tools/perf/bench/ |
D | sched-pipe.c | 157 result_usec = diff.tv_sec * USEC_PER_SEC; in bench_sched_pipe() 161 diff.tv_sec, in bench_sched_pipe() 173 diff.tv_sec, in bench_sched_pipe()
|
/tools/perf/ui/tui/ |
D | setup.c | 66 timeout.tv_sec = delay_secs; in ui__getch() 87 timeout.tv_sec = 0; in ui__getch()
|
/tools/testing/selftests/vDSO/ |
D | vdso_test.c | 46 (long long)tv.tv_sec, (long long)tv.tv_usec); in main()
|
/tools/testing/selftests/vm/ |
D | transhuge-stress.c | 137 s = b.tv_sec - a.tv_sec + (b.tv_nsec - a.tv_nsec) / 1000000000.; in main()
|
/tools/testing/selftests/futex/functional/ |
D | futex_wait_wouldblock.c | 44 struct timespec to = {.tv_sec = 0, .tv_nsec = timeout_ns}; in main()
|