aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86_64/ia32/vsyscall-syscall.S
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:20:36 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:20:36 -0400
commit1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 (patch)
tree0bba044c4ce775e45a88a51686b5d9f90697ea9d /arch/x86_64/ia32/vsyscall-syscall.S
Linux-2.6.12-rc2v2.6.12-rc2
Initial git repository build. I'm not bothering with the full history, even though we have it. We can create a separate "historical" git archive of that later if we want to, and in the meantime it's about 3.2GB when imported into git - space that would just make the early git days unnecessarily complicated, when we don't have a lot of good infrastructure for it. Let it rip!
Diffstat (limited to 'arch/x86_64/ia32/vsyscall-syscall.S')
-rw-r--r--arch/x86_64/ia32/vsyscall-syscall.S68
1 files changed, 68 insertions, 0 deletions
diff --git a/arch/x86_64/ia32/vsyscall-syscall.S b/arch/x86_64/ia32/vsyscall-syscall.S
new file mode 100644
index 000000000000..e2aaf3de8a42
--- /dev/null
+++ b/arch/x86_64/ia32/vsyscall-syscall.S
@@ -0,0 +1,68 @@
1/*
2 * Code for the vsyscall page. This version uses the syscall instruction.
3 */
4
5#include <asm/ia32_unistd.h>
6#include <asm/offset.h>
7#include <asm/segment.h>
8
9 .text
10 .section .text.vsyscall,"ax"
11 .globl __kernel_vsyscall
12 .type __kernel_vsyscall,@function
13__kernel_vsyscall:
14.LSTART_vsyscall:
15 push %ebp
16.Lpush_ebp:
17 movl %ecx, %ebp
18 syscall
19 movl $__USER32_DS, %ecx
20 movl %ecx, %ss
21 movl %ebp, %ecx
22 popl %ebp
23.Lpop_ebp:
24 ret
25.LEND_vsyscall:
26 .size __kernel_vsyscall,.-.LSTART_vsyscall
27
28 .section .eh_frame,"a",@progbits
29.LSTARTFRAME:
30 .long .LENDCIE-.LSTARTCIE
31.LSTARTCIE:
32 .long 0 /* CIE ID */
33 .byte 1 /* Version number */
34 .string "zR" /* NUL-terminated augmentation string */
35 .uleb128 1 /* Code alignment factor */
36 .sleb128 -4 /* Data alignment factor */
37 .byte 8 /* Return address register column */
38 .uleb128 1 /* Augmentation value length */
39 .byte 0x1b /* DW_EH_PE_pcrel|DW_EH_PE_sdata4. */
40 .byte 0x0c /* DW_CFA_def_cfa */
41 .uleb128 4
42 .uleb128 4
43 .byte 0x88 /* DW_CFA_offset, column 0x8 */
44 .uleb128 1
45 .align 4
46.LENDCIE:
47
48 .long .LENDFDE1-.LSTARTFDE1 /* Length FDE */
49.LSTARTFDE1:
50 .long .LSTARTFDE1-.LSTARTFRAME /* CIE pointer */
51 .long .LSTART_vsyscall-. /* PC-relative start address */
52 .long .LEND_vsyscall-.LSTART_vsyscall
53 .uleb128 0 /* Augmentation length */
54 /* What follows are the instructions for the table generation.
55 We have to record all changes of the stack pointer. */
56 .byte 0x40 + .Lpush_ebp-.LSTART_vsyscall /* DW_CFA_advance_loc */
57 .byte 0x0e /* DW_CFA_def_cfa_offset */
58 .uleb128 8
59 .byte 0x85, 0x02 /* DW_CFA_offset %ebp -8 */
60 .byte 0x40 + .Lpop_ebp-.Lpush_ebp /* DW_CFA_advance_loc */
61 .byte 0xc5 /* DW_CFA_restore %ebp */
62 .byte 0x0e /* DW_CFA_def_cfa_offset */
63 .uleb128 4
64 .align 4
65.LENDFDE1:
66
67#define SYSCALL_ENTER_KERNEL syscall
68#include "vsyscall-sigreturn.S"