diff options
author | H. Peter Anvin <hpa@zytor.com> | 2009-05-11 18:56:08 -0400 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2009-05-11 20:44:39 -0400 |
commit | 37ba7ab5e33cebc25c68fffe33e9f21e7c2014e8 (patch) | |
tree | 006ba60fcd29b8fdee844ee6d90b85104a254d0d /arch/x86/boot/compressed/head_32.S | |
parent | 99aa45595f45603526513d5e29fc00f8afbf3913 (diff) |
x86, boot: make kernel_alignment adjustable; new bzImage fields
Make the kernel_alignment field adjustable; this allows us to set it
to a large value (intended to be 16 MB to avoid ZONE_DMA contention,
memory holes and other weirdness) while a smart bootloader can still
force a loading at a lesser alignment if absolutely necessary.
Also export pref_address (preferred loading address, corresponding to
the link-time address) and init_size, the total amount of linear
memory the kernel will require during initialization.
[ Impact: allows better kernel placement, gives bootloader more info ]
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'arch/x86/boot/compressed/head_32.S')
-rw-r--r-- | arch/x86/boot/compressed/head_32.S | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/arch/x86/boot/compressed/head_32.S b/arch/x86/boot/compressed/head_32.S index 2b8e0dfa4b27..75e4f001e706 100644 --- a/arch/x86/boot/compressed/head_32.S +++ b/arch/x86/boot/compressed/head_32.S | |||
@@ -69,8 +69,11 @@ ENTRY(startup_32) | |||
69 | 69 | ||
70 | #ifdef CONFIG_RELOCATABLE | 70 | #ifdef CONFIG_RELOCATABLE |
71 | movl %ebp, %ebx | 71 | movl %ebp, %ebx |
72 | addl $(CONFIG_PHYSICAL_ALIGN - 1), %ebx | 72 | movl BP_kernel_alignment(%esi), %eax |
73 | andl $(~(CONFIG_PHYSICAL_ALIGN - 1)), %ebx | 73 | decl %eax |
74 | addl %eax, %ebx | ||
75 | notl %eax | ||
76 | andl %eax, %ebx | ||
74 | #else | 77 | #else |
75 | movl $LOAD_PHYSICAL_ADDR, %ebx | 78 | movl $LOAD_PHYSICAL_ADDR, %ebx |
76 | #endif | 79 | #endif |