Re: [PATCH 06/12] mempolicy trivia: use pgoff_t in shared mempolicy tree

From: Matthew Wilcox
Date: Mon Sep 25 2023 - 18:38:44 EST


On Mon, Sep 25, 2023 at 11:31:40PM +0100, Matthew Wilcox wrote:
> On Mon, Sep 25, 2023 at 01:28:14AM -0700, Hugh Dickins wrote:
> > Prefer the more explicit "pgoff_t" to "unsigned long" when dealing with
> > a shared mempolicy tree. Delete confusing comment about pseudo mm vmas.
>
> Yes, with three quibbles

Actually, a fourth has occurred to me

> > struct sp_node {
> > struct rb_node nd;
> > - unsigned long start, end;
> > + pgoff_t start, end;
> > struct mempolicy *policy;
> > };

This data structure is unused outside mempolicy.c today, and you don't
add any. Perhaps we could move it from mempolicy.h to mempolicy.c?