lkml.org 
[lkml]   [2006]   [Aug]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [RFC] ELF Relocatable x86 and x86_64 bzImages
Date
Horms <horms@verge.net.au> writes:

> On Mon, Aug 07, 2006 at 09:32:23PM -0700, H. Peter Anvin wrote:
>> Horms wrote:
>> >
>> >I also agree that it is non-intitive. But I wonder if a cleaner
>> >fix would be to remove CONFIG_PHYSICAL_START all together. Isn't
>> >it just a work around for the kernel not being relocatable, or
>> >are there uses for it that relocation can't replace?
>> >
>>
>> Yes, booting with the 2^n existing bootloaders.
>
> Ok, I must be confused then. I though CONFIG_PHYSICAL_START was
> introduced in order to allow an alternative address to be provided for
> kdump, and that previously it was hard-coded to some
> architecture-specific value.
>
> What I was really getting as is if it needs to be configurable at
> compile time or not. Obviously there needs to be some sane default
> regardless.

CONFIG_PHYSICAL_START has had 2 uses.
1) To allow a kernel to run a completely different address for use
with kexec on panic.
2) To allow the kernel to be better aligned for better performance.

For maintenance reasons I propose we introduce CONFIG_PHYSICAL_ALIGN.
Which will round our load address up to the nearest aligned address
and run the kernel there. That is roughly what I am doing on x86_64
at this point.

s/CONFIG_PHYSICAL_START/CONFIG_PHYSICAL_ALIGN/ gives me well defined
behavior and allows the alignment optimization without getting into
weird semantics.

Before CONFIG_PHYSICAL_START we _always_ ran the arch/i386 kernel
where it was loaded and I assumed we always would. Since people have
realized better aligned kernels can run better this assumption became
false. Going to CONFIG_PHYSICAL_ALIGN allows us to return to the
simple assumption of always running the kernel where it is loaded
modulo a little extra alignment.

Eric
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-08-08 09:27    [W:1.125 / U:0.444 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site