am 24e1dd80: am 4eaa1e1e: Merge "x86_64: add new __NR_arch_prctl syscall"

* commit '24e1dd8016eeaaa6ef3646cbb143de1506e733e8':
  x86_64: add new __NR_arch_prctl syscall
This commit is contained in:
Elliott Hughes 2013-10-01 14:04:19 -07:00 committed by Android Git Automerger
commit 211fd4f963
3 changed files with 19 additions and 0 deletions

View File

@ -94,6 +94,7 @@ int chroot(const char*) all
# IMPORTANT: Even though <sys/prctl.h> declares prctl(int, ...), the syscall stub must take 6 arguments # IMPORTANT: Even though <sys/prctl.h> declares prctl(int, ...), the syscall stub must take 6 arguments
# to match the kernel implementation. # to match the kernel implementation.
int prctl(int option, unsigned int arg2, unsigned int arg3, unsigned int arg4, unsigned int arg5) all int prctl(int option, unsigned int arg2, unsigned int arg3, unsigned int arg4, unsigned int arg5) all
long arch_prctl(int, unsigned long) x86_64
int capget(cap_user_header_t header, cap_user_data_t data) all int capget(cap_user_header_t header, cap_user_data_t data) all
int capset(cap_user_header_t header, const cap_user_data_t data) all int capset(cap_user_header_t header, const cap_user_data_t data) all
int sigaltstack(const stack_t*, stack_t*) all int sigaltstack(const stack_t*, stack_t*) all

View File

@ -41,6 +41,7 @@ syscall_src += arch-x86_64/syscalls/vfork.S
syscall_src += arch-x86_64/syscalls/setregid.S syscall_src += arch-x86_64/syscalls/setregid.S
syscall_src += arch-x86_64/syscalls/chroot.S syscall_src += arch-x86_64/syscalls/chroot.S
syscall_src += arch-x86_64/syscalls/prctl.S syscall_src += arch-x86_64/syscalls/prctl.S
syscall_src += arch-x86_64/syscalls/arch_prctl.S
syscall_src += arch-x86_64/syscalls/capget.S syscall_src += arch-x86_64/syscalls/capget.S
syscall_src += arch-x86_64/syscalls/capset.S syscall_src += arch-x86_64/syscalls/capset.S
syscall_src += arch-x86_64/syscalls/sigaltstack.S syscall_src += arch-x86_64/syscalls/sigaltstack.S

View File

@ -0,0 +1,17 @@
/* autogenerated by gensyscalls.py */
#include <asm/unistd.h>
#include <linux/err.h>
#include <machine/asm.h>
ENTRY(arch_prctl)
movl $__NR_arch_prctl, %eax
syscall
cmpq $-MAX_ERRNO, %rax
jb 1f
negl %eax
movl %eax, %edi
call __set_errno
orq $-1, %rax
1:
ret
END(arch_prctl)