]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[PATCH] x86_64: Don't try to put kernel page tables beyond ZONE_DMA32.
authorAndi Kleen <ak@suse.de>
Mon, 16 Jan 2006 00:56:51 +0000 (01:56 +0100)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 16 Jan 2006 19:27:59 +0000 (11:27 -0800)
For not fully explained reasons it broke mem=... on several setups.

Also minor cleanup.

Cc: axboe@suse.de
Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/x86_64/mm/init.c

index eca60125efc3b76a5e8145829f362f031757d35e..ef84106c1509b5d0b74b6f35d053ae0a95ee7c67 100644 (file)
@@ -262,19 +262,11 @@ static void __init find_early_table_space(unsigned long end)
        tables = round_up(puds * sizeof(pud_t), PAGE_SIZE) +
                 round_up(pmds * sizeof(pmd_t), PAGE_SIZE);
 
-       /* Put page tables beyond the DMA zones if possible.
-          RED-PEN might be better to spread them out more over
-          memory to avoid hotspots */
-       if (end > MAX_DMA32_PFN<<PAGE_SHIFT)
-               start = MAX_DMA32_PFN << PAGE_SHIFT;
-       else if (end > MAX_DMA_PFN << PAGE_SHIFT)
-               start = MAX_DMA_PFN << PAGE_SHIFT;
-       else
-               start = 0x8000;
-
-       table_start = find_e820_area(start, end, tables);
-       if (table_start == -1)
-               table_start = find_e820_area(0x8000, end, tables);
+       /* RED-PEN putting page tables only on node 0 could
+          cause a hotspot and fill up ZONE_DMA. The page tables
+          need roughly 0.5KB per GB. */
+       start = 0x8000;
+       table_start = find_e820_area(start, end, tables);
        if (table_start == -1UL)
                panic("Cannot find space for the kernel page tables");