Re: [PATCH v5 11/17] perf: Simplify get_perf_callchain() user logic

From: Steven Rostedt
Date: Thu Apr 24 2025 - 13:45:41 EST


On Thu, 24 Apr 2025 13:42:16 -0400
Mathieu Desnoyers <mathieu.desnoyers@xxxxxxxxxxxx> wrote:

> The case I'd be careful about is if the code can nest over exit_mm()
> (e.g. interrupt) after it sets current->mm = NULL.

Then probably we should always check if current->mm is non-NULL before
using it then, and not rely on just task->flags.

-- Steve