Commit 9b83f355 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] don't allocate an extra page in vmalloc

From Marcus Alanen <marcus@infa.abo.fi>

vmalloc is allocating one more page than necessary.
parent e57c2ae2
......@@ -387,7 +387,7 @@ void *__vmalloc(unsigned long size, int gfp_mask, pgprot_t prot)
if (!area)
return NULL;
nr_pages = (size+PAGE_SIZE) >> PAGE_SHIFT;
nr_pages = size >> PAGE_SHIFT;
array_size = (nr_pages * sizeof(struct page *));
area->nr_pages = nr_pages;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment