Re: [PATCH v14 13/19] unwind_user: Enable archs that pass RA in a register
Steven Rostedt <[email protected]> Tue, 19 May 2026 08:42:22 -0400
| Newsgroups | dev.linux.lists.sashiko,org.kernel.vger.bpf |
|---|---|
| Message-ID | <[email protected]> |
On Tue, 19 May 2026 14:24:34 +0200 Jens Remus <[email protected]> wrote: > > How can this be triggered? Does it require an architecture to implement > > only partial sframe to trigger? > > On x86-64 it can be triggered from user space using forged .sframe that > incorrectly specifies no fixed RA offset and thus causes the common > unwind user (sframe) logic to recover RA from the RA register using > the dummy unwind_user_get_ra_reg(). OK, so if user space could trigger it via a invalid .sframe, I would do at most a pr_debug() (may not even need a 'once'), and remove that this task has an sframe. That is, as soon as a sframe is discovered to be corrupted, it should be discarded and never used after that. A print could be done just to inform the admin of what happened. And since the sframe would be removed, that prevents it from spamming the console, so the "once" isn't needed. We may want to show it for other applications. The print should state the comm and pid of the task that failed. -- Steve