[LinuxBIOS] Initram+XIP

Stefan Reinauer stepan at coresystems.de
Sat Oct 6 07:52:38 CEST 2007

* Jordan Crouse <jordan.crouse at amd.com> [071006 00:28]:
> This week I've been working with LinuxBIOSv3 to try to get over the XIP
> initram problem.  For those that tuning in late, here's the recap:
> There are some symbols that we use that we want to define once, and 
> use in different segments (such as printk). This is very easy to do
> for segments that are loaded and run at a particular location in memory,
> by passing in the symbol list from stage0 to LD through the -R command
> line option, from which LD figures the right relative offsets.
> The problem is, this is only easy if you know where your code is 
> executing, and pass the appropriate fu into LD.  For most systems,
> we need to run at least the initram segment in place on the ROM which
> are not always located at a known location - there can be multiple
> initram blocks, and LAR can put them anywhere it wishes.  Needless to
> say, this breaks things badly when we try to call functions in the bootblock
> with a relative offset that walks into the weeds.

I tried playing with the same thing and I came up with the following
hack (attachment) .. The big issue is it doesnt work like that yet. The
idea is to take the decision of the jump address from the
compiler+linker because we already know it.

Can something like this work a all?

coresystems GmbH • Brahmsstr. 16 • D-79104 Freiburg i. Br.
      Tel.: +49 761 7668825 • Fax: +49 761 7664613
Email: info at coresystems.dehttp://www.coresystems.de/
Registergericht: Amtsgericht Freiburg • HRB 7656
Geschäftsführer: Stefan Reinauer • Ust-IdNr.: DE245674866
-------------- next part --------------
A non-text attachment was scrubbed...
Name: reloc.diff
Type: text/x-patch
Size: 2510 bytes
Desc: not available
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20071006/f86067ba/attachment.diff>

More information about the coreboot mailing list