[libvirt] [PATCH 1/7] Fix network device inconsistency between xm and sxpr

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

 



xenDaemonFormatSxpr() adds (type ioemu) only if xendConfigVersion < 4.
xenXMDomainConfigFormatNet() adds type=ioemu always.  Change it make
it consistent with xenDaemonFormatSxpr().

Signed-off-by: Markus Armbruster <armbru@xxxxxxxxxx>
---
 src/xm_internal.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/src/xm_internal.c b/src/xm_internal.c
index 77aa3e1..b3be199 100644
--- a/src/xm_internal.c
+++ b/src/xm_internal.c
@@ -1808,6 +1808,7 @@ static int xenXMDomainConfigFormatNet(virConnectPtr conn,
     virBuffer buf = VIR_BUFFER_INITIALIZER;
     virConfValuePtr val, tmp;
     char *str;
+    xenUnifiedPrivatePtr priv = (xenUnifiedPrivatePtr) conn->privateData;
 
     virBufferVSprintf(&buf, "mac=%02x:%02x:%02x:%02x:%02x:%02x",
                       net->mac[0], net->mac[1],
@@ -1836,7 +1837,7 @@ static int xenXMDomainConfigFormatNet(virConnectPtr conn,
         goto cleanup;
     }
 
-    if (hvm)
+    if (hvm && priv->xendConfigVersion < 4)
         virBufferAddLit(&buf, ",type=ioemu");
 
     if (net->model)
-- 
1.5.4.3

--
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]