mm/slab.c: remove redundant assignments for slab_state
[email protected]
maintainerPATCH 27/119 mm/slab.c: remove redundant assignments for slab_state
From: Oscar Salvador <[email protected]>
Subject: mm/slab.c: remove redundant assignments for slab_state
slab_state is being set to "UP" in create_kmalloc_caches(), and later on we set it again in kmem_cache_init_late(), but slab_state does not change in the meantime.
Remove the redundant assignment from kmem_cache_init_late().
And unless I overlooked anything, the same goes for "slab_state = FULL". slab_state is set to "FULL" in kmem_cache_init_late(), but it is later being set again in cpucache_init(), which gets called from do_initcall_level(). So remove the assignment from cpucache_init() as well.
Signed-off-by Oscar Salvador <[email protected]>
Cc Pekka Enberg <[email protected]>
Cc David Rientjes <[email protected]>
Cc Joonsoo Kim <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
mm/slab.c | 4 ---- 1 file changed, 4 deletions(-)
mm/slab.c renamed from mm/slab.c~mm-slab-remove-redundant-assignments-for-slab_state +0 -1
@@ -1316,8 +1316,6 @@ void __init kmem_cache_init_late(void) {struct kmem_cache *cachep; - slab_state =UP ;