seccomp: allow mode setting across threads
authorKees Cook <keescook@chromium.org>
Fri, 27 Jun 2014 22:01:35 +0000 (15:01 -0700)
committerJP Abgrall <jpa@google.com>
Tue, 7 Oct 2014 23:42:34 +0000 (16:42 -0700)
commitc852ef778224ecf5fe995d74ad96087038778bca
treef317901d72a453cdf517c91b65ac6f130230fe7d
parent61b6b882a0abfeb627d25a069cfa1d232b84c8eb
seccomp: allow mode setting across threads

This changes the mode setting helper to allow threads to change the
seccomp mode from another thread. We must maintain barriers to keep
TIF_SECCOMP synchronized with the rest of the seccomp state.

Signed-off-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Oleg Nesterov <oleg@redhat.com>
Reviewed-by: Andy Lutomirski <luto@amacapital.net>
Conflicts:
kernel/seccomp.c
kernel/seccomp.c