Re: Patch to make the head.S-must-be-first-in-vmlinux order explicit

From: Andi Kleen
Date: Thu Feb 23 2006 - 08:40:10 EST


On Thursday 23 February 2006 14:19, Arjan van de Ven wrote:
> This patch puts the code from head.S in a special .bootstrap.text
> section.
>
> I'm working on a patch to reorder the functions in the kernel (I'll post
> that later), but for x86-64 at least the kernel bootstrap requires that the
> head.S functions are on the very first page/pages of the kernel text. This
> is understandable since the bootstrap is complex enough already and not a
> problem at all, it just means they aren't allowed to be reordered. This
> patch puts these special functions into a separate section to document this,
> and to guarantee this in the light of possibly reordering the rest later.
>
> (So this patch doesn't fix a bug per se, but makes things more robust by
> making the order of these functions explicit)

I don't think the 64bit kernel code requires this actually (or at least
it shouldn't), but arch/x86_64/boot/compressed/head.S
seems to have the entry address hardcoded. Perhaps you can just change this
to pass in the right address?

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