diff options
author | Christoph Lameter <clameter@engr.sgi.com> | 2005-11-13 19:06:47 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-11-13 21:14:12 -0500 |
commit | 50c85a19e7b3928b5b5188524c44ffcbacdd4e35 (patch) | |
tree | a886792eba2e11615c3846bc6b1c77c41ce6dda0 | |
parent | 065d41cb269e9debb18c6d5052e4de1088ae3d8f (diff) |
[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>
-rw-r--r-- | mm/slab.c | 6 |
1 files changed, 1 insertions, 5 deletions
@@ -1205,11 +1205,7 @@ static void *kmem_getpages(kmem_cache_t *cachep, gfp_t flags, int nodeid) | |||
1205 | int i; | 1205 | int i; |
1206 | 1206 | ||
1207 | flags |= cachep->gfpflags; | 1207 | flags |= cachep->gfpflags; |
1208 | if (likely(nodeid == -1)) { | 1208 | page = alloc_pages_node(nodeid, flags, cachep->gfporder); |
1209 | page = alloc_pages(flags, cachep->gfporder); | ||
1210 | } else { | ||
1211 | page = alloc_pages_node(nodeid, flags, cachep->gfporder); | ||
1212 | } | ||
1213 | if (!page) | 1209 | if (!page) |
1214 | return NULL; | 1210 | return NULL; |
1215 | addr = page_address(page); | 1211 | addr = page_address(page); |