glibc/sysdeps/posix
Zack Weinberg 40a36935ff Use clock_gettime to implement timespec_get.
timespec_get is the same function as clock_gettime, with an obnoxious
coating of NIH painted on it by the ISO C committee.  In addition to
the rename, it takes its arguments in a different order, it returns 0
on *failure* or a positive number on *success*, and it requires that
all of its TIME_* constants be positive.  This last means we cannot
directly reuse the existing CLOCK_* constants for it, because
those have been allocated starting with CLOCK_REALTIME = 0 on all
existing platforms.

This patch simply promotes the sysdeps/posix implementation to
universal, and removes the Linux-specific implementation, whose
apparent reason for existing was to cut out one function call's worth
of overhead.

Checked on x86_64-linux-gnu, i686-linux-gnu, powerpc64le-linux-gnu,
powerpc64-linux-gnu, powerpc-linux-gnu, and aarch64-linux-gnu.

Reviewed-by: Lukasz Majewski <lukma@denx.de>
2019-10-30 17:11:10 -03:00
..
alarm.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
clock_getres.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
clock.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
closedir.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
ctermid.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
cuserid.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
dirfd.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
dirstream.h Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
dl-fileid.h Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
dup2.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
dup.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
euidaccess.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fdopendir.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
flock.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fpathconf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
gai_strerror-strs.h * sysdeps/posix/gai_strerror.c: Complete rewrite. Avoid relocations. 2005-12-20 17:53:00 +00:00
gai_strerror.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
getaddrinfo.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
getcwd.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
getdtsz.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
gethostname.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
getpagesize.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
gettimeofday.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
isatty.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
isfdtype.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
killpg.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
libc_fatal.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
Makefile NPTL: Refactor named semaphore code to use shm-directory.h 2014-12-12 15:01:30 -08:00
mkfifo.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
mkfifoat.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
nice.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
open64.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
opendir.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pathconf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pause.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
posix_fallocate64.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
posix_fallocate.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pread64.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pread.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
preadv2.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
preadv64.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
preadv64v2.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
preadv_common.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
preadv.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
profil.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pwrite64.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pwrite.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pwritev2.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pwritev64.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pwritev64v2.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pwritev_common.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
pwritev.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
raise.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
readdir_r.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
readdir.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
readv.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
remove.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
rename.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
rewinddir.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
seekdir.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
shm_open.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
shm_unlink.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
shm-directory.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
shm-directory.h Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sigblock.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sigignore.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sigintr.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
signal.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sigpause.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sigset.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sigsetmask.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sigsuspend.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sigwait.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sleep.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
spawni.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sprofil.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
Subdirs Make sysdeps/posix bring in login subdir. 2015-07-23 17:04:22 -07:00
sysconf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
system.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
sysv_signal.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
telldir.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
tempname.c Change most internal uses of __gettimeofday to __clock_gettime. 2019-10-30 17:04:10 -03:00
truncate.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
ttyname_r.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
ttyname.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
ulimit.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
usleep.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
utime.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
utimes.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
wait3.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
wait.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
waitid.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
writev.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00