Re: [PATCH] x86: fix location of comment about pgd_list

From: Brendan Jackman

Date: Wed Mar 11 2026 - 13:18:33 EST


On Wed Mar 11, 2026 at 4:39 PM UTC, Dave Hansen wrote:
> On 3/11/26 07:04, Brendan Jackman wrote:
>> This venerable comment got detached from its context when the code moved
>> in commit 394158559d4c ("x86: move all the pgd_list handling to one
>> place"). Put it back next to that code.
>
> Shouldn't the comment about the data structure be on the *data*
> *structure*, not the code?
>
> LIST_HEAD(pgd_list);
>
> ?

Yep, you're right.

>
> But either way, I think the comment should just be chopped down to
> something much smaller, maybe:
>
> /*
> * A list of all PGD pages. Mainly used to keep shared kernel
> * mapping page tables in sync. Needed because PGDs are private
> * to each process.
> */

Great, sounds good to me. I'll let this sit a little in case anyone has
other additions/corrections then post a v2.