Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Compatibility mode system call entry point for x86-64. |
| 3 | * |
| 4 | * Copyright 2000-2002 Andi Kleen, SuSE Labs. |
| 5 | */ |
| 6 | |
| 7 | #include <asm/dwarf2.h> |
| 8 | #include <asm/calling.h> |
Sam Ravnborg | e2d5df9 | 2005-09-09 21:28:48 +0200 | [diff] [blame] | 9 | #include <asm/asm-offsets.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 10 | #include <asm/current.h> |
| 11 | #include <asm/errno.h> |
| 12 | #include <asm/ia32_unistd.h> |
| 13 | #include <asm/thread_info.h> |
| 14 | #include <asm/segment.h> |
| 15 | #include <asm/vsyscall32.h> |
| 16 | #include <linux/linkage.h> |
| 17 | |
| 18 | .macro IA32_ARG_FIXUP noebp=0 |
| 19 | movl %edi,%r8d |
| 20 | .if \noebp |
| 21 | .else |
| 22 | movl %ebp,%r9d |
| 23 | .endif |
| 24 | xchg %ecx,%esi |
| 25 | movl %ebx,%edi |
| 26 | movl %edx,%edx /* zero extension */ |
| 27 | .endm |
| 28 | |
| 29 | /* clobbers %eax */ |
| 30 | .macro CLEAR_RREGS |
| 31 | xorl %eax,%eax |
| 32 | movq %rax,R11(%rsp) |
| 33 | movq %rax,R10(%rsp) |
| 34 | movq %rax,R9(%rsp) |
| 35 | movq %rax,R8(%rsp) |
| 36 | .endm |
| 37 | |
| 38 | /* |
| 39 | * 32bit SYSENTER instruction entry. |
| 40 | * |
| 41 | * Arguments: |
| 42 | * %eax System call number. |
| 43 | * %ebx Arg1 |
| 44 | * %ecx Arg2 |
| 45 | * %edx Arg3 |
| 46 | * %esi Arg4 |
| 47 | * %edi Arg5 |
| 48 | * %ebp user stack |
| 49 | * 0(%ebp) Arg6 |
| 50 | * |
| 51 | * Interrupts off. |
| 52 | * |
| 53 | * This is purely a fast path. For anything complicated we use the int 0x80 |
| 54 | * path below. Set up a complete hardware stack frame to share code |
| 55 | * with the int 0x80 path. |
| 56 | */ |
| 57 | ENTRY(ia32_sysenter_target) |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 58 | CFI_STARTPROC simple |
| 59 | CFI_DEF_CFA rsp,0 |
| 60 | CFI_REGISTER rsp,rbp |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 61 | swapgs |
| 62 | movq %gs:pda_kernelstack, %rsp |
| 63 | addq $(PDA_STACKOFFSET),%rsp |
| 64 | sti |
| 65 | movl %ebp,%ebp /* zero extension */ |
| 66 | pushq $__USER32_DS |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 67 | CFI_ADJUST_CFA_OFFSET 8 |
| 68 | /*CFI_REL_OFFSET ss,0*/ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 69 | pushq %rbp |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 70 | CFI_ADJUST_CFA_OFFSET 8 |
| 71 | CFI_REL_OFFSET rsp,0 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 72 | pushfq |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 73 | CFI_ADJUST_CFA_OFFSET 8 |
| 74 | /*CFI_REL_OFFSET rflags,0*/ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 75 | movl $VSYSCALL32_SYSEXIT, %r10d |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 76 | CFI_REGISTER rip,r10 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 77 | pushq $__USER32_CS |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 78 | CFI_ADJUST_CFA_OFFSET 8 |
| 79 | /*CFI_REL_OFFSET cs,0*/ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 80 | movl %eax, %eax |
| 81 | pushq %r10 |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 82 | CFI_ADJUST_CFA_OFFSET 8 |
| 83 | CFI_REL_OFFSET rip,0 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 84 | pushq %rax |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 85 | CFI_ADJUST_CFA_OFFSET 8 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 86 | cld |
| 87 | SAVE_ARGS 0,0,1 |
| 88 | /* no need to do an access_ok check here because rbp has been |
| 89 | 32bit zero extended */ |
| 90 | 1: movl (%rbp),%r9d |
| 91 | .section __ex_table,"a" |
| 92 | .quad 1b,ia32_badarg |
| 93 | .previous |
| 94 | GET_THREAD_INFO(%r10) |
| 95 | testl $(_TIF_SYSCALL_TRACE|_TIF_SYSCALL_AUDIT|_TIF_SECCOMP),threadinfo_flags(%r10) |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 96 | CFI_REMEMBER_STATE |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 97 | jnz sysenter_tracesys |
| 98 | sysenter_do_call: |
| 99 | cmpl $(IA32_NR_syscalls),%eax |
| 100 | jae ia32_badsys |
| 101 | IA32_ARG_FIXUP 1 |
| 102 | call *ia32_sys_call_table(,%rax,8) |
| 103 | movq %rax,RAX-ARGOFFSET(%rsp) |
| 104 | GET_THREAD_INFO(%r10) |
| 105 | cli |
| 106 | testl $_TIF_ALLWORK_MASK,threadinfo_flags(%r10) |
| 107 | jnz int_ret_from_sys_call |
| 108 | /* clear IF, that popfq doesn't enable interrupts early */ |
| 109 | andl $~0x200,EFLAGS-R11(%rsp) |
| 110 | RESTORE_ARGS 1,24,1,1,1,1 |
| 111 | popfq |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 112 | CFI_ADJUST_CFA_OFFSET -8 |
| 113 | /*CFI_RESTORE rflags*/ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 114 | popq %rcx /* User %esp */ |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 115 | CFI_ADJUST_CFA_OFFSET -8 |
| 116 | CFI_REGISTER rsp,rcx |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 117 | movl $VSYSCALL32_SYSEXIT,%edx /* User %eip */ |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 118 | CFI_REGISTER rip,rdx |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 119 | swapgs |
| 120 | sti /* sti only takes effect after the next instruction */ |
| 121 | /* sysexit */ |
| 122 | .byte 0xf, 0x35 |
| 123 | |
| 124 | sysenter_tracesys: |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 125 | CFI_RESTORE_STATE |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 126 | SAVE_REST |
| 127 | CLEAR_RREGS |
| 128 | movq $-ENOSYS,RAX(%rsp) /* really needed? */ |
| 129 | movq %rsp,%rdi /* &pt_regs -> arg1 */ |
| 130 | call syscall_trace_enter |
| 131 | LOAD_ARGS ARGOFFSET /* reload args from stack in case ptrace changed it */ |
| 132 | RESTORE_REST |
| 133 | movl %ebp, %ebp |
| 134 | /* no need to do an access_ok check here because rbp has been |
| 135 | 32bit zero extended */ |
| 136 | 1: movl (%rbp),%r9d |
| 137 | .section __ex_table,"a" |
| 138 | .quad 1b,ia32_badarg |
| 139 | .previous |
| 140 | jmp sysenter_do_call |
| 141 | CFI_ENDPROC |
| 142 | |
| 143 | /* |
| 144 | * 32bit SYSCALL instruction entry. |
| 145 | * |
| 146 | * Arguments: |
| 147 | * %eax System call number. |
| 148 | * %ebx Arg1 |
| 149 | * %ecx return EIP |
| 150 | * %edx Arg3 |
| 151 | * %esi Arg4 |
| 152 | * %edi Arg5 |
| 153 | * %ebp Arg2 [note: not saved in the stack frame, should not be touched] |
| 154 | * %esp user stack |
| 155 | * 0(%esp) Arg6 |
| 156 | * |
| 157 | * Interrupts off. |
| 158 | * |
| 159 | * This is purely a fast path. For anything complicated we use the int 0x80 |
| 160 | * path below. Set up a complete hardware stack frame to share code |
| 161 | * with the int 0x80 path. |
| 162 | */ |
| 163 | ENTRY(ia32_cstar_target) |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 164 | CFI_STARTPROC simple |
| 165 | CFI_DEF_CFA rsp,0 |
| 166 | CFI_REGISTER rip,rcx |
| 167 | /*CFI_REGISTER rflags,r11*/ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 168 | swapgs |
| 169 | movl %esp,%r8d |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 170 | CFI_REGISTER rsp,r8 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 171 | movq %gs:pda_kernelstack,%rsp |
| 172 | sti |
| 173 | SAVE_ARGS 8,1,1 |
| 174 | movl %eax,%eax /* zero extension */ |
| 175 | movq %rax,ORIG_RAX-ARGOFFSET(%rsp) |
| 176 | movq %rcx,RIP-ARGOFFSET(%rsp) |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 177 | CFI_REL_OFFSET rip,RIP-ARGOFFSET |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 178 | movq %rbp,RCX-ARGOFFSET(%rsp) /* this lies slightly to ptrace */ |
| 179 | movl %ebp,%ecx |
| 180 | movq $__USER32_CS,CS-ARGOFFSET(%rsp) |
| 181 | movq $__USER32_DS,SS-ARGOFFSET(%rsp) |
| 182 | movq %r11,EFLAGS-ARGOFFSET(%rsp) |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 183 | /*CFI_REL_OFFSET rflags,EFLAGS-ARGOFFSET*/ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 184 | movq %r8,RSP-ARGOFFSET(%rsp) |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 185 | CFI_REL_OFFSET rsp,RSP-ARGOFFSET |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 186 | /* no need to do an access_ok check here because r8 has been |
| 187 | 32bit zero extended */ |
| 188 | /* hardware stack frame is complete now */ |
| 189 | 1: movl (%r8),%r9d |
| 190 | .section __ex_table,"a" |
| 191 | .quad 1b,ia32_badarg |
| 192 | .previous |
| 193 | GET_THREAD_INFO(%r10) |
| 194 | testl $(_TIF_SYSCALL_TRACE|_TIF_SYSCALL_AUDIT|_TIF_SECCOMP),threadinfo_flags(%r10) |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 195 | CFI_REMEMBER_STATE |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 196 | jnz cstar_tracesys |
| 197 | cstar_do_call: |
| 198 | cmpl $IA32_NR_syscalls,%eax |
| 199 | jae ia32_badsys |
| 200 | IA32_ARG_FIXUP 1 |
| 201 | call *ia32_sys_call_table(,%rax,8) |
| 202 | movq %rax,RAX-ARGOFFSET(%rsp) |
| 203 | GET_THREAD_INFO(%r10) |
| 204 | cli |
| 205 | testl $_TIF_ALLWORK_MASK,threadinfo_flags(%r10) |
| 206 | jnz int_ret_from_sys_call |
| 207 | RESTORE_ARGS 1,-ARG_SKIP,1,1,1 |
| 208 | movl RIP-ARGOFFSET(%rsp),%ecx |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 209 | CFI_REGISTER rip,rcx |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 210 | movl EFLAGS-ARGOFFSET(%rsp),%r11d |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 211 | /*CFI_REGISTER rflags,r11*/ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 212 | movl RSP-ARGOFFSET(%rsp),%esp |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 213 | CFI_RESTORE rsp |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 214 | swapgs |
| 215 | sysretl |
| 216 | |
| 217 | cstar_tracesys: |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 218 | CFI_RESTORE_STATE |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 219 | SAVE_REST |
| 220 | CLEAR_RREGS |
| 221 | movq $-ENOSYS,RAX(%rsp) /* really needed? */ |
| 222 | movq %rsp,%rdi /* &pt_regs -> arg1 */ |
| 223 | call syscall_trace_enter |
| 224 | LOAD_ARGS ARGOFFSET /* reload args from stack in case ptrace changed it */ |
| 225 | RESTORE_REST |
| 226 | movl RSP-ARGOFFSET(%rsp), %r8d |
| 227 | /* no need to do an access_ok check here because r8 has been |
| 228 | 32bit zero extended */ |
| 229 | 1: movl (%r8),%r9d |
| 230 | .section __ex_table,"a" |
| 231 | .quad 1b,ia32_badarg |
| 232 | .previous |
| 233 | jmp cstar_do_call |
| 234 | |
| 235 | ia32_badarg: |
| 236 | movq $-EFAULT,%rax |
| 237 | jmp ia32_sysret |
| 238 | CFI_ENDPROC |
| 239 | |
| 240 | /* |
| 241 | * Emulated IA32 system calls via int 0x80. |
| 242 | * |
| 243 | * Arguments: |
| 244 | * %eax System call number. |
| 245 | * %ebx Arg1 |
| 246 | * %ecx Arg2 |
| 247 | * %edx Arg3 |
| 248 | * %esi Arg4 |
| 249 | * %edi Arg5 |
| 250 | * %ebp Arg6 [note: not saved in the stack frame, should not be touched] |
| 251 | * |
| 252 | * Notes: |
| 253 | * Uses the same stack frame as the x86-64 version. |
| 254 | * All registers except %eax must be saved (but ptrace may violate that) |
| 255 | * Arguments are zero extended. For system calls that want sign extension and |
| 256 | * take long arguments a wrapper is needed. Most calls can just be called |
| 257 | * directly. |
| 258 | * Assumes it is only called from user space and entered with interrupts off. |
| 259 | */ |
| 260 | |
| 261 | ENTRY(ia32_syscall) |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 262 | CFI_STARTPROC simple |
| 263 | CFI_DEF_CFA rsp,SS+8-RIP |
| 264 | /*CFI_REL_OFFSET ss,SS-RIP*/ |
| 265 | CFI_REL_OFFSET rsp,RSP-RIP |
| 266 | /*CFI_REL_OFFSET rflags,EFLAGS-RIP*/ |
| 267 | /*CFI_REL_OFFSET cs,CS-RIP*/ |
| 268 | CFI_REL_OFFSET rip,RIP-RIP |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 269 | swapgs |
| 270 | sti |
| 271 | movl %eax,%eax |
| 272 | pushq %rax |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 273 | CFI_ADJUST_CFA_OFFSET 8 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 274 | cld |
| 275 | /* note the registers are not zero extended to the sf. |
| 276 | this could be a problem. */ |
| 277 | SAVE_ARGS 0,0,1 |
| 278 | GET_THREAD_INFO(%r10) |
| 279 | testl $(_TIF_SYSCALL_TRACE|_TIF_SYSCALL_AUDIT|_TIF_SECCOMP),threadinfo_flags(%r10) |
| 280 | jnz ia32_tracesys |
| 281 | ia32_do_syscall: |
| 282 | cmpl $(IA32_NR_syscalls),%eax |
| 283 | jae ia32_badsys |
| 284 | IA32_ARG_FIXUP |
| 285 | call *ia32_sys_call_table(,%rax,8) # xxx: rip relative |
| 286 | ia32_sysret: |
| 287 | movq %rax,RAX-ARGOFFSET(%rsp) |
| 288 | jmp int_ret_from_sys_call |
| 289 | |
| 290 | ia32_tracesys: |
| 291 | SAVE_REST |
| 292 | movq $-ENOSYS,RAX(%rsp) /* really needed? */ |
| 293 | movq %rsp,%rdi /* &pt_regs -> arg1 */ |
| 294 | call syscall_trace_enter |
| 295 | LOAD_ARGS ARGOFFSET /* reload args from stack in case ptrace changed it */ |
| 296 | RESTORE_REST |
| 297 | jmp ia32_do_syscall |
| 298 | |
| 299 | ia32_badsys: |
| 300 | movq $0,ORIG_RAX-ARGOFFSET(%rsp) |
| 301 | movq $-ENOSYS,RAX-ARGOFFSET(%rsp) |
| 302 | jmp int_ret_from_sys_call |
| 303 | |
| 304 | ni_syscall: |
| 305 | movq %rax,%rdi |
| 306 | jmp sys32_ni_syscall |
| 307 | |
| 308 | quiet_ni_syscall: |
| 309 | movq $-ENOSYS,%rax |
| 310 | ret |
| 311 | CFI_ENDPROC |
| 312 | |
| 313 | .macro PTREGSCALL label, func, arg |
| 314 | .globl \label |
| 315 | \label: |
| 316 | leaq \func(%rip),%rax |
| 317 | leaq -ARGOFFSET+8(%rsp),\arg /* 8 for return address */ |
| 318 | jmp ia32_ptregs_common |
| 319 | .endm |
| 320 | |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 321 | CFI_STARTPROC |
| 322 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 323 | PTREGSCALL stub32_rt_sigreturn, sys32_rt_sigreturn, %rdi |
| 324 | PTREGSCALL stub32_sigreturn, sys32_sigreturn, %rdi |
| 325 | PTREGSCALL stub32_sigaltstack, sys32_sigaltstack, %rdx |
| 326 | PTREGSCALL stub32_sigsuspend, sys32_sigsuspend, %rcx |
| 327 | PTREGSCALL stub32_execve, sys32_execve, %rcx |
| 328 | PTREGSCALL stub32_fork, sys_fork, %rdi |
| 329 | PTREGSCALL stub32_clone, sys32_clone, %rdx |
| 330 | PTREGSCALL stub32_vfork, sys_vfork, %rdi |
| 331 | PTREGSCALL stub32_iopl, sys_iopl, %rsi |
| 332 | PTREGSCALL stub32_rt_sigsuspend, sys_rt_sigsuspend, %rdx |
| 333 | |
| 334 | ENTRY(ia32_ptregs_common) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 335 | popq %r11 |
Jan Beulich | 7effaa8 | 2005-09-12 18:49:24 +0200 | [diff] [blame^] | 336 | CFI_ADJUST_CFA_OFFSET -8 |
| 337 | CFI_REGISTER rip, r11 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 338 | SAVE_REST |
| 339 | call *%rax |
| 340 | RESTORE_REST |
| 341 | jmp ia32_sysret /* misbalances the return cache */ |
| 342 | CFI_ENDPROC |
| 343 | |
| 344 | .data |
| 345 | .align 8 |
| 346 | .globl ia32_sys_call_table |
| 347 | ia32_sys_call_table: |
| 348 | .quad sys_restart_syscall |
| 349 | .quad sys_exit |
| 350 | .quad stub32_fork |
| 351 | .quad sys_read |
| 352 | .quad sys_write |
Miklos Szeredi | e922efc | 2005-09-06 15:18:25 -0700 | [diff] [blame] | 353 | .quad compat_sys_open /* 5 */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 354 | .quad sys_close |
| 355 | .quad sys32_waitpid |
| 356 | .quad sys_creat |
| 357 | .quad sys_link |
| 358 | .quad sys_unlink /* 10 */ |
| 359 | .quad stub32_execve |
| 360 | .quad sys_chdir |
| 361 | .quad compat_sys_time |
| 362 | .quad sys_mknod |
| 363 | .quad sys_chmod /* 15 */ |
| 364 | .quad sys_lchown16 |
| 365 | .quad quiet_ni_syscall /* old break syscall holder */ |
| 366 | .quad sys_stat |
| 367 | .quad sys32_lseek |
| 368 | .quad sys_getpid /* 20 */ |
| 369 | .quad compat_sys_mount /* mount */ |
| 370 | .quad sys_oldumount /* old_umount */ |
| 371 | .quad sys_setuid16 |
| 372 | .quad sys_getuid16 |
| 373 | .quad compat_sys_stime /* stime */ /* 25 */ |
| 374 | .quad sys32_ptrace /* ptrace */ |
| 375 | .quad sys_alarm |
| 376 | .quad sys_fstat /* (old)fstat */ |
| 377 | .quad sys_pause |
| 378 | .quad compat_sys_utime /* 30 */ |
| 379 | .quad quiet_ni_syscall /* old stty syscall holder */ |
| 380 | .quad quiet_ni_syscall /* old gtty syscall holder */ |
| 381 | .quad sys_access |
| 382 | .quad sys_nice |
| 383 | .quad quiet_ni_syscall /* 35 */ /* old ftime syscall holder */ |
| 384 | .quad sys_sync |
| 385 | .quad sys32_kill |
| 386 | .quad sys_rename |
| 387 | .quad sys_mkdir |
| 388 | .quad sys_rmdir /* 40 */ |
| 389 | .quad sys_dup |
| 390 | .quad sys32_pipe |
| 391 | .quad compat_sys_times |
| 392 | .quad quiet_ni_syscall /* old prof syscall holder */ |
| 393 | .quad sys_brk /* 45 */ |
| 394 | .quad sys_setgid16 |
| 395 | .quad sys_getgid16 |
| 396 | .quad sys_signal |
| 397 | .quad sys_geteuid16 |
| 398 | .quad sys_getegid16 /* 50 */ |
| 399 | .quad sys_acct |
| 400 | .quad sys_umount /* new_umount */ |
| 401 | .quad quiet_ni_syscall /* old lock syscall holder */ |
| 402 | .quad compat_sys_ioctl |
| 403 | .quad compat_sys_fcntl64 /* 55 */ |
| 404 | .quad quiet_ni_syscall /* old mpx syscall holder */ |
| 405 | .quad sys_setpgid |
| 406 | .quad quiet_ni_syscall /* old ulimit syscall holder */ |
| 407 | .quad sys32_olduname |
| 408 | .quad sys_umask /* 60 */ |
| 409 | .quad sys_chroot |
| 410 | .quad sys32_ustat |
| 411 | .quad sys_dup2 |
| 412 | .quad sys_getppid |
| 413 | .quad sys_getpgrp /* 65 */ |
| 414 | .quad sys_setsid |
| 415 | .quad sys32_sigaction |
| 416 | .quad sys_sgetmask |
| 417 | .quad sys_ssetmask |
| 418 | .quad sys_setreuid16 /* 70 */ |
| 419 | .quad sys_setregid16 |
| 420 | .quad stub32_sigsuspend |
| 421 | .quad compat_sys_sigpending |
| 422 | .quad sys_sethostname |
| 423 | .quad compat_sys_setrlimit /* 75 */ |
| 424 | .quad compat_sys_old_getrlimit /* old_getrlimit */ |
| 425 | .quad compat_sys_getrusage |
| 426 | .quad sys32_gettimeofday |
| 427 | .quad sys32_settimeofday |
| 428 | .quad sys_getgroups16 /* 80 */ |
| 429 | .quad sys_setgroups16 |
| 430 | .quad sys32_old_select |
| 431 | .quad sys_symlink |
| 432 | .quad sys_lstat |
| 433 | .quad sys_readlink /* 85 */ |
| 434 | #ifdef CONFIG_IA32_AOUT |
| 435 | .quad sys_uselib |
| 436 | #else |
| 437 | .quad quiet_ni_syscall |
| 438 | #endif |
| 439 | .quad sys_swapon |
| 440 | .quad sys_reboot |
| 441 | .quad compat_sys_old_readdir |
| 442 | .quad sys32_mmap /* 90 */ |
| 443 | .quad sys_munmap |
| 444 | .quad sys_truncate |
| 445 | .quad sys_ftruncate |
| 446 | .quad sys_fchmod |
| 447 | .quad sys_fchown16 /* 95 */ |
| 448 | .quad sys_getpriority |
| 449 | .quad sys_setpriority |
| 450 | .quad quiet_ni_syscall /* old profil syscall holder */ |
| 451 | .quad compat_sys_statfs |
| 452 | .quad compat_sys_fstatfs /* 100 */ |
| 453 | .quad sys_ioperm |
| 454 | .quad compat_sys_socketcall |
| 455 | .quad sys_syslog |
| 456 | .quad compat_sys_setitimer |
| 457 | .quad compat_sys_getitimer /* 105 */ |
| 458 | .quad compat_sys_newstat |
| 459 | .quad compat_sys_newlstat |
| 460 | .quad compat_sys_newfstat |
| 461 | .quad sys32_uname |
| 462 | .quad stub32_iopl /* 110 */ |
| 463 | .quad sys_vhangup |
| 464 | .quad quiet_ni_syscall /* old "idle" system call */ |
| 465 | .quad sys32_vm86_warning /* vm86old */ |
| 466 | .quad compat_sys_wait4 |
| 467 | .quad sys_swapoff /* 115 */ |
| 468 | .quad sys32_sysinfo |
| 469 | .quad sys32_ipc |
| 470 | .quad sys_fsync |
| 471 | .quad stub32_sigreturn |
| 472 | .quad stub32_clone /* 120 */ |
| 473 | .quad sys_setdomainname |
| 474 | .quad sys_uname |
| 475 | .quad sys_modify_ldt |
| 476 | .quad sys32_adjtimex |
| 477 | .quad sys32_mprotect /* 125 */ |
| 478 | .quad compat_sys_sigprocmask |
| 479 | .quad quiet_ni_syscall /* create_module */ |
| 480 | .quad sys_init_module |
| 481 | .quad sys_delete_module |
| 482 | .quad quiet_ni_syscall /* 130 get_kernel_syms */ |
| 483 | .quad sys_quotactl |
| 484 | .quad sys_getpgid |
| 485 | .quad sys_fchdir |
| 486 | .quad quiet_ni_syscall /* bdflush */ |
| 487 | .quad sys_sysfs /* 135 */ |
| 488 | .quad sys_personality |
| 489 | .quad quiet_ni_syscall /* for afs_syscall */ |
| 490 | .quad sys_setfsuid16 |
| 491 | .quad sys_setfsgid16 |
| 492 | .quad sys_llseek /* 140 */ |
| 493 | .quad compat_sys_getdents |
| 494 | .quad compat_sys_select |
| 495 | .quad sys_flock |
| 496 | .quad sys_msync |
| 497 | .quad compat_sys_readv /* 145 */ |
| 498 | .quad compat_sys_writev |
| 499 | .quad sys_getsid |
| 500 | .quad sys_fdatasync |
| 501 | .quad sys32_sysctl /* sysctl */ |
| 502 | .quad sys_mlock /* 150 */ |
| 503 | .quad sys_munlock |
| 504 | .quad sys_mlockall |
| 505 | .quad sys_munlockall |
| 506 | .quad sys_sched_setparam |
| 507 | .quad sys_sched_getparam /* 155 */ |
| 508 | .quad sys_sched_setscheduler |
| 509 | .quad sys_sched_getscheduler |
| 510 | .quad sys_sched_yield |
| 511 | .quad sys_sched_get_priority_max |
| 512 | .quad sys_sched_get_priority_min /* 160 */ |
| 513 | .quad sys_sched_rr_get_interval |
| 514 | .quad compat_sys_nanosleep |
| 515 | .quad sys_mremap |
| 516 | .quad sys_setresuid16 |
| 517 | .quad sys_getresuid16 /* 165 */ |
| 518 | .quad sys32_vm86_warning /* vm86 */ |
| 519 | .quad quiet_ni_syscall /* query_module */ |
| 520 | .quad sys_poll |
| 521 | .quad compat_sys_nfsservctl |
| 522 | .quad sys_setresgid16 /* 170 */ |
| 523 | .quad sys_getresgid16 |
| 524 | .quad sys_prctl |
| 525 | .quad stub32_rt_sigreturn |
| 526 | .quad sys32_rt_sigaction |
| 527 | .quad sys32_rt_sigprocmask /* 175 */ |
| 528 | .quad sys32_rt_sigpending |
| 529 | .quad compat_sys_rt_sigtimedwait |
| 530 | .quad sys32_rt_sigqueueinfo |
| 531 | .quad stub32_rt_sigsuspend |
| 532 | .quad sys32_pread /* 180 */ |
| 533 | .quad sys32_pwrite |
| 534 | .quad sys_chown16 |
| 535 | .quad sys_getcwd |
| 536 | .quad sys_capget |
| 537 | .quad sys_capset |
| 538 | .quad stub32_sigaltstack |
| 539 | .quad sys32_sendfile |
| 540 | .quad quiet_ni_syscall /* streams1 */ |
| 541 | .quad quiet_ni_syscall /* streams2 */ |
| 542 | .quad stub32_vfork /* 190 */ |
| 543 | .quad compat_sys_getrlimit |
| 544 | .quad sys32_mmap2 |
| 545 | .quad sys32_truncate64 |
| 546 | .quad sys32_ftruncate64 |
| 547 | .quad sys32_stat64 /* 195 */ |
| 548 | .quad sys32_lstat64 |
| 549 | .quad sys32_fstat64 |
| 550 | .quad sys_lchown |
| 551 | .quad sys_getuid |
| 552 | .quad sys_getgid /* 200 */ |
| 553 | .quad sys_geteuid |
| 554 | .quad sys_getegid |
| 555 | .quad sys_setreuid |
| 556 | .quad sys_setregid |
| 557 | .quad sys_getgroups /* 205 */ |
| 558 | .quad sys_setgroups |
| 559 | .quad sys_fchown |
| 560 | .quad sys_setresuid |
| 561 | .quad sys_getresuid |
| 562 | .quad sys_setresgid /* 210 */ |
| 563 | .quad sys_getresgid |
| 564 | .quad sys_chown |
| 565 | .quad sys_setuid |
| 566 | .quad sys_setgid |
| 567 | .quad sys_setfsuid /* 215 */ |
| 568 | .quad sys_setfsgid |
| 569 | .quad sys_pivot_root |
| 570 | .quad sys_mincore |
| 571 | .quad sys_madvise |
| 572 | .quad compat_sys_getdents64 /* 220 getdents64 */ |
| 573 | .quad compat_sys_fcntl64 |
| 574 | .quad quiet_ni_syscall /* tux */ |
| 575 | .quad quiet_ni_syscall /* security */ |
| 576 | .quad sys_gettid |
| 577 | .quad sys_readahead /* 225 */ |
| 578 | .quad sys_setxattr |
| 579 | .quad sys_lsetxattr |
| 580 | .quad sys_fsetxattr |
| 581 | .quad sys_getxattr |
| 582 | .quad sys_lgetxattr /* 230 */ |
| 583 | .quad sys_fgetxattr |
| 584 | .quad sys_listxattr |
| 585 | .quad sys_llistxattr |
| 586 | .quad sys_flistxattr |
| 587 | .quad sys_removexattr /* 235 */ |
| 588 | .quad sys_lremovexattr |
| 589 | .quad sys_fremovexattr |
| 590 | .quad sys_tkill |
| 591 | .quad sys_sendfile64 |
| 592 | .quad compat_sys_futex /* 240 */ |
| 593 | .quad compat_sys_sched_setaffinity |
| 594 | .quad compat_sys_sched_getaffinity |
| 595 | .quad sys32_set_thread_area |
| 596 | .quad sys32_get_thread_area |
| 597 | .quad compat_sys_io_setup /* 245 */ |
| 598 | .quad sys_io_destroy |
| 599 | .quad compat_sys_io_getevents |
| 600 | .quad compat_sys_io_submit |
| 601 | .quad sys_io_cancel |
| 602 | .quad sys_fadvise64 /* 250 */ |
| 603 | .quad quiet_ni_syscall /* free_huge_pages */ |
| 604 | .quad sys_exit_group |
| 605 | .quad sys32_lookup_dcookie |
| 606 | .quad sys_epoll_create |
| 607 | .quad sys_epoll_ctl /* 255 */ |
| 608 | .quad sys_epoll_wait |
| 609 | .quad sys_remap_file_pages |
| 610 | .quad sys_set_tid_address |
| 611 | .quad sys32_timer_create |
| 612 | .quad compat_sys_timer_settime /* 260 */ |
| 613 | .quad compat_sys_timer_gettime |
| 614 | .quad sys_timer_getoverrun |
| 615 | .quad sys_timer_delete |
| 616 | .quad compat_sys_clock_settime |
| 617 | .quad compat_sys_clock_gettime /* 265 */ |
| 618 | .quad compat_sys_clock_getres |
| 619 | .quad compat_sys_clock_nanosleep |
| 620 | .quad compat_sys_statfs64 |
| 621 | .quad compat_sys_fstatfs64 |
| 622 | .quad sys_tgkill /* 270 */ |
| 623 | .quad compat_sys_utimes |
| 624 | .quad sys32_fadvise64_64 |
| 625 | .quad quiet_ni_syscall /* sys_vserver */ |
| 626 | .quad sys_mbind |
| 627 | .quad compat_sys_get_mempolicy /* 275 */ |
| 628 | .quad sys_set_mempolicy |
| 629 | .quad compat_sys_mq_open |
| 630 | .quad sys_mq_unlink |
| 631 | .quad compat_sys_mq_timedsend |
| 632 | .quad compat_sys_mq_timedreceive /* 280 */ |
| 633 | .quad compat_sys_mq_notify |
| 634 | .quad compat_sys_mq_getsetattr |
Eric W. Biederman | 5234f5e | 2005-06-25 14:58:02 -0700 | [diff] [blame] | 635 | .quad compat_sys_kexec_load /* reserved for kexec */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 636 | .quad compat_sys_waitid |
Robert Love | 725b38ab | 2005-07-25 15:19:29 -0400 | [diff] [blame] | 637 | .quad quiet_ni_syscall /* 285: sys_altroot */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 638 | .quad sys_add_key |
| 639 | .quad sys_request_key |
| 640 | .quad sys_keyctl |
Robert Love | 725b38ab | 2005-07-25 15:19:29 -0400 | [diff] [blame] | 641 | .quad sys_ioprio_set |
| 642 | .quad sys_ioprio_get /* 290 */ |
| 643 | .quad sys_inotify_init |
| 644 | .quad sys_inotify_add_watch |
| 645 | .quad sys_inotify_rm_watch |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 646 | ia32_syscall_end: |
| 647 | .rept IA32_NR_syscalls-(ia32_syscall_end-ia32_sys_call_table)/8 |
| 648 | .quad ni_syscall |
| 649 | .endr |