On Thu, 2008-01-31 at 22:57 +0100, Jordi Mallach wrote:
> [EMAIL PROTECTED]:~$ sudo grub-mkdevicemap --device-map=/dev/stdout
> (hd)  /dev/hda
> 
> However, grub-probe totally doesn't like the lack of drive number:
> [EMAIL PROTECTED]:~$ sudo grub-probe /boot/grub 
> grub-probe: error: /boot/grub/device.map:1: Bad device name
> 
> If I edit my device.map and add a drive number, say hd0:
> 
> [EMAIL PROTECTED]:~$ sudo grub-probe /boot/grub
> hfs

Yes, I've seen this problem.

> util/biosdisk.c assumes:
> 
>       if (drive < 0 || drive >= (int) (sizeof (map) / sizeof (map[0])))
>         show_error ("Bad device name");
> 
> Can this be ifndef GRUB_MACHINE_PCBIOS'd?

No.  This would lead to using a wrong index in the map table.  I think
the code should be changed so that the map uses consecutive numbers for
the entries in device.map and stores the actual names.

The BIOS numbers for the disks should not be needed in cross-platform
utilities.  If they are, the code should be fixed.

-- 
Regards,
Pavel Roskin


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

Reply via email to