Re: [PATCH v5] seccomp: restore knotif->state when SECCOMP_ADDFD_FLAG_SEND is interrupted

From: Kees Cook

Date: Tue Sep 22 2026 - 00:35:23 EST


On Tue, 22 Sep 2026 02:32:04 +0000, Hui Peng wrote:
> In seccomp_notify_addfd(), when SECCOMP_ADDFD_FLAG_SEND is set in
> addfd.flags, knotif->state is optimistically transitioned from
> SECCOMP_NOTIFY_SENT to SECCOMP_NOTIFY_REPLIED before waking the tracee
> and waiting on kaddfd.completion:
>
> if (addfd.flags & SECCOMP_ADDFD_FLAG_SEND) {
> knotif->state = SECCOMP_NOTIFY_REPLIED;
> ...
> }
>
> [...]

I renamed the empty signal handler and added a comment, but otherwise,
applied to for-next/seccomp, thanks!

[1/1] seccomp: restore knotif->state when SECCOMP_ADDFD_FLAG_SEND is interrupted
https://git.kernel.org/kees/c/832b9b176be0

Take care,

--
Kees Cook