summaryrefslogtreecommitdiffstats
path: root/include/linux/slub_def.h
diff options
context:
space:
mode:
authorChristoph Lameter <clameter@sgi.com>2008-02-14 14:21:32 -0800
committerChristoph Lameter <christoph@stapp.engr.sgi.com>2008-02-14 15:30:01 -0800
commitb7a49f0d4c34166ae84089d9f145cfaae1b0eec5 (patch)
tree716bd20c8b920511f032a42be78c0a523a17565d /include/linux/slub_def.h
parentdada123d99c241d1a45798a7c77bcf99c4968704 (diff)
downloadop-kernel-dev-b7a49f0d4c34166ae84089d9f145cfaae1b0eec5.zip
op-kernel-dev-b7a49f0d4c34166ae84089d9f145cfaae1b0eec5.tar.gz
slub: Determine gfpflags once and not every time a slab is allocated
Currently we determine the gfp flags to pass to the page allocator each time a slab is being allocated. Determine the bits to be set at the time the slab is created. Store in a new allocflags field and add the flags in allocate_slab(). Acked-by: Mel Gorman <mel@csn.ul.ie> Reviewed-by: Pekka Enberg <penberg@cs.helsinki.fi> Signed-off-by: Christoph Lameter <clameter@sgi.com>
Diffstat (limited to 'include/linux/slub_def.h')
-rw-r--r--include/linux/slub_def.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/slub_def.h b/include/linux/slub_def.h
index a849c47..98be113 100644
--- a/include/linux/slub_def.h
+++ b/include/linux/slub_def.h
@@ -71,6 +71,7 @@ struct kmem_cache {
/* Allocation and freeing of slabs */
int objects; /* Number of objects in slab */
+ gfp_t allocflags; /* gfp flags to use on each alloc */
int refcount; /* Refcount for slab cache destroy */
void (*ctor)(struct kmem_cache *, void *);
int inuse; /* Offset to metadata */
OpenPOWER on IntegriCloud