aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/unix/sysv/linux/sysdep-vdso.h
diff options
context:
space:
mode:
authorRafael Ávila de Espíndola <rafael@espindo.la>2018-11-23 15:34:15 -0800
committerH.J. Lu <hjl.tools@gmail.com>2018-11-23 16:50:29 -0800
commit1e8bdc3a2b3e8d6e26efd14d44ae71d21d8366fe (patch)
tree7cf38f1dd13672c72fa85892ab6a3a8a9fbc3bce /sysdeps/unix/sysv/linux/sysdep-vdso.h
parent1283c478aa0a9b3d84320db5745a61b7f61b360c (diff)
downloadglibc-1e8bdc3a2b3e8d6e26efd14d44ae71d21d8366fe.tar
glibc-1e8bdc3a2b3e8d6e26efd14d44ae71d21d8366fe.tar.gz
glibc-1e8bdc3a2b3e8d6e26efd14d44ae71d21d8366fe.tar.bz2
glibc-1e8bdc3a2b3e8d6e26efd14d44ae71d21d8366fe.zip
Enable VDSO on x86_64 statically linked programs [BZ #19767]
All the required code already existed, and some of it was already running. AT_SYSINFO_EHDR is processed if NEED_DL_SYSINFO_DSO is defined, but it looks like it always is. The call to setup_vdso is also unconditional, so all that was left to do was setup the function pointers and use them. This patch just deletes some #ifdef to enable that. [BZ #19767] * nptl/Makefile (tests-static): Add tst-cond11-static. (tests): Likewise. * nptl/tst-cond11-static.c: New File. * sysdeps/unix/sysv/linux/Makefile (tests-static): Add tst-affinity-static. (tests): Likewise. * sysdeps/unix/sysv/linux/sysdep-vdso.h: Check USE_VSYSCALL instead of SHARED. * sysdeps/unix/sysv/linux/sysdep.h (ALWAYS_USE_VSYSCALL): New. (USE_VSYSCALL): Likewise. * sysdeps/unix/sysv/linux/tst-affinity-static.c: New file. * sysdeps/unix/sysv/linux/x86/libc-vdso.h: Check USE_VSYSCALL instead of SHARED. * sysdeps/unix/sysv/linux/x86_64/init-first.c: Don't check SHARED. * sysdeps/unix/sysv/linux/x86_64/sysdep.h (ALWAYS_USE_VSYSCALL): New.
Diffstat (limited to 'sysdeps/unix/sysv/linux/sysdep-vdso.h')
-rw-r--r--sysdeps/unix/sysv/linux/sysdep-vdso.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/sysdeps/unix/sysv/linux/sysdep-vdso.h b/sysdeps/unix/sysv/linux/sysdep-vdso.h
index 7f894c5e02..1ee0657ad3 100644
--- a/sysdeps/unix/sysv/linux/sysdep-vdso.h
+++ b/sysdeps/unix/sysv/linux/sysdep-vdso.h
@@ -26,7 +26,7 @@
funcptr (args)
#endif
-#if defined SHARED && defined HAVE_VSYSCALL
+#if USE_VSYSCALL && defined HAVE_VSYSCALL
# include <libc-vdso.h>
@@ -84,6 +84,6 @@
# define INTERNAL_VSYSCALL(name, err, nr, args...) \
INTERNAL_SYSCALL (name, err, nr, ##args)
-#endif /* defined SHARED && defined HAVE_VSYSCALL */
+#endif /* USE_VSYSCALL && defined HAVE_VSYSCALL */
#endif /* SYSDEP_VDSO_LINUX_H */