Re: [PATCH mm-unstable v1 0/2] Track pages allocated for struct

From: Matthew Wilcox
Date: Fri Nov 01 2024 - 11:54:40 EST


On Thu, Oct 31, 2024 at 04:06:04PM -0700, Andrew Morton wrote:
> Possibly dumb question: can we switch swap_cgroup_prepare to kmalloc()
> (or kmem-cache_alloc()) and use slab's accounting to satisfy this
> requirement?

It looks to me like a bad reimplemention of vmalloc(). It looks like
this code used to make more sense once upon a time, but now it's really
just vmalloc(). Or did I miss something?