1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
---|---|
2 | /* |
3 | * vsyscall_emu_64.S: Vsyscall emulation page |
4 | * |
5 | * Copyright (c) 2011 Andy Lutomirski |
6 | */ |
7 | |
8 | #include <linux/linkage.h> |
9 | |
10 | #include <asm/irq_vectors.h> |
11 | #include <asm/page_types.h> |
12 | #include <asm/unistd_64.h> |
13 | |
14 | __PAGE_ALIGNED_DATA |
15 | .globl __vsyscall_page |
16 | .balign PAGE_SIZE, 0xcc |
17 | .type __vsyscall_page, @object |
18 | __vsyscall_page: |
19 | |
20 | mov $__NR_gettimeofday, %rax |
21 | syscall |
22 | ret |
23 | int3 |
24 | |
25 | .balign 1024, 0xcc |
26 | mov $__NR_time, %rax |
27 | syscall |
28 | ret |
29 | int3 |
30 | |
31 | .balign 1024, 0xcc |
32 | mov $__NR_getcpu, %rax |
33 | syscall |
34 | ret |
35 | int3 |
36 | |
37 | .balign 4096, 0xcc |
38 | |
39 | .size __vsyscall_page, 4096 |
40 |