Subject: trouble netbooting a G4
To: None <port-macppc@netbsd.org>
From: Chuck Silvers <chuq@chuq.com>
List: port-macppc
Date: 02/12/2006 22:34:34
hi,

I'm trying to net-boot my G4 tower with ofwboot, but I'm running into
some difficulty.  the command I'm using is:

	boot enet:,ofwboot.xcf netbsd.macppc

this takes a long time and eventually results in:

>> NetBSD/macppc OpenFirmware Boot, Revision 1.10
>> (chs@spathi.chuq.com, Sun Feb 12 22:10:35 PST 2006)
BOOTP/BSDP failed: no FILENAME specifiedopen netbsd.macppc: Device not configured


the first part of this error message is actually coming from OFW,
but that's a red herring... even if I hack dhcpd to include the filename
in the reply to the DHCPINFORM request, it still fails with the same error.

the real problem is that the device that ofwboot is passing to OF_open()
is "/pci@f4000000/ethernet:0".  if I remove the final ":0" from this string
then everything works fine.  the ":0" is actually being added by ofwboot
due to this change to boot.c:

----------------------------
revision 1.7
date: 1999/08/03 07:08:36;  author: tsubai;  state: Exp;  lines: +34 -5
branches:  1.7.2;
Make ``boot kernelname'' work on OF-3.x too.
----------------------------

my machine has OFW version 3, so this code will make sure that there's always
a ":0" on the end of the bootdev string.  I tried some experiments with
disk-booting without the :0 to see what problem occured without this change,
but everything I tried worked ok.  can anyone explain what this change
was fixing?

in case it matters, I have my machine set up to disk-boot from a small
FAT partition using "hd:2,ofwboot netbsd".  was the above change perhaps
an attempt to make "partition zero" booting work on OFW 3 machines?
the install docs are a little unclear, but it looks like we don't recommend
using "partition zero" style bootingon OFW 3 machines at this point.

I guess I'm proposing to back out the above change to ofwboot/boot.c,
can anyone tell me if that would break anything?

-Chuck