aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/vdso/vdso32/sysenter.S
diff options
context:
space:
mode:
authorRoland McGrath <roland@redhat.com>2008-01-30 07:30:44 -0500
committerIngo Molnar <mingo@elte.hu>2008-01-30 07:30:44 -0500
commit69d0627a7f6e891189124d784d2fa90cae7c449a (patch)
treef39140f454b98a28846df7d0a1b9279a8b3b8d97 /arch/x86/vdso/vdso32/sysenter.S
parent16f4bc738d616962a844e80f7b1fcb52c626542a (diff)
x86 vDSO: reorder vdso32 code
This reorders the code in the 32-bit vDSO images to put the signal trampolines first and __kernel_vsyscall after them. The order does not matter to userland, it just uses what AT_SYSINFO or e_entry says. Since the signal trampolines are the same size in both versions of the vDSO, putting them first is the simplest way to get the addresses to line up. This makes it work to use a more compact layout for the vDSO. Signed-off-by: Roland McGrath <roland@redhat.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/vdso/vdso32/sysenter.S')
-rw-r--r--arch/x86/vdso/vdso32/sysenter.S21
1 files changed, 11 insertions, 10 deletions
diff --git a/arch/x86/vdso/vdso32/sysenter.S b/arch/x86/vdso/vdso32/sysenter.S
index 109bfa394eaa..902d5fc11f1b 100644
--- a/arch/x86/vdso/vdso32/sysenter.S
+++ b/arch/x86/vdso/vdso32/sysenter.S
@@ -1,11 +1,10 @@
1/* 1/*
2 * Code for the vsyscall page. This version uses the sysenter instruction. 2 * Code for the vDSO. This version uses the sysenter instruction.
3 * 3 *
4 * NOTE: 4 * First get the common code for the sigreturn entry points.
5 * 1) __kernel_vsyscall _must_ be first in this page. 5 * This must come first.
6 * 2) there are alignment constraints on this stub, see vsyscall-sigreturn.S
7 * for details.
8 */ 6 */
7#include "sigreturn.S"
9 8
10/* 9/*
11 * The caller puts arg2 in %ecx, which gets pushed. The kernel will use 10 * The caller puts arg2 in %ecx, which gets pushed. The kernel will use
@@ -23,11 +22,12 @@
23 * arg6 from the stack. 22 * arg6 from the stack.
24 * 23 *
25 * You can not use this vsyscall for the clone() syscall because the 24 * You can not use this vsyscall for the clone() syscall because the
26 * three dwords on the parent stack do not get copied to the child. 25 * three words on the parent stack do not get copied to the child.
27 */ 26 */
28 .text 27 .text
29 .globl __kernel_vsyscall 28 .globl __kernel_vsyscall
30 .type __kernel_vsyscall,@function 29 .type __kernel_vsyscall,@function
30 ALIGN
31__kernel_vsyscall: 31__kernel_vsyscall:
32.LSTART_vsyscall: 32.LSTART_vsyscall:
33 push %ecx 33 push %ecx
@@ -115,7 +115,8 @@ VDSO32_SYSENTER_RETURN: /* Symbol used by sysenter.c via vdso32-syms.h */
115.LENDFDEDLSI: 115.LENDFDEDLSI:
116 .previous 116 .previous
117 117
118/* 118 /*
119 * Get the common code for the sigreturn entry points. 119 * Emit a symbol with the size of this .eh_frame data,
120 */ 120 * to verify it matches the other versions.
121#include "sigreturn.S" 121 */
122VDSO32_vsyscall_eh_frame_size = (.LENDFDEDLSI-.LSTARTFRAMEDLSI)