seccomp: Lift wait_queue into struct seccomp_filter
authorChristian Brauner <christian.brauner@ubuntu.com>
Mon, 1 Jun 2020 18:50:07 +0000 (11:50 -0700)
committerKees Cook <keescook@chromium.org>
Fri, 10 Jul 2020 23:01:51 +0000 (16:01 -0700)
commit76194c4e830d570d9e369d637bb907591d2b3111
treef309b4a62abc68b2c0d48d27210770e8b345a9cd
parent3a15fb6ed92cb32b0a83f406aa4a96f28c9adbc3
seccomp: Lift wait_queue into struct seccomp_filter

Lift the wait_queue from struct notification into struct seccomp_filter.
This is cleaner overall and lets us avoid having to take the notifier
mutex in the future for EPOLLHUP notifications since we need to neither
read nor modify the notifier specific aspects of the seccomp filter. In
the exit path I'd very much like to avoid having to take the notifier mutex
for each filter in the task's filter hierarchy.

Cc: Tycho Andersen <tycho@tycho.ws>
Cc: Kees Cook <keescook@chromium.org>
Cc: Matt Denton <mpdenton@google.com>
Cc: Sargun Dhillon <sargun@sargun.me>
Cc: Jann Horn <jannh@google.com>
Cc: Chris Palmer <palmer@google.com>
Cc: Aleksa Sarai <cyphar@cyphar.com>
Cc: Robert Sesek <rsesek@google.com>
Cc: Jeffrey Vander Stoep <jeffv@google.com>
Cc: Linux Containers <containers@lists.linux-foundation.org>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
Signed-off-by: Kees Cook <keescook@chromium.org>
kernel/seccomp.c