lkml.org 
[lkml]   [2011]   [Feb]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[tip:x86/mm] x86-64, numa: Allocate memnodemap under max_pfn_mapped
Commit-ID:  dbef7b56d2fc5115f26f72a0b080283bbf972cab
Gitweb: http://git.kernel.org/tip/dbef7b56d2fc5115f26f72a0b080283bbf972cab
Author: Yinghai Lu <yinghai@kernel.org>
AuthorDate: Mon, 27 Dec 2010 16:48:08 -0800
Committer: H. Peter Anvin <hpa@linux.intel.com>
CommitDate: Wed, 29 Dec 2010 15:48:08 -0800

x86-64, numa: Allocate memnodemap under max_pfn_mapped

We need to access it right way, so make sure that it is mapped already.

Prepare to put page table on local node, and nodemap is used before that.

Signed-off-by: Yinghai Lu <yinghai@kernel.org>
LKML-Reference: <4D1933C8.7060105@kernel.org>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
---
arch/x86/mm/numa_64.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/x86/mm/numa_64.c b/arch/x86/mm/numa_64.c
index 7762a51..02d36ff 100644
--- a/arch/x86/mm/numa_64.c
+++ b/arch/x86/mm/numa_64.c
@@ -87,7 +87,7 @@ static int __init allocate_cachealigned_memnodemap(void)

addr = 0x8000;
nodemap_size = roundup(sizeof(s16) * memnodemapsize, L1_CACHE_BYTES);
- nodemap_addr = memblock_find_in_range(addr, max_pfn<<PAGE_SHIFT,
+ nodemap_addr = memblock_find_in_range(addr, get_max_mapped(),
nodemap_size, L1_CACHE_BYTES);
if (nodemap_addr == MEMBLOCK_ERROR) {
printk(KERN_ERR

\
 
 \ /
  Last update: 2011-02-16 09:53    [W:0.171 / U:1.104 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site