aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorVivek Goyal <vgoyal@in.ibm.com>2005-06-25 17:57:51 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-06-25 19:24:48 -0400
commit8a9190853c34289d9181acd9c620c76143bf88ca (patch)
tree449d3fcc0dea0f9eef321a9c373db342ecdbf387 /arch
parent3d345e3fc9e9177deb7c82e5c79e32d77eb63cce (diff)
[PATCH] kexec: reserve Bootmem fix for booting nondefault location kernel
This patch fixes a problem with reserving memory during boot up of a kernel built for non-default location. Currently boot memory allocator reserves the memory required by kernel image, boot allocaotor bitmap etc. It assumes that kernel is loaded at 1MB (HIGH_MEMORY hard coded to 1024*1024). But kernel can be built for non-default locatoin, hence existing hardcoding will lead to reserving unnecessary memory. This patch fixes it. Signed-off-by: Vivek Goyal <vgoyal@in.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/i386/kernel/setup.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/i386/kernel/setup.c b/arch/i386/kernel/setup.c
index f1ad9fdeaad8..6337157f5df3 100644
--- a/arch/i386/kernel/setup.c
+++ b/arch/i386/kernel/setup.c
@@ -1124,8 +1124,8 @@ void __init setup_bootmem_allocator(void)
1124 * the (very unlikely) case of us accidentally initializing the 1124 * the (very unlikely) case of us accidentally initializing the
1125 * bootmem allocator with an invalid RAM area. 1125 * bootmem allocator with an invalid RAM area.
1126 */ 1126 */
1127 reserve_bootmem(HIGH_MEMORY, (PFN_PHYS(min_low_pfn) + 1127 reserve_bootmem(__PHYSICAL_START, (PFN_PHYS(min_low_pfn) +
1128 bootmap_size + PAGE_SIZE-1) - (HIGH_MEMORY)); 1128 bootmap_size + PAGE_SIZE-1) - (__PHYSICAL_START));
1129 1129
1130 /* 1130 /*
1131 * reserve physical page 0 - it's a special BIOS page on many boxes, 1131 * reserve physical page 0 - it's a special BIOS page on many boxes,