[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ppc patch] fix Old World disk access
From: |
Hollis Blanchard |
Subject: |
[ppc patch] fix Old World disk access |
Date: |
Thu, 14 Oct 2004 22:54:19 -0500 |
User-agent: |
Mutt/1.5.6+20040722i |
This patch works around a bug in Old World Mac firmware. It allows "open" to
succeed but fails at least "seek" when disks are opened with a trailing ":0".
With the patch, we can get output like this:
grub> linux (scsi/sd,
Possible partitions are: Partition num:0, Filesystem type Unknown
Partition num:1, Filesystem type Unknown
Partition num:2, Filesystem type Unknown
Partition num:3, Filesystem type Unknown
Partition num:4, Filesystem type Unknown
Partition num:5, Filesystem type ext2
(The use of BAT mappings must be replaced before the kernel will boot, but
unfortunately that will have to wait for another day.)
-Hollis
2004-10-14 Hollis Blanchard <address@hidden>
* disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Do not
append ":0" to devpath if the GRUB_IEEE1275_NO_PARTITION_0 flag is
set in grub_ieee1275_flags.
Index: disk/powerpc/ieee1275/ofdisk.c
===================================================================
RCS file: /cvsroot/grub/grub2/disk/powerpc/ieee1275/ofdisk.c,v
retrieving revision 1.4
diff -u -r1.4 ofdisk.c
--- disk/powerpc/ieee1275/ofdisk.c 13 Oct 2004 23:43:44 -0000 1.4
+++ disk/powerpc/ieee1275/ofdisk.c 15 Oct 2004 03:42:30 -0000
@@ -57,7 +57,9 @@
return grub_errno;
/* To access the complete disk add `:0'. */
- grub_strcat (devpath, ":0");
+ if (! (grub_ieee1275_flags & GRUB_IEEE1275_NO_PARTITION_0))
+ grub_strcat (devpath, ":0");
+
grub_ieee1275_open (devpath, &dev_ihandle);
if (! dev_ihandle)
{
- [ppc patch] fix Old World disk access,
Hollis Blanchard <=