Linuxbios + Etherboot + tagged Kernel Image

Eric W. Biederman ebiederman at lnxi.com
Sat Apr 26 15:04:00 CEST 2003


Steve Gehlbach <steve at nexpath.com> writes:

> >>cat vmlinux.gz > /dev/hda1
> >>
> >>That puts it where etherboot can get it.
> > Note.  Etherboot is not limited to only one hard disk so it may make
> > sense to put it on a secondary disk.
> > Eric
> 
> I don't see how this works, with an 8kbytes limit how etherboot could find it in
> 
> hda1. Typical disks are 63 sectors, so the initial skip to partition 1 is 63 x
> 512 ~= 32K, or much larger than 8K.

So again my goal was not to be able to boot out of hda1 but to provide
a MBR like boot mechanism that would work with older systems.

It happens that you can tell some of the partition programs to create
a partition that is not aligned on cylinder boundaries.  So they can
create a partition hda1 that you can just throw the ELF image into.

The way etherboot loads the image is it interprets all addresses
in the ELF image as disk addresses with offsets from the start 
of the ELF image.  There is support for ELF64 so you can if you wish
scatter the image across an entire disk.  The only restriction is there
is an assumption that the entire ELF header, and ELF program header
are read into memory with the first 8K read.

I have a proof of concept utility that will look up the addresses
a ELF images is stored on disk (like lilo) and generate a new 64bit
ELF header that will allow it to be loaded from anywhere on the disk.
I have not published it because the address it puts the ELF header at
is currently hard coded, and there are several other stupid
assumptions.  If you want the code holler and I will send it to you.


Eric




More information about the coreboot mailing list