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 46d8384..6f35f4d 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 33a17e7..bb00089 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 ad0cdf4..e31a905 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 580cde9..d72f76a 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