[PATCH] Add "ubd" to the list of disk prefixes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



virDiskNameToIndex has a list of disk name prefixes that it uses in the
process of finding the disk's index. This list is missing "ubd" which
is the disk prefix used for UML domains.

Signed-off-by: Soren Hansen <soren@xxxxxxxxxxx>
---
 src/util/util.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/util/util.c b/src/util/util.c
index 8f2a17e..c173e49 100644
--- a/src/util/util.c
+++ b/src/util/util.c
@@ -2367,7 +2367,7 @@ const char *virEnumToString(const char *const*types,
 int virDiskNameToIndex(const char *name) {
     const char *ptr = NULL;
     int idx = 0;
-    static char const* const drive_prefix[] = {"fd", "hd", "vd", "sd", "xvd"};
+    static char const* const drive_prefix[] = {"fd", "hd", "vd", "sd", "xvd", "ubd"};
     unsigned int i;
 
     for (i = 0; i < ARRAY_CARDINALITY(drive_prefix); i++) {
-- 
1.7.0.4

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]