Signed-off-by: Xu Wang <gesaint(a)linux.vnet.ibm.com>
---
libxkutil/device_parsing.c | 10 ++++++++++
1 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/libxkutil/device_parsing.c b/libxkutil/device_parsing.c
index 37582da..b8a0c73 100644
--- a/libxkutil/device_parsing.c
+++ b/libxkutil/device_parsing.c
@@ -43,6 +43,7 @@
#define GRAPHICS_XPATH (xmlChar *)"/domain/devices/graphics | "\
"/domain/devices/console | /domain/devices/serial"
#define INPUT_XPATH (xmlChar *)"/domain/devices/input"
+#define UNKNOWN_XPATH (xmlChar *)"/domain/devices"
#define DEFAULT_BRIDGE "xenbr0"
#define DEFAULT_NETWORK "default"
@@ -1528,6 +1529,11 @@ static int parse_devices(const char *xml, struct virt_device
**_list, int type)
func = &parse_input_device;
break;
+ case CIM_RES_TYPE_UNKNOWN:
+ xpathstr = UNKNOWN_XPATH;
+ func = &parse_unknown_device;
+ break;
+
default:
CU_DEBUG("Unrecognized device type. Returning.");
goto err1;
@@ -1932,6 +1938,10 @@ int get_dominfo_from_xml(const char *xml, struct domain **dominfo)
&(*dominfo)->dev_vcpu,
CIM_RES_TYPE_PROC);
+ (*dominfo)->dev_unknown_ct = parse_devices(xml,
+ &(*dominfo)->dev_unknown,
+ CIM_RES_TYPE_UNKNOWN);
+
return ret;
err:
--
1.7.1