projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f899b0a
)
mm: don't drop a partial page in a zone's memory map size
author
Johannes Weiner
<
[email protected]
>
Fri, 23 May 2008 20:04:21 +0000
(13:04 -0700)
committer
Linus Torvalds
<
[email protected]
>
Sat, 24 May 2008 16:56:07 +0000
(09:56 -0700)
In a zone's present pages number, account for all pages occupied by the
memory map, including a partial.
Signed-off-by: Johannes Weiner <
[email protected]
>
Cc: KAMEZAWA Hiroyuki <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
mm/page_alloc.c
patch
|
blob
|
history
diff --git
a/mm/page_alloc.c
b/mm/page_alloc.c
index 63835579323a7ca70722154f5b3e6560872da409..035300299f94d8a2fdd744ae2a03ff94ea873522 100644
(file)
--- a/
mm/page_alloc.c
+++ b/
mm/page_alloc.c
@@
-3378,7
+3378,8
@@
static void __paginginit free_area_init_core(struct pglist_data *pgdat,
* is used by this zone for memmap. This affects the watermark
* and per-cpu initialisations
*/
- memmap_pages = (size * sizeof(struct page)) >> PAGE_SHIFT;
+ memmap_pages =
+ PAGE_ALIGN(size * sizeof(struct page)) >> PAGE_SHIFT;
if (realsize >= memmap_pages) {
realsize -= memmap_pages;
printk(KERN_DEBUG