# HG changeset patch
# User Kaitlin Rupert <karupert(a)us.ibm.com>
# Date 1227636080 28800
# Node ID fe39b8a3b9bc769e8af3e3a39be3b77c34227c25
# Parent 8a1f369f8f70a23eea6771ed09cd06ce74992be2
Add input support to Mod/Del/Add methods.
Signed-off-by: Kaitlin Rupert <karupert(a)us.ibm.com>
diff -r 8a1f369f8f70 -r fe39b8a3b9bc src/Makefile.am
--- a/src/Makefile.am Tue Nov 25 09:41:16 2008 -0800
+++ b/src/Makefile.am Tue Nov 25 10:01:20 2008 -0800
@@ -87,9 +87,9 @@
libVirt_ComputerSystemMigrationIndication_la_SOURCES =
Virt_ComputerSystemMigrationIndication.c
libVirt_ComputerSystemMigrationIndication_la_LIBADD = -lVirt_ComputerSystem
-libVirt_VirtualSystemManagementService_la_DEPENDENCIES = libVirt_ComputerSystem.la
libVirt_ComputerSystemIndication.la libVirt_RASD.la libVirt_HostSystem.la
libVirt_DevicePool.la
+libVirt_VirtualSystemManagementService_la_DEPENDENCIES = libVirt_ComputerSystem.la
libVirt_ComputerSystemIndication.la libVirt_RASD.la libVirt_HostSystem.la
libVirt_DevicePool.la libVirt_Device.la
libVirt_VirtualSystemManagementService_la_SOURCES =
Virt_VirtualSystemManagementService.c
-libVirt_VirtualSystemManagementService_la_LIBADD = -lVirt_ComputerSystem
-lVirt_ComputerSystemIndication -lVirt_RASD -lVirt_HostSystem -lVirt_DevicePool
+libVirt_VirtualSystemManagementService_la_LIBADD = -lVirt_ComputerSystem
-lVirt_ComputerSystemIndication -lVirt_RASD -lVirt_HostSystem -lVirt_DevicePool
-lVirt_Device
libVirt_VirtualSystemManagementCapabilities_la_DEPENDENCIES = libVirt_HostSystem.la
libVirt_VirtualSystemManagementCapabilities_la_SOURCES =
Virt_VirtualSystemManagementCapabilities.c
diff -r 8a1f369f8f70 -r fe39b8a3b9bc src/Virt_VirtualSystemManagementService.c
--- a/src/Virt_VirtualSystemManagementService.c Tue Nov 25 09:41:16 2008 -0800
+++ b/src/Virt_VirtualSystemManagementService.c Tue Nov 25 10:01:20 2008 -0800
@@ -50,6 +50,7 @@
#include "Virt_RASD.h"
#include "Virt_HostSystem.h"
#include "Virt_DevicePool.h"
+#include "Virt_Device.h"
#include "svpc_types.h"
#include "config.h"
@@ -1417,6 +1418,9 @@
} else if (type == CIM_RES_TYPE_GRAPHICS) {
list = &dominfo->dev_graphics;
*count = &dominfo->dev_graphics_ct;
+ } else if (type == CIM_RES_TYPE_INPUT) {
+ list = &dominfo->dev_input;
+ *count = &dominfo->dev_input_ct;
}
return list;
@@ -1535,7 +1539,8 @@
if (STREQ(dev->id, devid)) {
dev->type = CIM_RES_TYPE_UNKNOWN;
- if (type == CIM_RES_TYPE_GRAPHICS)
+ if ((type == CIM_RES_TYPE_GRAPHICS) ||
+ (type == CIM_RES_TYPE_INPUT))
cu_statusf(_BROKER, &s, CMPI_RC_OK, "");
else {
s = _resource_dynamic(dominfo,
@@ -1611,7 +1616,7 @@
dev->type = type;
rasd_to_vdev(rasd, dominfo, dev, ns);
- if (type == CIM_RES_TYPE_GRAPHICS) {
+ if ((type == CIM_RES_TYPE_GRAPHICS) || (type == CIM_RES_TYPE_INPUT)) {
(*count)++;
cu_statusf(_BROKER, &s, CMPI_RC_OK, "");
goto out;
@@ -1674,7 +1679,8 @@
if (STREQ(dev->id, devid)) {
rasd_to_vdev(rasd, dominfo, dev, ns);
- if (type == CIM_RES_TYPE_GRAPHICS)
+ if ((type == CIM_RES_TYPE_GRAPHICS) ||
+ (type == CIM_RES_TYPE_INPUT))
cu_statusf(_BROKER, &s, CMPI_RC_OK, "");
else {
s = _resource_dynamic(dominfo,