aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/slub_def.h
diff options
context:
space:
mode:
authorChristoph Lameter <clameter@sgi.com>2007-07-17 07:03:24 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-07-17 13:23:01 -0400
commit0c710013200e72b5e0bc680ff4ec6bdac53c5ce8 (patch)
tree160c44e8036e9ea65e7863271f925954d05ed091 /include/linux/slub_def.h
parentd07dbea46405b37d59495eb4de9d1056dcfb7c6d (diff)
SLUB: add some more inlines and #ifdef CONFIG_SLUB_DEBUG
Add #ifdefs around data structures only needed if debugging is compiled into SLUB. Add inlines to small functions to reduce code size. Signed-off-by: Christoph Lameter <clameter@sgi.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/slub_def.h')
-rw-r--r--include/linux/slub_def.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/slub_def.h b/include/linux/slub_def.h
index 579b0a22858e..bae11111458f 100644
--- a/include/linux/slub_def.h
+++ b/include/linux/slub_def.h
@@ -16,7 +16,9 @@ struct kmem_cache_node {
16 unsigned long nr_partial; 16 unsigned long nr_partial;
17 atomic_long_t nr_slabs; 17 atomic_long_t nr_slabs;
18 struct list_head partial; 18 struct list_head partial;
19#ifdef CONFIG_SLUB_DEBUG
19 struct list_head full; 20 struct list_head full;
21#endif
20}; 22};
21 23
22/* 24/*
@@ -44,7 +46,9 @@ struct kmem_cache {
44 int align; /* Alignment */ 46 int align; /* Alignment */
45 const char *name; /* Name (only for display!) */ 47 const char *name; /* Name (only for display!) */
46 struct list_head list; /* List of slab caches */ 48 struct list_head list; /* List of slab caches */
49#ifdef CONFIG_SLUB_DEBUG
47 struct kobject kobj; /* For sysfs */ 50 struct kobject kobj; /* For sysfs */
51#endif
48 52
49#ifdef CONFIG_NUMA 53#ifdef CONFIG_NUMA
50 int defrag_ratio; 54 int defrag_ratio;