aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/mm/init_64.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/arch/x86/mm/init_64.c b/arch/x86/mm/init_64.c
index 359e3afaaa6b..6eced2f10734 100644
--- a/arch/x86/mm/init_64.c
+++ b/arch/x86/mm/init_64.c
@@ -227,6 +227,7 @@ void __init cleanup_highmap(void)
227 227
228static unsigned long __initdata table_start; 228static unsigned long __initdata table_start;
229static unsigned long __meminitdata table_end; 229static unsigned long __meminitdata table_end;
230static unsigned long __meminitdata table_top;
230 231
231static __meminit void *alloc_low_page(unsigned long *phys) 232static __meminit void *alloc_low_page(unsigned long *phys)
232{ 233{
@@ -240,7 +241,7 @@ static __meminit void *alloc_low_page(unsigned long *phys)
240 return adr; 241 return adr;
241 } 242 }
242 243
243 if (pfn >= end_pfn) 244 if (pfn >= table_top)
244 panic("alloc_low_page: ran out of memory"); 245 panic("alloc_low_page: ran out of memory");
245 246
246 adr = early_ioremap(pfn * PAGE_SIZE, PAGE_SIZE); 247 adr = early_ioremap(pfn * PAGE_SIZE, PAGE_SIZE);
@@ -372,10 +373,10 @@ static void __init find_early_table_space(unsigned long end)
372 373
373 table_start >>= PAGE_SHIFT; 374 table_start >>= PAGE_SHIFT;
374 table_end = table_start; 375 table_end = table_start;
376 table_top = table_start + (tables >> PAGE_SHIFT);
375 377
376 early_printk("kernel direct mapping tables up to %lx @ %lx-%lx\n", 378 printk(KERN_DEBUG "kernel direct mapping tables up to %lx @ %lx-%lx\n",
377 end, table_start << PAGE_SHIFT, 379 end, table_start << PAGE_SHIFT, table_top << PAGE_SHIFT);
378 (table_start << PAGE_SHIFT) + tables);
379} 380}
380 381
381static void __init init_gbpages(void) 382static void __init init_gbpages(void)