]> err.no Git - linux-2.6/blobdiff - include/linux/slub_def.h
Merge branch 'for-2.6.24' of master.kernel.org:/pub/scm/linux/kernel/git/galak/powerp...
[linux-2.6] / include / linux / slub_def.h
index 92e10cf6d0e848ef39379fd38f4a3e52503bf3a5..40801e754afb48430e3af7c59497b5726e298250 100644 (file)
@@ -16,8 +16,8 @@ struct kmem_cache_cpu {
        struct page *page;
        int node;
        unsigned int offset;
-       /* Lots of wasted space */
-} ____cacheline_aligned_in_smp;
+       unsigned int objsize;
+};
 
 struct kmem_cache_node {
        spinlock_t list_lock;   /* Protect partial list and nr_partial */
@@ -49,7 +49,7 @@ struct kmem_cache {
        /* Allocation and freeing of slabs */
        int objects;            /* Number of objects in slab */
        int refcount;           /* Refcount for slab cache destroy */
-       void (*ctor)(void *, struct kmem_cache *, unsigned long);
+       void (*ctor)(struct kmem_cache *, void *);
        int inuse;              /* Offset to metadata */
        int align;              /* Alignment */
        const char *name;       /* Name (only for display!) */
@@ -62,7 +62,11 @@ struct kmem_cache {
        int defrag_ratio;
        struct kmem_cache_node *node[MAX_NUMNODES];
 #endif
-       struct kmem_cache_cpu cpu_slab[NR_CPUS];
+#ifdef CONFIG_SMP
+       struct kmem_cache_cpu *cpu_slab[NR_CPUS];
+#else
+       struct kmem_cache_cpu cpu_slab;
+#endif
 };
 
 /*