mm/sl[aou]b: Extract a common function for kmem_cache_destroy

kmem_cache_destroy does basically the same in all allocators.

Extract common code which is easy since we already have common mutex
handling.

Reviewed-by: Glauber Costa <glommer@parallels.com>
Signed-off-by: Christoph Lameter <cl@linux.com>
Signed-off-by: Pekka Enberg <penberg@kernel.org>
This commit is contained in:
Christoph Lameter
2012-09-04 23:18:33 +00:00
committed by Pekka Enberg
parent 7c9adf5a54
commit 945cf2b619
5 changed files with 49 additions and 75 deletions
+3
View File
@@ -30,4 +30,7 @@ extern struct list_head slab_caches;
struct kmem_cache *__kmem_cache_create(const char *name, size_t size,
size_t align, unsigned long flags, void (*ctor)(void *));
int __kmem_cache_shutdown(struct kmem_cache *);
void __kmem_cache_destroy(struct kmem_cache *);
#endif