| /external/libchrome/base/time/ |
| time_posix.cc | 84 int64_t ConvertTimespecToMicros(const struct timespec& ts) { 87 if (sizeof(ts.tv_sec) <= 4 && sizeof(ts.tv_nsec) <= 8) { 88 int64_t result = ts.tv_sec; 90 result += (ts.tv_nsec / base::Time::kNanosecondsPerMicrosecond); 93 base::CheckedNumeric<int64_t> result(ts.tv_sec); 95 result += (ts.tv_nsec / base::Time::kNanosecondsPerMicrosecond); 108 struct timespec ts; local 109 if (clock_gettime(clk_id, &ts) != 0) { 113 return ConvertTimespecToMicros(ts); [all...] |
| /external/libevent/ |
| evport.c | 275 struct timespec ts; local 278 ts.tv_sec = tv->tv_sec; 279 ts.tv_nsec = tv->tv_usec * 1000; 280 ts_p = &ts;
|
| evutil_time.c | 134 struct timespec ts; 135 ts.tv_sec = tv->tv_sec; 136 ts.tv_nsec = tv->tv_usec*1000; 137 nanosleep(&ts, NULL); 272 struct timespec ts; local 283 if (clock_gettime(CLOCK_MONOTONIC_COARSE, &ts) == 0) { 289 if (!fallback && clock_gettime(CLOCK_MONOTONIC, &ts) == 0) { 306 struct timespec ts; local 315 if (clock_gettime(base->monotonic_clock, &ts) == -1) 317 tp->tv_sec = ts.tv_sec [all...] |
| kqueue.c | 259 struct timespec ts, *ts_p = NULL; local 263 ts.tv_sec = tv->tv_sec; 264 ts.tv_nsec = tv->tv_usec * 1000; 265 ts_p = &ts;
|
| /external/libxcam/modules/ocl/ |
| cl_kernel.cpp | 135 struct timeval ts; local 199 gettimeofday (&ts, NULL); 203 cache_filename, XCAM_TIMESTAMP_ARGS (XCAM_TIMEVAL_2_USEC (ts)));
|
| /external/libxcam/xcore/ |
| image_processor.cpp | 31 int64_t ts = buf->get_timestamp(); local 32 XCAM_UNUSED (ts); 36 XCAM_TIMESTAMP_ARGS (ts)); 44 int64_t ts = buf->get_timestamp(); local 45 XCAM_UNUSED (ts); 49 XCAM_TIMESTAMP_ARGS (ts)); 58 int64_t ts = result->get_timestamp(); local 59 XCAM_UNUSED (ts); 65 XCAM_TIMESTAMP_ARGS (ts));
|
| /external/linux-kselftest/tools/testing/selftests/futex/functional/ |
| futex_requeue_pi.c | 288 struct timespec ts, *tsp = NULL; local 297 ret = clock_gettime(CLOCK_MONOTONIC, &ts); 298 secs = (ts.tv_nsec + timeout_ns) / 1000000000; 299 ts.tv_nsec = ((int64_t)ts.tv_nsec + timeout_ns) % 1000000000; 300 ts.tv_sec += secs; 301 info("ts.tv_sec = %ld\n", ts.tv_sec); 302 info("ts.tv_nsec = %ld\n", ts.tv_nsec) [all...] |
| /external/linux-kselftest/tools/testing/selftests/networking/timestamping/ |
| rxtimestamp.c | 173 struct scm_timestamping *ts; local 214 ts = (struct scm_timestamping *)CMSG_DATA(cmsg); 215 actual.swtstamp = !!ts->ts[0].tv_sec; 216 if (ts->ts[1].tv_sec != 0) 217 error(0, 0, "ts[1] should not be set."); 218 actual.hwtstamp = !!ts->ts[2].tv_sec;
|
| timestamping.c | 161 struct timespec ts; local 269 if (ioctl(sock, SIOCGSTAMPNS, &ts)) 273 (long)ts.tv_sec, 274 (long)ts.tv_nsec);
|
| txtimestamp.c | 108 struct timespec ts; local 112 ts.tv_sec = tv.tv_sec; 113 ts.tv_nsec = tv.tv_usec * 1000; 115 __print_timestamp(" USR", &ts, 0, 0); 137 __print_timestamp(tsname, &tss->ts[0], tskey, payload_len);
|
| /external/linux-kselftest/tools/testing/selftests/ptp/ |
| testptp.c | 151 struct timespec ts; local 317 if (clock_gettime(clkid, &ts)) { 321 ts.tv_sec, ts.tv_nsec, ctime(&ts.tv_sec)); 326 clock_gettime(CLOCK_REALTIME, &ts); 327 if (clock_settime(clkid, &ts)) { 335 clock_gettime(clkid, &ts); 336 if (clock_settime(CLOCK_REALTIME, &ts)) { 344 ts.tv_sec = seconds [all...] |
| /external/linux-kselftest/tools/testing/selftests/timers/ |
| freq-step.c | 213 struct timespec ts; local 216 if (clock_gettime(CLOCK_MONOTONIC_RAW, &ts)) { 221 mono_raw_base = ts.tv_sec; 223 if (clock_gettime(CLOCK_MONOTONIC, &ts)) { 228 mono_base = ts.tv_sec; 241 srand(ts.tv_sec ^ ts.tv_nsec);
|
| set-timer-lat.c | 100 struct timespec ts; local 102 clock_gettime(clock_id, &ts); 105 delta_ns = timespec_sub(start_time, ts);
|
| /external/ltp/testcases/kernel/io/aio/aio01/ |
| aio01.c | 104 static struct timespec ts; local 131 ts.tv_sec = 30; 132 ts.tv_nsec = 0; 142 while (io_getevents(io_ctx, 1, 1, &event, &ts) != 1) ; 162 ts.tv_sec = 30; 163 ts.tv_nsec = 0; 173 while (io_getevents(io_ctx, 1, 1, &event, &ts) != 1) ; 193 ts.tv_sec = 30; 194 ts.tv_nsec = 0; 204 while (io_getevents(io_ctx, 1, 1, &event, &ts) != 1) [all...] |
| /external/ltp/testcases/kernel/syscalls/ppoll/ |
| ppoll01.c | 50 struct timespec *ts; /* ts ppoll parameter */ member in struct:test_case 101 .ts = &ts_long, 110 .ts = &ts_short, 120 .ts = &ts_short, 129 .ts = &ts_long, 137 .ts = &ts_long, 149 .ts = &ts_long, 159 .ts = &ts_long, 167 .ts = &ts_long 214 struct timespec ts, *tsp = NULL; local [all...] |
| /external/ltp/testcases/kernel/syscalls/sigwaitinfo/ |
| sigwaitinfo01.c | 158 struct timespec ts = {.tv_sec = 1 }; local 165 TEST(sigwaitinfo(&sigs, &si, &ts));
|
| /external/ltp/testcases/open_posix_testsuite/conformance/interfaces/pthread_cond_broadcast/ |
| 2-3.c | 170 struct timespec ts; local 182 ret = clock_gettime(td->cid, &ts); 185 ts.tv_sec += TIMEOUT; 191 ret = pthread_cond_timedwait(&td->cnd, &td->mtx, &ts);
|
| /external/ltp/testcases/open_posix_testsuite/conformance/interfaces/pthread_cond_destroy/ |
| 2-1.c | 221 struct timespec ts; local 237 ret = clock_gettime(td->cid, &ts); 241 ts.tv_sec += TIMEOUT; 247 ret = pthread_cond_timedwait(&td->cnd, &td->mtx1, &ts); 284 ret = clock_gettime(td->cid, &ts); 288 ts.tv_sec += TIMEOUT; 294 ret = pthread_cond_timedwait(&td->cnd, &td->mtx2, &ts);
|
| /external/ltp/testcases/open_posix_testsuite/conformance/interfaces/pthread_cond_signal/ |
| 1-2.c | 218 struct timespec ts; local 234 ret = clock_gettime(td->cid, &ts); 238 ts.tv_sec += TIMEOUT; 244 ret = pthread_cond_timedwait(&td->cnd, &td->mtx, &ts);
|
| /external/ltp/testcases/open_posix_testsuite/conformance/interfaces/pthread_cond_timedwait/ |
| 2-4.c | 162 struct timespec ts; local 177 ret = clock_gettime(td->cid, &ts); 183 ts.tv_sec += 10; 185 output("[child] Will timeout at %i.%09i\n", ts.tv_sec, ts.tv_nsec); 190 ret = pthread_cond_timedwait(&(td->cnd), &(td->mtx), &ts);
|
| 2-7.c | 164 struct timespec ts; local 179 ret = clock_gettime(td->cid, &ts); 186 ts.tv_nsec += TIMEOUT * 1000; 187 if (ts.tv_nsec >= 1000000000) { 188 ts.tv_sec++; 189 ts.tv_nsec -= 1000000000; 192 output("[child] Will timeout at %i.%09i\n", ts.tv_sec, ts.tv_nsec); 197 ret = pthread_cond_timedwait(&(td->cnd), &(td->mtx), &ts);
|
| 4-2.c | 207 struct timespec ts, ts_junk; local 489 ret = clock_gettime(cid, &ts); 498 (junks_ts[j].sec_is_offset ? ts.tv_sec : 0); 501 (junks_ts[j].nsec_is_offset ? ts.tv_nsec : 0); 504 output("TS: s = %s%li ; ns = %s%li\n", 509 output("Now is: %i.%09li\n", ts.tv_sec, ts.tv_nsec);
|
| /external/ltp/testcases/open_posix_testsuite/functional/threads/pi_test/ |
| pitest-1.c | 97 struct timespec ts; local 114 ts.tv_sec = 0; 115 ts.tv_nsec = tp->sleep_ms * 1000 * 1000; 120 rc = nanosleep(&ts, NULL); 168 struct timespec ts; local 181 ts.tv_sec = 0; 182 ts.tv_nsec = period * 1000 * 1000; 191 rc = nanosleep(&ts, NULL);
|
| pitest-2.c | 99 struct timespec ts; local 116 ts.tv_sec = 0; 117 ts.tv_nsec = tp->sleep_ms * 1000 * 1000; 122 rc = nanosleep(&ts, NULL); 168 struct timespec ts; local 181 ts.tv_sec = 0; 182 ts.tv_nsec = period * 1000 * 1000; 191 rc = nanosleep(&ts, NULL);
|
| pitest-3.c | 100 struct timespec ts; local 119 ts.tv_sec = 0; 120 ts.tv_nsec = tp->sleep_ms * 1000 * 1000; 125 rc = nanosleep(&ts, NULL); 176 struct timespec ts; local 192 ts.tv_sec = 0; 193 ts.tv_nsec = period * 1000 * 1000; 202 rc = nanosleep(&ts, NULL);
|