Re: [PATCH v2 1/2] uprobes: skip mappings not managed by core mm
From: Oleg Nesterov
Date: Thu Dec 03 2026 - 08:53:54 EST
On 12/03, David Hildenbrand (Arm) wrote:
>
> Further, since commit 83e3dc9a5d4d ("uprobes: simplify
> find_active_uprobe_rcu() VMA checks"), the uprobe lookups no longer check
> the VMA flags, assuming that a trap instruction in a VMA implies that we
> installed a breakpoint there. But we never install breakpoints into
> some VMAs, such as MAP_SHARED mappings. If the file itself contains a
> trap instruction at the offset of a uprobe, executing it in such a VMA
> will find the uprobe, and instead of delivering SIGTRAP, > we let the task
> loop on that trap instruction forever.
OK, I guess this can really happen if prepare_uprobe() wasn't called...
LGTM,
Acked-by: Oleg Nesterov <oleg@xxxxxxxxxx>