[PATCH 00/14] RFC: x86: relocatable kernel changes
H. Peter Anvin
h.peter.anvin at intel.com
Fri May 8 14:47:47 EDT 2009
Eric W. Biederman wrote:
>
> Perhaps we should have:
> init_size
> best start (As a 64bit field please)
> optimum align (Or we flip it around)
>
Thinking about this some more, I think you have a very good idea here.
Specifically, if we retcon the existing kernel_alignment field as
"preferred alignment" (ignoring the naming issue for a bit), we can set
that to 16 MB, which should give us correct behavior for all previously
existing bootloaders. Then we create a new "minimum alignment" field
that newer bootloaders can use to relax the alignment requirement -- all
the way down to 4K in the case of i386. We document this field
indicating that the bootloader should find the highest power of 2 <=
preferred alignment, but down to this number.
The preferred address field becomes a readonly, advisory field; with it
being readonly there aren't any funny issues with a strange loader
writing a 64-bit address for a kernel which can't handle it (64-bit
loading will still need substantial protocol changes, including how to
find the entry point.)
Does that work for you? That *should* address all your concerns, right?
-hpa
More information about the kexec
mailing list