[Libvirt-cim] [PATCH] This fix the generation of the <boot> tag on fully-virtualizable Xen guests

Richard Maciel rmaciel at linux.vnet.ibm.com
Thu May 14 15:28:45 UTC 2009


# HG changeset patch
# User Richard Maciel <rmaciel at linux.vnet.ibm.com>
# Date 1242071235 10800
# Node ID c0bd6c9a2c0084398784bb1ae36649bd3400e36c
# Parent  5608b9455cd32fccbc324cd540c509d7230a113f
This fix the generation of the <boot> tag on fully-virtualizable Xen guests.

Right now it is generated with the boot device as a the value of the node (e.g. <boot>hd</boot>)
However, the boot device must be a property of the node (e.g. <boot dev='hd'/>)

Signed-off-by: Richard Maciel <rmaciel at linux.vnet.ibm.com>

diff -r 5608b9455cd3 -r c0bd6c9a2c00 libxkutil/xmlgen.c
--- a/libxkutil/xmlgen.c	Mon Apr 27 17:05:48 2009 -0700
+++ b/libxkutil/xmlgen.c	Mon May 11 16:47:15 2009 -0300
@@ -457,10 +457,12 @@
         if (tmp == NULL)
                 return XML_ERROR;
 
-        tmp = xmlNewChild(root, NULL, BAD_CAST "boot", BAD_CAST os->boot);
+        tmp = xmlNewChild(root, NULL, BAD_CAST "boot", NULL);
         if (tmp == NULL)
                 return XML_ERROR;
 
+        xmlNewProp(tmp, BAD_CAST "dev", BAD_CAST os->boot);
+
         tmp = xmlNewChild(root, NULL, BAD_CAST "features", NULL);
         xmlNewChild(tmp, NULL, BAD_CAST "pae", NULL);
         xmlNewChild(tmp, NULL, BAD_CAST "acpi", NULL);




More information about the Libvirt-cim mailing list