Signed-off-by: Xu Wang <gesaint(a)linux.vnet.ibm.com>
---
libxkutil/xmlgen.c | 18 +++++++++++++++---
1 files changed, 15 insertions(+), 3 deletions(-)
diff --git a/libxkutil/xmlgen.c b/libxkutil/xmlgen.c
index 292717d..c59b172 100644
--- a/libxkutil/xmlgen.c
+++ b/libxkutil/xmlgen.c
@@ -1860,9 +1860,12 @@ char *system_to_xml(struct domain *dominfo)
&input_xml,
&graphics_xml,
&emu_xml,
+ &unknown_xml,
NULL
};
+ CU_DEBUG("Enter system_to_xml()");
+
if ((dominfo->type == DOMAIN_XENPV) || (dominfo->type == DOMAIN_XENFV))
domtype = "xen";
else if (dominfo->type == DOMAIN_KVM)
@@ -1890,15 +1893,18 @@ char *system_to_xml(struct domain *dominfo)
if (xmlNewProp(root, BAD_CAST "type", BAD_CAST domtype) == NULL)
goto out;
- msg = system_xml(root, dominfo);
+ /* Parse all tags into others field of domain and generate xml in
+ * others_to_xml().
+ */
+ msg = os_xml(root, dominfo);
if (msg != NULL)
goto out;
- msg = os_xml(root, dominfo);
+ msg = features_xml(root, dominfo);
if (msg != NULL)
goto out;
- msg = features_xml(root, dominfo);
+ msg = system_xml(root, dominfo);
if (msg != NULL)
goto out;
@@ -1917,6 +1923,12 @@ char *system_to_xml(struct domain *dominfo)
goto out;
#endif
+ dominfo->others = others_to_xml(root, dominfo->others,
"domain");
+ if (dominfo->others) {
+ CU_DEBUG("others_to_xml failed.");
+ }
+
+ /* Parse <devices> field. */
devices = xmlNewChild(root, NULL, BAD_CAST "devices", NULL);
if (devices == NULL) {
msg = XML_ERROR;
--
1.7.1