From: sashiko-bot@kernel.org
To: "Daehyeon Ko" <4ncienth@gmail.com>
Cc: linux-perf-users@vger.kernel.org
Subject: Re: [PATCH] perf/core: Close owner-list publication race with remove-on-exec
Date: Thu, 15 Oct 2026 12:45:30 +0000 [thread overview]
Message-ID: <sashiko-outbox-172858@kernel.org> (raw)
In-Reply-To: <20261015123416.795008-1-4ncienth@gmail.com>
> perf_event_open() makes a user event visible in the target context before
> adding owner_entry to the opener's perf_event_list. For a remote task, it
> also releases exec_update_lock before adding the list node.
>
> A concurrent target exec can therefore process a remove_on_exec event in
> this interval. perf_remove_from_owner() sees the published non-NULL owner
> and calls list_del_init() on the zero-allocated, but not initialized,
> owner_entry. DEBUG_LIST reports a NULL-link list corruption and can panic
> the kernel.
>
> If list corruption reporting is non-fatal, list_del_init() initializes the
> node and clears the owner. The open path then adds the ownerless event to
> the opener's list. Closing the returned file descriptor frees the event
> while it remains linked, and the next owner-list insertion accesses the
> freed object.
> [ ... ]
>
> Fixes: 2e498d0a74e5 ("perf: Add support for event removal on exec")
> Cc: stable@vger.kernel.org
> Assisted-by: LLM
> Signed-off-by: Daehyeon Ko <4ncienth@gmail.com>
Sashiko has reviewed this patch and found no issues. It looks great!
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261015123416.795008-1-4ncienth@gmail.com?part=1
prev parent reply other threads:[~2026-10-15 12:45 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-15 12:34 [PATCH] perf/core: Close owner-list publication race with remove-on-exec Daehyeon Ko
2026-10-15 12:45 ` sashiko-bot [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=sashiko-outbox-172858@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=4ncienth@gmail.com \
--cc=linux-perf-users@vger.kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.