This is a set of proposed changes for doing initram which are backward-compatible (and tested) on qemu. The change is to exploit the elf-parsing abilities of lar to better set up the initram files in LAR, and get away from worrying about potential gld bugs, now and in the future.
The change is to use the elf-parsing capabilities of LAR to parse the initram.o file, and create a valid LAR header with an entry value. This will fix the problems I am having on the ALIX 1C and probably allow it to boot. It also sets the text base of the .o to 0, instead of whatever wacky value gld is choosing, so all platforms will have the same value.
I would appreciate comments on this, and I wonder if we shouldn't just drop the "binary blob" initram immediately. I don't see a need for it at this point.
That said, this is backwards-compatible for now.
Note that we can next apply this to stage 2, and completely remove the dreaded "binary blobs" from the LAR, and also remove our use of objcopy for this use.
ron
thanks
ron