/third_party/mesa3d/src/util/tests/ |
H A D | timespec_test.cpp | 38 a.tv_nsec = NSEC_PER_SEC - 1; in TEST() 56 EXPECT_EQ(r.tv_nsec, NSEC_PER_SEC - 1); in TEST() 65 EXPECT_EQ(timespec_to_nsec(&a), (NSEC_PER_SEC * 4ULL) + 4); in TEST() 101 a.tv_nsec = NSEC_PER_SEC - 1; in TEST() 105 EXPECT_EQ(NSEC_PER_SEC - 1, tv_nsec); in TEST() 137 a.tv_nsec = NSEC_PER_SEC - 1; in TEST() 146 EXPECT_FALSE(timespec_add_nsec(&r, &a, (NSEC_PER_SEC * 2ULL))); in TEST() 148 EXPECT_EQ(NSEC_PER_SEC - 1, r.tv_nsec); in TEST() 150 EXPECT_FALSE(timespec_add_nsec(&r, &a, (NSEC_PER_SEC * 2ULL) + 2)); in TEST() 156 EXPECT_FALSE(timespec_add_nsec(&r, &r, NSEC_PER_SEC in TEST() [all...] |
/third_party/mesa3d/src/util/ |
H A D | timespec.h | 42 #define NSEC_PER_SEC 1000000000 macro 57 if (r->tv_nsec > NSEC_PER_SEC) { in timespec_add() 59 r->tv_nsec -= NSEC_PER_SEC; in timespec_add() 78 r->tv_nsec += NSEC_PER_SEC; in timespec_sub() 97 uint64_t b_sec = b / NSEC_PER_SEC; in timespec_add_nsec() 98 long b_nsec = b % NSEC_PER_SEC; in timespec_add_nsec() 105 if (r->tv_nsec >= NSEC_PER_SEC) { in timespec_add_nsec() 109 r->tv_nsec -= NSEC_PER_SEC; in timespec_add_nsec() 113 r->tv_nsec += NSEC_PER_SEC; in timespec_add_nsec() 142 return (uint64_t)a->tv_sec * NSEC_PER_SEC in timespec_to_nsec() [all...] |
/third_party/mesa3d/src/freedreno/drm/msm/ |
H A D | msm_priv.h | 116 ns = 3600ULL * NSEC_PER_SEC; /* 1 hour timeout is almost infinite */ in get_abs_timeout() 119 tv->tv_sec = t.tv_sec + ns / NSEC_PER_SEC; in get_abs_timeout() 120 tv->tv_nsec = t.tv_nsec + ns % NSEC_PER_SEC; in get_abs_timeout() 121 if (tv->tv_nsec >= NSEC_PER_SEC) { /* handle nsec overflow */ in get_abs_timeout() 122 tv->tv_nsec -= NSEC_PER_SEC; in get_abs_timeout()
|
/third_party/mesa3d/src/vulkan/wsi/ |
H A D | wsi_common_queue.h | 103 #define NSEC_PER_SEC 1000000000 macro 117 uint32_t abs_nsec = now.tv_nsec + timeout % NSEC_PER_SEC; in wsi_queue_pull() 118 uint64_t abs_sec = now.tv_sec + (abs_nsec / NSEC_PER_SEC) + in wsi_queue_pull() 119 (timeout / NSEC_PER_SEC); in wsi_queue_pull() 120 abs_nsec %= NSEC_PER_SEC; in wsi_queue_pull()
|
/third_party/eudev/src/shared/ |
H A D | time-util.h | 42 #define NSEC_PER_SEC ((nsec_t) 1000000000ULL) macro 47 #define NSEC_PER_MINUTE ((nsec_t) (60ULL*NSEC_PER_SEC)) 55 #define NSEC_PER_MONTH ((nsec_t) (2629800ULL*NSEC_PER_SEC)) 57 #define NSEC_PER_YEAR ((nsec_t) (31557600ULL*NSEC_PER_SEC))
|
/third_party/musl/libc-test/src/functionalext/common/ |
H A D | pthread_util.h | 39 #define NSEC_PER_SEC 1000000000 macro 66 const unsigned int nsecPerSec = NSEC_PER_SEC; in GetDelayedTimeByClockid() 77 const unsigned int nsecPerSec = NSEC_PER_SEC; in GetTimeDiff()
|
/third_party/mesa3d/src/etnaviv/drm/ |
H A D | etnaviv_priv.h | 215 tv->tv_sec = t.tv_sec + ns / NSEC_PER_SEC; in get_abs_timeout() 216 tv->tv_nsec = t.tv_nsec + ns % NSEC_PER_SEC; in get_abs_timeout() 217 if (tv->tv_nsec >= NSEC_PER_SEC) { in get_abs_timeout() 218 tv->tv_nsec -= NSEC_PER_SEC; in get_abs_timeout()
|
/third_party/FreeBSD/sys/sys/ |
H A D | callout.h | 56 #ifndef NSEC_PER_SEC 57 #define NSEC_PER_SEC 1000000000L macro
|
/third_party/ltp/include/lapi/ |
H A D | common_timers.h | 14 #ifndef NSEC_PER_SEC 15 #define NSEC_PER_SEC (1000000000LL) macro
|
/third_party/ltp/testcases/realtime/func/sched_jitter/ |
H A D | sched_jitter.c | 55 #define NSEC_PER_SEC 1000000000 macro 88 first = (unsigned long long)a.tv_sec * NSEC_PER_SEC + a.tv_nsec; in ts_sub() 89 second = (unsigned long long)b.tv_sec * NSEC_PER_SEC + b.tv_nsec; in ts_sub()
|
/third_party/ltp/testcases/kernel/syscalls/clock_gettime/ |
H A D | leapsec01.c | 124 const struct timespec sleeptime = { 0, NSEC_PER_SEC / 2 }; in run_leapsec() 168 start.tv_sec += start.tv_nsec / NSEC_PER_SEC; in run_leapsec() 169 start.tv_nsec = start.tv_nsec % NSEC_PER_SEC; in run_leapsec()
|
/third_party/musl/libc-test/src/functionalext/thread/ |
H A D | pthread_cond_timedwait.c | 92 ts.tv_nsec = NSEC_PER_SEC; in pthread_cond_timedwait_0020() 244 const unsigned int nsecPerSec = NSEC_PER_SEC; in ClockWaitTimedwait2() 322 const unsigned int nsecPerSec = NSEC_PER_SEC; in ClockWaitTimedwait4() 391 const unsigned int nsecPerSec = NSEC_PER_SEC; in ClockWaitTimeMismatch() 418 const unsigned int nsecPerSec = NSEC_PER_SEC; in ClockWaitTimeMismatch2() 546 const unsigned int nsecPerSec = NSEC_PER_SEC; in PthreadCondMonotonicTimeWait2() 615 const long einvalNsec = NSEC_PER_SEC; in PthreadCondMonotonicTimeEinval()
|
/third_party/mesa3d/src/intel/vulkan/ |
H A D | anv_bo_sync.c | 179 .tv_sec = abs_timeout_ns / NSEC_PER_SEC, in anv_bo_sync_wait() 180 .tv_nsec = abs_timeout_ns % NSEC_PER_SEC, in anv_bo_sync_wait()
|
H A D | genX_query.c | 424 uint64_t abs_timeout_ns = os_time_get_absolute_timeout(2 * NSEC_PER_SEC); in wait_for_available()
|
/third_party/ltp/testcases/kernel/syscalls/epoll_pwait/ |
H A D | epoll_pwait05.c | 30 {{.tv_nsec = NSEC_PER_SEC}, EINVAL, "ts.tv_nsec >= NSEC_PER_SEC"},
|
/third_party/ltp/testcases/kernel/syscalls/futex/ |
H A D | futex_wake04.c | 55 to = tst_ts_from_ns(tv->tstype, 30 * NSEC_PER_SEC); in setup()
|
/third_party/ltp/testcases/kernel/syscalls/clock_settime/ |
H A D | clock_settime02.c | 55 .tv_nsec = NSEC_PER_SEC + 1,
|
/third_party/ltp/testcases/kernel/syscalls/timer_settime/ |
H A D | timer_settime02.c | 17 * than NSEC_PER_SEC -> EINVAL 56 {&timer, &pnew_set, &pold_set, NSEC_PER_SEC + 1, EINVAL},
|
/third_party/alsa-utils/amidi/ |
H A D | amidi.c | 43 #define NSEC_PER_SEC 1000000000L macro 673 itimerspec.it_value.tv_nsec = modff(timeout, &timeout_int) * NSEC_PER_SEC; in main()
|
/third_party/mesa3d/src/gallium/drivers/iris/ |
H A D | iris_fence.c | 357 #define NSEC_PER_SEC (1000 * USEC_PER_SEC) macro 366 return (uint64_t)current.tv_sec * NSEC_PER_SEC + current.tv_nsec; in gettime_ns()
|
/third_party/mesa3d/src/gallium/drivers/crocus/ |
H A D | crocus_fence.c | 292 #define NSEC_PER_SEC (1000 * USEC_PER_SEC) macro 301 return (uint64_t)current.tv_sec * NSEC_PER_SEC + current.tv_nsec; in gettime_ns()
|
/third_party/wpa_supplicant/wpa_supplicant-2.9/src/utils/ |
H A D | os_unix.c | 120 t->sec = nano / NSEC_PER_SEC; in os_get_reltime() 121 t->usec = (nano - (((uint64_t) t->sec) * NSEC_PER_SEC)) / NSEC_PER_USEC; in os_get_reltime()
|
/third_party/wpa_supplicant/wpa_supplicant-2.9_standard/src/utils/ |
H A D | os_unix.c | 126 t->sec = nano / NSEC_PER_SEC; in os_get_reltime() 127 t->usec = (nano - (((uint64_t) t->sec) * NSEC_PER_SEC)) / NSEC_PER_USEC; in os_get_reltime()
|
/third_party/mesa3d/src/freedreno/vulkan/ |
H A D | tu_drm.c | 586 .tv_sec = abs_timeout_ns / NSEC_PER_SEC, in tu_timeline_sync_wait() 587 .tv_nsec = abs_timeout_ns % NSEC_PER_SEC, in tu_timeline_sync_wait()
|
H A D | tu_query.c | 22 #define NSEC_PER_SEC 1000000000ull macro 445 WAIT_TIMEOUT * NSEC_PER_SEC); in wait_for_available()
|