I've tested the patch on briQ. As far as I can tell, CodeGen's "SmartFirmware" is crap, frequently suffering mysterious failures that require unplugging and waiting (unplugging and replugging rapidly isn't enough). It also suffers frequent ATA failures, where the disk or controller simply stop responding.

1. (major) Firmware does not properly set /chosen/bootpath to include the partition number.
2. (major) Partition numbering *seems* to be 0-based. I had a lot of problems booting, but I'm pretty sure it is.
3. (minor) /chosen/bootpath is this:
/[EMAIL PROTECTED]/[EMAIL PROTECTED]/[EMAIL PROTECTED]/[EMAIL PROTECTED],0
but the "hd" devalias is this:
/[EMAIL PROTECTED]/[EMAIL PROTECTED]/[EMAIL PROTECTED]/[EMAIL PROTECTED],0
Note the differing case of "f". This prevents the devalias matching from succeeding. I've fixed this by using strncasecmp instead of strncmp.


There are various other problems, such as ignoring arguments to the "boot" command and instead always using boot-device and boot-file. Also I get unexplained errors like these:
ok boot hda:0,/grubof.chrp
error: error while trying to load or boot
but this works:
ok " hda:0" " /grubof.chrp" (load) go


Problem 1 could be worked around by taking the yaboot approach: iterate over all disk partitions looking for a file named "/grub/grub.cfg" (i.e. /boot/grub/grub.cfg). This fallback can be used if we do not find a grub.cfg in prefix.

Problem 2 could be worked around by blacklisting firmwares based on the /openprom properties. Here is the briQ's output:
ok dev /openprom
ok .properties
relative-addressing
model "BRIQ,1.0.2.60"
SmartFirmware-version "1.1"
CodeGen-copyright "SmartFirmware(tm) Copyright 1996-2000 by CodeGen, Inc. All Rights Reserved."
name "openprom"


Does the Pegasos have a SmartFirmware-version property?

-Hollis



_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to