glibc/sysdeps/unix/sysv/linux/x86
Adhemerval Zanella 7cbeabac0f x86: Remove vsyscall usage
This patch removes the vsyscall usage for x86_64 port.  As indicated
by kernel code comments [1], vsyscalls are a legacy ABI and its concept
is problematic:

- It interferes with ASLR.
- It's awkward to write code that lives in kernel addresses but is
  callable by userspace at fixed addresses.
- The whole concept is impossible for 32-bit compat userspace.
- UML cannot easily virtualize a vsyscall.

The VDSO is a better approach for such functionality.  Tested on i686,
x86_64, and x32.

	* sysdeps/unix/sysv/linux/i386/gettimeofday.c
	(__gettimeofday_syscall): Remove vsyscall fallback.
	* sysdeps/unix/sysv/linux/i386/time.c (__time_syscall): Likewise.
	* sysdeps/unix/sysv/linux/x86/gettimeofday.c (__gettimeofday_syscall):
	Add syscall fallback function.
	(gettimeofday_ifunc): Use __gettimeofday_syscall as fallback mechanism
	if vDSO is not present.
	* sysdeps/unix/sysv/linux/x86/time.c (__time_syscall): Add syscall
	fallback function.
	(time_ifunc): Use __time_syscall as fallback mechanism if vDSO is not
	present.
	* sysdeps/unix/sysv/linux/x86_64/gettimeofday.c: Remove file.
	* sysdeps/unix/sysv/linux/x86_64/time.c: Likewise.

[1] arch/x86/kernel/vsyscall_64.c
2015-06-09 18:10:19 -03:00
..
bits Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
sys Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
elision-conf.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
elision-conf.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
elision-lock.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
elision-timed.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
elision-trylock.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
elision-unlock.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
force-elision.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
gettimeofday.c x86: Remove vsyscall usage 2015-06-09 18:10:19 -03:00
hle.h Move remaining files out of nptl/sysdeps/unix/sysv/linux/x86/. 2014-05-14 15:32:18 -07:00
init-arch.c Move remaining files out of nptl/sysdeps/unix/sysv/linux/x86/. 2014-05-14 15:32:18 -07:00
init-arch.h Move remaining files out of nptl/sysdeps/unix/sysv/linux/x86/. 2014-05-14 15:32:18 -07:00
libc-vdso.h Consolidate sched_getcpu 2015-06-09 14:56:21 -03:00
Makefile Add x86 32 bit vDSO time function support 2015-01-12 16:03:58 -02:00
pthread_mutex_cond_lock.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
pthread_mutex_lock.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
pthread_mutex_timedlock.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
pthread_mutex_trylock.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
time.c x86: Remove vsyscall usage 2015-06-09 18:10:19 -03:00