Re: [PATCH V8 1/4] perf/core: Add PERF_SAMPLE_DATA_PAGE_SIZE

From: Dave Hansen
Date: Thu Oct 01 2020 - 09:49:40 EST


On 9/30/20 10:30 AM, Peter Zijlstra wrote:
> In general though; I think using ->active_mm is a mistake though. That
> code should be doing something like:
>
>
> mm = current->mm;
> if (!mm)
> mm = &init_mm;
>

I was hoping that using ->active_mm would give us the *actual* copy of
the page tables that's loaded in CR3 for kernel thraeds. But, there are
few if any practical advantages of doing that at the moment.

Using that ^ is fine with me.