aboutsummaryrefslogtreecommitdiffstats
path: root/mm/slub.c
diff options
context:
space:
mode:
Diffstat (limited to 'mm/slub.c')
-rw-r--r--mm/slub.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/mm/slub.c b/mm/slub.c
index c9c12ac79613..d379b782fc83 100644
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -217,7 +217,7 @@ struct track {
217 217
218enum track_item { TRACK_ALLOC, TRACK_FREE }; 218enum track_item { TRACK_ALLOC, TRACK_FREE };
219 219
220#if defined(CONFIG_SYSFS) && defined(CONFIG_SLUB_DEBUG) 220#ifdef CONFIG_SLUB_DEBUG
221static int sysfs_slab_add(struct kmem_cache *); 221static int sysfs_slab_add(struct kmem_cache *);
222static int sysfs_slab_alias(struct kmem_cache *, const char *); 222static int sysfs_slab_alias(struct kmem_cache *, const char *);
223static void sysfs_slab_remove(struct kmem_cache *); 223static void sysfs_slab_remove(struct kmem_cache *);
@@ -3247,7 +3247,7 @@ void *__kmalloc_node_track_caller(size_t size, gfp_t gfpflags,
3247 return slab_alloc(s, gfpflags, node, caller); 3247 return slab_alloc(s, gfpflags, node, caller);
3248} 3248}
3249 3249
3250#if (defined(CONFIG_SYSFS) && defined(CONFIG_SLUB_DEBUG)) || defined(CONFIG_SLABINFO) 3250#ifdef CONFIG_SLUB_DEBUG
3251static unsigned long count_partial(struct kmem_cache_node *n, 3251static unsigned long count_partial(struct kmem_cache_node *n,
3252 int (*get_count)(struct page *)) 3252 int (*get_count)(struct page *))
3253{ 3253{
@@ -3276,9 +3276,7 @@ static int count_free(struct page *page)
3276{ 3276{
3277 return page->objects - page->inuse; 3277 return page->objects - page->inuse;
3278} 3278}
3279#endif
3280 3279
3281#if defined(CONFIG_SYSFS) && defined(CONFIG_SLUB_DEBUG)
3282static int validate_slab(struct kmem_cache *s, struct page *page, 3280static int validate_slab(struct kmem_cache *s, struct page *page,
3283 unsigned long *map) 3281 unsigned long *map)
3284{ 3282{