]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit - mm/slub.c
slub: Optimize deactivate_slab()
authorChengming Zhou <zhouchengming@bytedance.com>
Thu, 2 Nov 2023 03:23:28 +0000 (03:23 +0000)
committerVlastimil Babka <vbabka@suse.cz>
Tue, 5 Dec 2023 09:35:49 +0000 (10:35 +0100)
commit00eb60c28815e22690834b2e3951ded0cd300b8d
treee02bcf650008934d2ff59456a85b571ec2a9ab57
parent8cd3fa428b56352beaa38df756c1d3f1556f5514
slub: Optimize deactivate_slab()

Since the introduce of unfrozen slabs on cpu partial list, we don't
need to synchronize the slab frozen state under the node list_lock.

The caller of deactivate_slab() and the caller of __slab_free() won't
manipulate the slab list concurrently.

So we can get node list_lock in the last stage if we really need to
manipulate the slab list in this path.

Signed-off-by: Chengming Zhou <zhouchengming@bytedance.com>
Reviewed-by: Vlastimil Babka <vbabka@suse.cz>
Tested-by: Hyeonggon Yoo <42.hyeyoo@gmail.com>
Reviewed-by: Hyeonggon Yoo <42.hyeyoo@gmail.com>
Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
mm/slub.c