Home
last modified time | relevance | path

Searched refs:tv_sec (Results 1 – 25 of 58) sorted by relevance

123

/tools/testing/selftests/timers/
Dleap-a-day.c73 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 …]
Dinconsistency-check.c94 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()
Dnanosleep.c93 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()
Dalarmtimer-suspend.c100 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()
Dvalid-adjtimex.c215 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()
Dleapcrash.c91 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()
Dset-timer-lat.c99 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()
Dnsleep-lat.c95 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()
Dposix_timers.c68 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()
Dmqueue-lat.c53 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()
Dthreadtest.c64 if ((b->tv_sec <= a->tv_sec) && in checklist()
78 printf("%lu:%lu\n", list[j].tv_sec, list[j].tv_nsec); in checklist()
Draw_skew.c60 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/
Dtimestamping.c149 (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 …]
Dtxtimestamp.c83 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/
Dmq_perf_tests.c353 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/
Dgettimeofday.c23 …printf("time = %.6f\n", tv_end.tv_sec - tv_start.tv_sec + (tv_end.tv_usec - tv_start.tv_usec) * 1e… in test_gettimeofday()
Dmmap_bench.c33 …printf("time = %.6f\n", ts_end.tv_sec - ts_start.tv_sec + (ts_end.tv_nsec - ts_start.tv_nsec) / 1e… in test_mmap()
Dfutex_bench.c34 …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/
Dtestptp.c307 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/
Dcpupower-monitor.c57 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/
Dsched-pipe.c157 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/
Dsetup.c66 timeout.tv_sec = delay_secs; in ui__getch()
87 timeout.tv_sec = 0; in ui__getch()
/tools/testing/selftests/vDSO/
Dvdso_test.c46 (long long)tv.tv_sec, (long long)tv.tv_usec); in main()
/tools/testing/selftests/vm/
Dtranshuge-stress.c137 s = b.tv_sec - a.tv_sec + (b.tv_nsec - a.tv_nsec) / 1000000000.; in main()
/tools/testing/selftests/futex/functional/
Dfutex_wait_wouldblock.c44 struct timespec to = {.tv_sec = 0, .tv_nsec = timeout_ns}; in main()

123