[GIT PULL] seccomp updates for v6.6-rc1

From: Kees Cook
Date: Mon Aug 28 2023 - 14:16:29 EST


Hi Linus,

Please pull these seccomp updates for v6.6-rc1. These changes touch stuff
that doesn't normally look like things related to seccomp (sched, perf,
arm), but it is intentional. :) Each have been acked by maintainers and
have been in -next for a while.

Thanks!

-Kees

The following changes since commit fdf0eaf11452d72945af31804e2a1048ee1b574c:

Linux 6.5-rc2 (2023-07-16 15:10:37 -0700)

are available in the Git repository at:

https://git.kernel.org/pub/scm/linux/kernel/git/kees/linux.git tags/seccomp-v6.6-rc1

for you to fetch changes up to 46822860a5a9a5a558475d323a55c8aab0b54012:

seccomp: Add missing kerndoc notations (2023-08-17 12:32:15 -0700)

----------------------------------------------------------------
seccomp updates for v6.6-rc1

- Provide USER_NOTIFY flag for synchronous mode (Andrei Vagin, Peter
Oskolkov). This touches the scheduler and perf but has been Acked by
Peter Zijlstra.

- Fix regression in syscall skipping and restart tracing on arm32.
This touches arch/arm/ but has been Acked by Arnd Bergmann.

----------------------------------------------------------------
Andrei Vagin (5):
seccomp: don't use semaphore and wait_queue together
sched: add a few helpers to wake up tasks on the current cpu
seccomp: add the synchronous mode for seccomp_unotify
selftest/seccomp: add a new test for the sync mode of seccomp_user_notify
perf/benchmark: add a new benchmark for seccom_unotify

Kees Cook (4):
selftests/seccomp: Handle arm32 corner cases better
ARM: ptrace: Restore syscall restart tracing
ARM: ptrace: Restore syscall skipping for tracers
seccomp: Add missing kerndoc notations

Peter Oskolkov (1):
sched: add WF_CURRENT_CPU and externise ttwu

arch/arm/include/asm/syscall.h | 3 +
arch/arm/kernel/entry-common.S | 1 +
arch/arm/kernel/ptrace.c | 5 +-
include/linux/completion.h | 1 +
include/linux/swait.h | 2 +-
include/linux/wait.h | 3 +
include/uapi/linux/seccomp.h | 4 +
kernel/sched/completion.c | 26 ++--
kernel/sched/core.c | 5 +-
kernel/sched/fair.c | 4 +
kernel/sched/sched.h | 13 +-
kernel/sched/swait.c | 8 +-
kernel/sched/wait.c | 5 +
kernel/seccomp.c | 84 ++++++++++--
tools/arch/x86/include/uapi/asm/unistd_32.h | 3 +
tools/arch/x86/include/uapi/asm/unistd_64.h | 3 +
tools/perf/bench/Build | 1 +
tools/perf/bench/bench.h | 1 +
tools/perf/bench/sched-seccomp-notify.c | 178 ++++++++++++++++++++++++++
tools/perf/builtin-bench.c | 1 +
tools/testing/selftests/seccomp/seccomp_bpf.c | 67 +++++++++-
21 files changed, 384 insertions(+), 34 deletions(-)
create mode 100644 tools/perf/bench/sched-seccomp-notify.c

--
Kees Cook