Re: [PATCH slab/for-next v2 08/14] powerpc/mm: specify SLAB_MAY_ACCOUNT for pgtable caches

From: Hao Li

Date: Thu Dec 03 2026 - 09:55:54 EST


On Wed, Nov 25, 2026 at 09:37:09PM +0000, Harry Yoo (Meta) wrote:
> User page tables are allocated from PGT_CACHE() with
> pgtable_gfp_flags(), which adds __GFP_ACCOUNT for non-kernel mms.
> Specify SLAB_MAY_ACCOUNT when the object may be charged to a memcg.
> __GFP_ACCOUNT without SLAB_MAY_ACCOUNT will not be allowed.
>
> Path: copy_process() -> mm_init() -> pgd_alloc()
> -> kmem_cache_alloc(PGT_CACHE(PGD_INDEX_SIZE),
> pgtable_gfp_flags(mm, GFP_KERNEL))
>
> Cc: Madhavan Srinivasan <maddy@xxxxxxxxxxxxx>
> Cc: Michael Ellerman <mpe@xxxxxxxxxxxxxx>
> Cc: Nicholas Piggin <npiggin@xxxxxxxxx>
> Cc: "Christophe Leroy (CS GROUP)" <chleroy@xxxxxxxxxx>
> Cc: linuxppc-dev@xxxxxxxxxxxxxxxx
> Signed-off-by: Harry Yoo (Meta) <harry@xxxxxxxxxx>
> ---
> arch/powerpc/mm/init-common.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)

Looks good to me.
Reviewed-by: Hao Li <hao.li@xxxxxxxxx>

--
Thanks,
Hao