diff options
author | Ulrich Drepper <drepper@gmail.com> | 2011-09-06 21:34:11 -0400 |
---|---|---|
committer | Ulrich Drepper <drepper@gmail.com> | 2011-09-06 21:34:11 -0400 |
commit | a77d3c17dc6517636c1cf6ab9c6bb8c257772354 (patch) | |
tree | c23fdba4a9a5bc7bf7e1914b18f965e8909ed2e5 /sysdeps/unix/sysv/linux/x86_64 | |
parent | d53a73acdbf6ac6eb99cd06f5dd695da58d9e8f5 (diff) | |
download | glibc-a77d3c17dc6517636c1cf6ab9c6bb8c257772354.tar.gz glibc-a77d3c17dc6517636c1cf6ab9c6bb8c257772354.tar.xz glibc-a77d3c17dc6517636c1cf6ab9c6bb8c257772354.zip |
Don't unconditionally use clock_gettime vsyscall on x86-64
Diffstat (limited to 'sysdeps/unix/sysv/linux/x86_64')
-rw-r--r-- | sysdeps/unix/sysv/linux/x86_64/clock_gettime.c | 10 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/x86_64/sysdep.h | 9 |
2 files changed, 13 insertions, 6 deletions
diff --git a/sysdeps/unix/sysv/linux/x86_64/clock_gettime.c b/sysdeps/unix/sysv/linux/x86_64/clock_gettime.c new file mode 100644 index 0000000000..9d6cd238de --- /dev/null +++ b/sysdeps/unix/sysv/linux/x86_64/clock_gettime.c @@ -0,0 +1,10 @@ +#include "bits/libc-vdso.h" + +#ifdef SHARED +# define SYSCALL_GETTIME(id, tp) \ + (*__vdso_clock_gettime) (id, tp) +# define INTERNAL_GETTIME(id, tp) \ + (*__vdso_clock_gettime) (id, tp) +#endif + +#include "../clock_gettime.c" diff --git a/sysdeps/unix/sysv/linux/x86_64/sysdep.h b/sysdeps/unix/sysv/linux/x86_64/sysdep.h index 2b9ea85d8e..a9821dc0a8 100644 --- a/sysdeps/unix/sysv/linux/x86_64/sysdep.h +++ b/sysdeps/unix/sysv/linux/x86_64/sysdep.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2001-2005, 2007 Free Software Foundation, Inc. +/* Copyright (C) 2001-2005, 2007, 2011 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -279,8 +279,8 @@ if (INTERNAL_SYSCALL_ERROR_P (sc_ret, sc_err)) \ { \ iserr: \ - __set_errno (INTERNAL_SYSCALL_ERRNO (sc_ret, sc_err)); \ - sc_ret = -1L; \ + __set_errno (INTERNAL_SYSCALL_ERRNO (sc_ret, sc_err)); \ + sc_ret = -1L; \ } \ out: \ sc_ret; \ @@ -304,9 +304,6 @@ v_ret; \ }) -/* List of system calls which are supported as vsyscalls. */ -# define HAVE_CLOCK_GETTIME_VSYSCALL 1 - # else # define INLINE_VSYSCALL(name, nr, args...) \ INLINE_SYSCALL (name, nr, ##args) |