diff options
author | Andy Lutomirski <luto@amacapital.net> | 2014-03-20 21:57:18 -0400 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2014-03-20 23:20:08 -0400 |
commit | 9e6f450f946d35d585798da268d45c679632fe05 (patch) | |
tree | 733e5945b5efc2be040da323ec2c17c1100525d3 /arch/x86/include | |
parent | b67e612cef1e5964efc6fa99fb7ad3d31c4db01a (diff) |
x86, vdso: Move more vdso definitions into vdso.h
This fixes the Xen build and gets rid of a silly header file.
Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Cc: Stefani Seibold <stefani@seibold.net>
Link: http://lkml.kernel.org/r/1df77311795aff75f5742c787d277518314a38d3.1395366931.git.luto@amacapital.net
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'arch/x86/include')
-rw-r--r-- | arch/x86/include/asm/vdso.h | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/arch/x86/include/asm/vdso.h b/arch/x86/include/asm/vdso.h index 0301d78bb910..7622a65a969e 100644 --- a/arch/x86/include/asm/vdso.h +++ b/arch/x86/include/asm/vdso.h | |||
@@ -1,10 +1,46 @@ | |||
1 | #ifndef _ASM_X86_VDSO_H | 1 | #ifndef _ASM_X86_VDSO_H |
2 | #define _ASM_X86_VDSO_H | 2 | #define _ASM_X86_VDSO_H |
3 | 3 | ||
4 | #include <asm/page_types.h> | ||
5 | #include <linux/linkage.h> | ||
6 | |||
7 | #ifdef __ASSEMBLER__ | ||
8 | |||
9 | #define DEFINE_VDSO_IMAGE(symname, filename) \ | ||
10 | __PAGE_ALIGNED_DATA ; \ | ||
11 | .globl symname##_start, symname##_end ; \ | ||
12 | .align PAGE_SIZE ; \ | ||
13 | symname##_start: ; \ | ||
14 | .incbin filename ; \ | ||
15 | symname##_end: ; \ | ||
16 | .align PAGE_SIZE /* extra data here leaks to userspace. */ ; \ | ||
17 | \ | ||
18 | .previous ; \ | ||
19 | \ | ||
20 | .globl symname##_pages ; \ | ||
21 | .bss ; \ | ||
22 | .align 8 ; \ | ||
23 | .type symname##_pages, @object ; \ | ||
24 | symname##_pages: ; \ | ||
25 | .zero (symname##_end - symname##_start + PAGE_SIZE - 1) / PAGE_SIZE * (BITS_PER_LONG / 8) ; \ | ||
26 | .size symname##_pages, .-symname##_pages | ||
27 | |||
28 | #else | ||
29 | |||
30 | #define DECLARE_VDSO_IMAGE(symname) \ | ||
31 | extern char symname##_start[], symname##_end[]; \ | ||
32 | extern struct page *symname##_pages[] | ||
33 | |||
4 | #if defined CONFIG_X86_32 || defined CONFIG_COMPAT | 34 | #if defined CONFIG_X86_32 || defined CONFIG_COMPAT |
5 | 35 | ||
6 | #include <asm/vdso32.h> | 36 | #include <asm/vdso32.h> |
7 | 37 | ||
38 | DECLARE_VDSO_IMAGE(vdso32_int80); | ||
39 | #ifdef CONFIG_COMPAT | ||
40 | DECLARE_VDSO_IMAGE(vdso32_syscall); | ||
41 | #endif | ||
42 | DECLARE_VDSO_IMAGE(vdso32_sysenter); | ||
43 | |||
8 | extern const char VDSO32_PRELINK[]; | 44 | extern const char VDSO32_PRELINK[]; |
9 | 45 | ||
10 | /* | 46 | /* |
@@ -27,4 +63,6 @@ extern void __user __kernel_rt_sigreturn; | |||
27 | 63 | ||
28 | void __init patch_vdso32(void *vdso, size_t len); | 64 | void __init patch_vdso32(void *vdso, size_t len); |
29 | 65 | ||
66 | #endif /* __ASSEMBLER__ */ | ||
67 | |||
30 | #endif /* _ASM_X86_VDSO_H */ | 68 | #endif /* _ASM_X86_VDSO_H */ |