sparc: hook up execveat system call
authorDavid Drysdale <drysdale@google.com>
Sat, 13 Dec 2014 00:57:39 +0000 (16:57 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sat, 13 Dec 2014 20:42:51 +0000 (12:42 -0800)
Signed-off-by: David Drysdale <drysdale@google.com>
Acked-by: David S. Miller <davem@davemloft.net>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/sparc/include/uapi/asm/unistd.h
arch/sparc/kernel/syscalls.S
arch/sparc/kernel/systbls_32.S
arch/sparc/kernel/systbls_64.S

index 46d83842eddc6ceae0496b6397a0a04e77ce0e10..6f35f4df17f281f5aa52c31381a6b781629bbbb0 100644 (file)
 #define __NR_getrandom         347
 #define __NR_memfd_create      348
 #define __NR_bpf               349
+#define __NR_execveat          350
 
-#define NR_syscalls            350
+#define NR_syscalls            351
 
 /* Bitmask values returned from kern_features system call.  */
 #define KERN_FEATURE_MIXED_MODE_STACK  0x00000001
index 33a17e7b3ccd0fad8477d4c5b051cca1b24f248a..bb0008927598b1f7bbeeccdf30c6fa154219a4ce 100644 (file)
@@ -6,6 +6,11 @@ sys64_execve:
        jmpl    %g1, %g0
         flushw
 
+sys64_execveat:
+       set     sys_execveat, %g1
+       jmpl    %g1, %g0
+        flushw
+
 #ifdef CONFIG_COMPAT
 sunos_execv:
        mov     %g0, %o2
@@ -13,6 +18,11 @@ sys32_execve:
        set     compat_sys_execve, %g1
        jmpl    %g1, %g0
         flushw
+
+sys32_execveat:
+       set     compat_sys_execveat, %g1
+       jmpl    %g1, %g0
+        flushw
 #endif
 
        .align  32
index ad0cdf497b785de84fe3f8f5e1e092a4f2de7429..e31a9056a3039ad5e5b2b7da5abe7f18509d1107 100644 (file)
@@ -87,3 +87,4 @@ sys_call_table:
 /*335*/        .long sys_syncfs, sys_sendmmsg, sys_setns, sys_process_vm_readv, sys_process_vm_writev
 /*340*/        .long sys_ni_syscall, sys_kcmp, sys_finit_module, sys_sched_setattr, sys_sched_getattr
 /*345*/        .long sys_renameat2, sys_seccomp, sys_getrandom, sys_memfd_create, sys_bpf
+/*350*/        .long sys_execveat
index 580cde9370c9317a2cc8b6522579d5c38fa48ee3..d72f76ae70eba5a7418630c7e1890a6e239675cd 100644 (file)
@@ -88,6 +88,7 @@ sys_call_table32:
        .word sys_syncfs, compat_sys_sendmmsg, sys_setns, compat_sys_process_vm_readv, compat_sys_process_vm_writev
 /*340*/        .word sys_kern_features, sys_kcmp, sys_finit_module, sys_sched_setattr, sys_sched_getattr
        .word sys32_renameat2, sys_seccomp, sys_getrandom, sys_memfd_create, sys_bpf
+/*350*/        .word sys32_execveat
 
 #endif /* CONFIG_COMPAT */
 
@@ -167,3 +168,4 @@ sys_call_table:
        .word sys_syncfs, sys_sendmmsg, sys_setns, sys_process_vm_readv, sys_process_vm_writev
 /*340*/        .word sys_kern_features, sys_kcmp, sys_finit_module, sys_sched_setattr, sys_sched_getattr
        .word sys_renameat2, sys_seccomp, sys_getrandom, sys_memfd_create, sys_bpf
+/*350*/        .word sys64_execveat