]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
* util/hostdisk.c (convert_system_partition_to_system_disk):
authordavem <davem@localhost>
Thu, 30 Apr 2009 13:21:14 +0000 (13:21 +0000)
committerdavem <davem@localhost>
Thu, 30 Apr 2009 13:21:14 +0000 (13:21 +0000)
Handle virtual disk devices named /dev/vdiskX as found on sparc
and powerpc.

ChangeLog
util/hostdisk.c

index 4b170990efb80548d0232c278405316fcc154d31..d0df5dc686d7cbac444876833cafb181449a0f34 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2009-04-30  David S. Miller  <davem@davemloft.net>
 
+       * util/hostdisk.c (convert_system_partition_to_system_disk):
+       Handle virtual disk devices named /dev/vdiskX as found on sparc
+       and powerpc.
+
        * kern/sparc64/ieee1275/init.c (grub_machine_set_prefix): If
        lettered partition specifier is found, convert to numbered.
 
index aa41703fedb7a0cafa25a966c2cdd063adec4ea2..af93f97591ab7188dbc2968099c298e873259edb 100644 (file)
@@ -767,6 +767,13 @@ convert_system_partition_to_system_disk (const char *os_dev)
        }
       
       /* If this is an IDE, SCSI or Virtio disk.  */
+      if (strncmp ("vdisk", p, 5) == 0
+         && p[5] >= 'a' && p[5] <= 'z')
+       {
+         /* /dev/vdisk[a-z][0-9]* */
+         p[6] = '\0';
+         return path;
+       }
       if ((strncmp ("hd", p, 2) == 0
           || strncmp ("vd", p, 2) == 0
           || strncmp ("sd", p, 2) == 0)