Subject: Re: CVS commit: syssrc
To: None <M.Drochner@fz-juelich.de>
From: Simon Burge <simonb@netbsd.org>
List: port-pmax
Date: 10/30/1999 02:51:06
Matthias Drochner wrote:

> simonb@netbsd.org said:
> > Sorry 'bout that.  I had some changes to mkboot that I must have
> > forgotten to commit that go with this.
> 
> Sorry if this interfered...

No drama - I shouldn't have left the tree in a non-buildable state.  My
apologies for that.

> > The changes are needed for
> > multi-archictecture bootblocks.
> 
> Is this worth much if the firmware can't boot an iso cd anyway?

I've booted an iso image dd'd to an RZ23L, so it should also be
possible to boot an iso cd.

> > maybe I should leave it so that
> > sizeof(struct boot_block)==512 so that I/O to the raw device is
> > always sector-sized...
> 
> So you are turning "mkboot" into an "installboot"?

Sortof - I've pretty much stolen the Alpha installboot (and a good
chunk of their stand/ as well), but they can cheat a little bit over
there.  On an Alpha, the first stage loads at a fixed address, whereas
on the pmax the load address is specified in the bootblock header.  That
means that the alpha can get away with putting a binary file with just
text+data in /usr/mdec and installboot just stuffs it on the disk.  I've
changed a few things around so that we store stripped ELF bootblocks
in /usr/mdec and installboot reads them directly.  This should mean an
end for elf2aout (hopefully I'll figure out what objcopy doesn't seem
to generate a happy ECOFF kernel and we can get rid of elf2ecoff too).
Here's what I have now:

	mona:~ 1> ls -l /usr/mdec
	total 192
	-r-xr-xr-x  1 root  wheel  41072 Aug 11 00:06 boot*
	-r-xr-xr-x  1 root  wheel  51136 Oct 25 15:54 bootpmax*
	-r-xr-xr-x  1 root  wheel   7680 Aug 11 18:37 bootrz*
	-r--r--r--  1 root  wheel   6960 Oct 25 15:54 bootxx_cd9660
	-r--r--r--  1 root  wheel   7952 Oct 25 15:54 bootxx_ffs
	-r--r--r--  1 root  wheel   7872 Oct 25 15:54 bootxx_lfs
	-r-xr-xr-x  1 root  wheel  70364 Oct 25 21:19 installboot*
	-r-xr-xr-x  1 root  wheel    512 Aug 11 18:37 rzboot*
	mona:~ 2> file /usr/mdec/*
	/usr/mdec/boot:          ELF 32-bit LSB executable, ....
	/usr/mdec/bootpmax:      ELF 32-bit LSB executable, ....
	/usr/mdec/bootrz:        data
	/usr/mdec/bootxx_cd9660: ELF 32-bit LSB executable, ....
	/usr/mdec/bootxx_ffs:    ELF 32-bit LSB executable, ....
	/usr/mdec/bootxx_lfs:    ELF 32-bit LSB executable, ....
	/usr/mdec/installboot:   ELF 32-bit LSB executable, ....
	/usr/mdec/rzboot:        data

The files dated 'Aug 11' aren't used anymore - I just haven't gotten
around to deleting them...

I still need to add an option to installboot so that it can put
the first stage at an arbitary block so that other less-friendly
architectures that assume their first stage is on blocks 1-15 can
co-exist on a cdrom :-)

Simon.