linux-mips
[Top] [All Lists]

[PATCH v6 8/9] ARM: add seccomp syscall

To: linux-kernel@vger.kernel.org
Subject: [PATCH v6 8/9] ARM: add seccomp syscall
From: Kees Cook <keescook@chromium.org>
Date: Tue, 10 Jun 2014 16:01:53 -0700
Cc: Kees Cook <keescook@chromium.org>, Andy Lutomirski <luto@amacapital.net>, Oleg Nesterov <oleg@redhat.com>, Will Drewry <wad@chromium.org>, Julien Tinnes <jln@chromium.org>, David Drysdale <drysdale@google.com>, Alexei Starovoitov <ast@plumgrid.com>, John Johansen <john.johansen@canonical.com>, Russell King <linux@arm.linux.org.uk>, Ralf Baechle <ralf@linux-mips.org>, Thomas Gleixner <tglx@linutronix.de>, Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>, Alexander Viro <viro@zeniv.linux.org.uk>, Peter Zijlstra <peterz@infradead.org>, Arnd Bergmann <arnd@arndb.de>, James Morris <james.l.morris@oracle.com>, Andrew Morton <akpm@linux-foundation.org>, Frederic Weisbecker <fweisbec@gmail.com>, "David A. Long" <dave.long@linaro.org>, Heiko Carstens <heiko.carstens@de.ibm.com>, Kevin Hilman <khilman@linaro.org>, Christoph Hellwig <hch@infradead.org>, Michal Simek <michal.simek@xilinx.com>, Juri Lelli <juri.lelli@gmail.com>, Miklos Szeredi <mszeredi@suse.cz>, Dario Faggioli <raistlin@linux.it>, Markos Chandras <markos.chandras@imgtec.com>, James Hogan <james.hogan@imgtec.com>, Huacai Chen <chenhc@lemote.com>, Paul Burton <paul.burton@imgtec.com>, Viresh Kumar <viresh.kumar@linaro.org>, "J. Bruce Fields" <bfields@redhat.com>, Mike Frysinger <vapier@gentoo.org>, "David S. Miller" <davem@davemloft.net>, Daniel Borkmann <dborkman@redhat.com>, Steven Rostedt <rostedt@goodmis.org>, Rasmus Villemoes <linux@rasmusvillemoes.dk>, Tom Zanussi <tom.zanussi@linux.intel.com>, Andi Kleen <ak@linux.intel.com>, Mathieu Desnoyers <mathieu.desnoyers@efficios.com>, Rik van Riel <riel@redhat.com>, Daeseok Youn <daeseok.youn@gmail.com>, David Rientjes <rientjes@google.com>, Eric Paris <eparis@redhat.com>, Fabian Frederick <fabf@skynet.be>, Robin Holt <holt@sgi.com>, Dongsheng Yang <yangds.fnst@cn.fujitsu.com>, liguang <lig.fnst@cn.fujitsu.com>, Geert Uytterhoeven <geert@linux-m68k.org>, Alex Thorlton <athorlton@sgi.com>, "Eric W. Biederman" <ebiederm@xmission.com>, Josh Triplett <josh@joshtriplett.org>, linux-arm-kernel@lists.infradead.org, linux-mips@linux-mips.org, linux-fsdevel@vger.kernel.org, linux-api@vger.kernel.org, linux-arch@vger.kernel.org, linux-security-module@vger.kernel.org, x86@kernel.org
In-reply-to: <1402441314-7447-1-git-send-email-keescook@chromium.org>
List-archive: <http://www.linux-mips.org/archives/linux-mips/>
List-help: <mailto:ecartis@linux-mips.org?Subject=help>
List-id: linux-mips <linux-mips.eddie.linux-mips.org>
List-owner: <mailto:ralf@linux-mips.org>
List-post: <mailto:linux-mips@linux-mips.org>
List-software: Ecartis version 1.0.0
List-subscribe: <mailto:ecartis@linux-mips.org?subject=subscribe%20linux-mips>
List-unsubscribe: <mailto:ecartis@linux-mips.org?subject=unsubscribe%20linux-mips>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <1402441314-7447-1-git-send-email-keescook@chromium.org>
Sender: linux-mips-bounce@linux-mips.org
Wires up the new seccomp syscall.

Signed-off-by: Kees Cook <keescook@chromium.org>
---
 arch/arm/include/uapi/asm/unistd.h |    1 +
 arch/arm/kernel/calls.S            |    1 +
 2 files changed, 2 insertions(+)

diff --git a/arch/arm/include/uapi/asm/unistd.h 
b/arch/arm/include/uapi/asm/unistd.h
index ba94446c72d9..e21b4a069701 100644
--- a/arch/arm/include/uapi/asm/unistd.h
+++ b/arch/arm/include/uapi/asm/unistd.h
@@ -409,6 +409,7 @@
 #define __NR_sched_setattr             (__NR_SYSCALL_BASE+380)
 #define __NR_sched_getattr             (__NR_SYSCALL_BASE+381)
 #define __NR_renameat2                 (__NR_SYSCALL_BASE+382)
+#define __NR_seccomp                   (__NR_SYSCALL_BASE+383)
 
 /*
  * This may need to be greater than __NR_last_syscall+1 in order to
diff --git a/arch/arm/kernel/calls.S b/arch/arm/kernel/calls.S
index 8f51bdcdacbb..bea85f97f363 100644
--- a/arch/arm/kernel/calls.S
+++ b/arch/arm/kernel/calls.S
@@ -392,6 +392,7 @@
 /* 380 */      CALL(sys_sched_setattr)
                CALL(sys_sched_getattr)
                CALL(sys_renameat2)
+               CALL(sys_seccomp)
 #ifndef syscalls_counted
 .equ syscalls_padding, ((NR_syscalls + 3) & ~3) - NR_syscalls
 #define syscalls_counted
-- 
1.7.9.5


<Prev in Thread] Current Thread [Next in Thread>