diff options
author | Christoph Lameter <clameter@engr.sgi.com> | 2005-11-14 03:06:47 +0300 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-11-14 05:14:12 +0300 |
commit | 50c85a19e7b3928b5b5188524c44ffcbacdd4e35 (patch) | |
tree | a886792eba2e11615c3846bc6b1c77c41ce6dda0 /mm | |
parent | 065d41cb269e9debb18c6d5052e4de1088ae3d8f (diff) | |
download | linux-50c85a19e7b3928b5b5188524c44ffcbacdd4e35.tar.xz |
[PATCH] slab: remove alloc_pages() calls
The slab allocator never uses alloc_pages since kmem_getpages() is always
called with a valid nodeid. Remove the branch and the code from
kmem_getpages()
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Cc: Manfred Spraul <manfred@colorfullife.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'mm')
-rw-r--r-- | mm/slab.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/mm/slab.c b/mm/slab.c index 15d25ae5b686..e5ec26e0c460 100644 --- a/mm/slab.c +++ b/mm/slab.c @@ -1205,11 +1205,7 @@ static void *kmem_getpages(kmem_cache_t *cachep, gfp_t flags, int nodeid) int i; flags |= cachep->gfpflags; - if (likely(nodeid == -1)) { - page = alloc_pages(flags, cachep->gfporder); - } else { - page = alloc_pages_node(nodeid, flags, cachep->gfporder); - } + page = alloc_pages_node(nodeid, flags, cachep->gfporder); if (!page) return NULL; addr = page_address(page); |