[PATCH v1 02/11] mm/slub: zero page->private when freeing pages
Zi Yan
ziy at nvidia.com
Mon Feb 23 14:26:32 AEDT 2026
This prepares for upcoming checks in page freeing path.
Signed-off-by: Zi Yan <ziy at nvidia.com>
Cc: Vlastimil Babka <vbabka at kernel.org>
Cc: Christoph Lameter <cl at gentwo.org>
Cc: David Rientjes <rientjes at google.com>
Cc: Roman Gushchin <roman.gushchin at linux.dev>
Cc: Harry Yoo <harry.yoo at oracle.com>
Cc: linux-mm at kvack.org
---
mm/slub.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/mm/slub.c b/mm/slub.c
index 865bc050f654..012c71e7b488 100644
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -3511,6 +3511,7 @@ static void __free_slab(struct kmem_cache *s, struct slab *slab, bool allow_spin
__slab_clear_pfmemalloc(slab);
page->mapping = NULL;
+ set_page_private(page, 0);
__ClearPageSlab(page);
mm_account_reclaimed_pages(pages);
unaccount_slab(slab, order, s, allow_spin);
--
2.51.0
More information about the Linux-erofs
mailing list