[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH]: Handle virtual disk device names on powerpc/sparc64
From: |
David Miller |
Subject: |
[PATCH]: Handle virtual disk device names on powerpc/sparc64 |
Date: |
Thu, 30 Apr 2009 06:22:13 -0700 (PDT) |
PowerPC and Sparc64 virtualized disks on hypervisor systems
are named /dev/vdiskX instead of /dev/vdX. Handle this.
Committed.
2009-04-30 David S. Miller <address@hidden>
* util/hostdisk.c (convert_system_partition_to_system_disk):
Handle virtual disk devices named /dev/vdiskX as found on sparc
and powerpc.
diff --git a/util/hostdisk.c b/util/hostdisk.c
index aa41703..eaccb73 100644
--- a/util/hostdisk.c
+++ b/util/hostdisk.c
@@ -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)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [PATCH]: Handle virtual disk device names on powerpc/sparc64,
David Miller <=