Re: [PATCH v2 3/8] mm: move anon-exclusive batch helper to mm.h
From: Barry Song
Date: Wed Sep 02 2026 - 02:33:24 EST
On Tue, Sep 1, 2026 at 2:24 PM Dev Jain <dev.jain@xxxxxxx> wrote:
[...]
> >
> > Hi Dev,
> >
> > I really don't want everything to become a top-level header
> > file. If these are only mm-internal things, could we move them
> > to mm/internal.h or another more appropriate header?
>
> What do you suggest? I had it in mm/internal.h initially, but
> because I had to use the helper this time in patch 4, I couldn't
> do that. The helper will now be used by mprotect.c, rmap.c and
> rmap.h.
>
> I can keep it in rmap.h and make mprotect.c include rmap.h too.
I’d vote for this approach until we find a better one :-)
`include/linux/mm.h` is already way, way too long.
Best Regards
Barry