Lines Matching refs:ts

144 		struct timespec64 ts;  in SYSCALL_DEFINE2()  local
146 ktime_get_real_ts64(&ts); in SYSCALL_DEFINE2()
147 if (put_user(ts.tv_sec, &tv->tv_sec) || in SYSCALL_DEFINE2()
148 put_user(ts.tv_nsec / 1000, &tv->tv_usec)) in SYSCALL_DEFINE2()
228 struct timespec64 ts; in COMPAT_SYSCALL_DEFINE2() local
230 ktime_get_real_ts64(&ts); in COMPAT_SYSCALL_DEFINE2()
231 if (put_user(ts.tv_sec, &tv->tv_sec) || in COMPAT_SYSCALL_DEFINE2()
232 put_user(ts.tv_nsec / 1000, &tv->tv_usec)) in COMPAT_SYSCALL_DEFINE2()
472 struct timespec64 ts = ns_to_timespec64(nsec); in ns_to_kernel_old_timeval() local
475 tv.tv_sec = ts.tv_sec; in ns_to_kernel_old_timeval()
476 tv.tv_usec = (suseconds_t)ts.tv_nsec / 1000; in ns_to_kernel_old_timeval()
495 void set_normalized_timespec64(struct timespec64 *ts, time64_t sec, s64 nsec) in set_normalized_timespec64() argument
512 ts->tv_sec = sec; in set_normalized_timespec64()
513 ts->tv_nsec = nsec; in set_normalized_timespec64()
525 struct timespec64 ts = { 0, 0 }; in ns_to_timespec64() local
529 ts.tv_sec = div_u64_rem(nsec, NSEC_PER_SEC, &rem); in ns_to_timespec64()
530 ts.tv_nsec = rem; in ns_to_timespec64()
537 ts.tv_sec = -div_u64_rem(-nsec - 1, NSEC_PER_SEC, &rem) - 1; in ns_to_timespec64()
538 ts.tv_nsec = NSEC_PER_SEC - rem - 1; in ns_to_timespec64()
541 return ts; in ns_to_timespec64()
871 int get_timespec64(struct timespec64 *ts, in get_timespec64() argument
881 ts->tv_sec = kts.tv_sec; in get_timespec64()
888 ts->tv_nsec = kts.tv_nsec; in get_timespec64()
902 int put_timespec64(const struct timespec64 *ts, in put_timespec64() argument
906 .tv_sec = ts->tv_sec, in put_timespec64()
907 .tv_nsec = ts->tv_nsec in put_timespec64()
917 struct old_timespec32 ts; in __get_old_timespec32() local
920 ret = copy_from_user(&ts, cts, sizeof(ts)); in __get_old_timespec32()
924 ts64->tv_sec = ts.tv_sec; in __get_old_timespec32()
925 ts64->tv_nsec = ts.tv_nsec; in __get_old_timespec32()
933 struct old_timespec32 ts = { in __put_old_timespec32() local
937 return copy_to_user(cts, &ts, sizeof(ts)) ? -EFAULT : 0; in __put_old_timespec32()
949 int get_old_timespec32(struct timespec64 *ts, const void __user *uts) in get_old_timespec32() argument
952 return copy_from_user(ts, uts, sizeof(*ts)) ? -EFAULT : 0; in get_old_timespec32()
954 return __get_old_timespec32(ts, uts); in get_old_timespec32()
968 int put_old_timespec32(const struct timespec64 *ts, void __user *uts) in put_old_timespec32() argument
971 return copy_to_user(uts, ts, sizeof(*ts)) ? -EFAULT : 0; in put_old_timespec32()
973 return __put_old_timespec32(ts, uts); in put_old_timespec32()