]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
mm: remove reference to destructor in comment in calculate_sizes()
authorWilliam Kucharski <william.kucharski@oracle.com>
Tue, 21 Oct 2025 11:00:04 +0000 (05:00 -0600)
committerAndrew Morton <akpm@linux-foundation.org>
Wed, 22 Oct 2025 01:51:53 +0000 (18:51 -0700)
The commit that removed support for destructors from kmem_cache_alloc()
never removed the comment regarding destructors in the explanation of the
possible relocation of the free pointer in calculate_sizes().

Link: https://lkml.kernel.org/r/20251021110004.2209008-1-william.kucharski@oracle.com
Fixes: 20c2df83d25c ("mm: Remove slab destructors from kmem_cache_create().")
Signed-off-by: William Kucharski <william.kucharski@oracle.com>
Acked-by: Roman Gushchin <roman.gushchin@linux.dev>
Reviewed-by: Christoph Lameter (Ampere) <cl@gentwo.org>
Cc: David Rientjes <rientjes@google.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: Harry Yoo <harry.yoo@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/slub.c

index b7442015f64047e0f7215c5dbeccb90780440363..708848d3512c5dbde98ef2f589f84cde01812261 100644 (file)
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -7874,11 +7874,11 @@ static int calculate_sizes(struct kmem_cache_args *args, struct kmem_cache *s)
                 * permitted to overwrite the first word of the object on
                 * kmem_cache_free.
                 *
-                * This is the case if we do RCU, have a constructor or
-                * destructor, are poisoning the objects, or are
-                * redzoning an object smaller than sizeof(void *) or are
-                * redzoning an object with slub_debug_orig_size() enabled,
-                * in which case the right redzone may be extended.
+                * This is the case if we do RCU, have a constructor, are
+                * poisoning the objects, or are redzoning an object smaller
+                * than sizeof(void *) or are redzoning an object with
+                * slub_debug_orig_size() enabled, in which case the right
+                * redzone may be extended.
                 *
                 * The assumption that s->offset >= s->inuse means free
                 * pointer is outside of the object is used in the