Skip to content

Commit aee52ca

Browse files
Vladimir Davydovtorvalds
authored andcommitted
slub: remove kmemcg id from create_unique_id
This function is never called for memcg caches, because they are unmergeable, so remove the dead code. Signed-off-by: Vladimir Davydov <vdavydov@parallels.com> Cc: Michal Hocko <mhocko@suse.cz> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Christoph Lameter <cl@linux.com> Reviewed-by: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 9ef0a0f commit aee52ca

1 file changed

Lines changed: 0 additions & 6 deletions

File tree

‎mm/slub.c‎

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5128,12 +5128,6 @@ static char *create_unique_id(struct kmem_cache *s)
51285128
*p++ = '-';
51295129
p += sprintf(p, "%07d", s->size);
51305130

5131-
#ifdef CONFIG_MEMCG_KMEM
5132-
if (!is_root_cache(s))
5133-
p += sprintf(p, "-%08d",
5134-
memcg_cache_id(s->memcg_params->memcg));
5135-
#endif
5136-
51375131
BUG_ON(p > name + ID_STR_LENGTH - 1);
51385132
return name;
51395133
}

0 commit comments

Comments
 (0)