summaryrefslogtreecommitdiffstats
path: root/mm/util.c
diff options
context:
space:
mode:
authorVladimir Davydov <vdavydov@parallels.com>2014-04-08 00:39:24 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2014-04-08 01:36:12 +0200
commit5722d094ad2b56fa2c1cb3adaf40071a55bbf242 (patch)
treefbae9cdc8bf4d92d2ac268cf761b5f25c5ad6ef9 /mm/util.c
parentmemcg, slab: never try to merge memcg caches (diff)
downloadlinux-5722d094ad2b56fa2c1cb3adaf40071a55bbf242.tar.xz
linux-5722d094ad2b56fa2c1cb3adaf40071a55bbf242.zip
memcg, slab: cleanup memcg cache creation
This patch cleans up the memcg cache creation path as follows: - Move memcg cache name creation to a separate function to be called from kmem_cache_create_memcg(). This allows us to get rid of the mutex protecting the temporary buffer used for the name formatting, because the whole cache creation path is protected by the slab_mutex. - Get rid of memcg_create_kmem_cache(). This function serves as a proxy to kmem_cache_create_memcg(). After separating the cache name creation path, it would be reduced to a function call, so let's inline it. Signed-off-by: Vladimir Davydov <vdavydov@parallels.com> Cc: Michal Hocko <mhocko@suse.cz> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: David Rientjes <rientjes@google.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: Glauber Costa <glommer@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/util.c')
0 files changed, 0 insertions, 0 deletions