rpms/libvirt-cim/devel hyp_conn_fail.patch, NONE, 1.1 mem_parse.patch, NONE, 1.1 mig_prof_ver.patch, NONE, 1.1 rm_def_virtdev.patch, NONE, 1.1 rm_eafp_err.patch, NONE, 1.1 sdc_unsup.patch, NONE, 1.1 vsmigser_schema.patch, NONE, 1.1 libvirt-cim.spec, 1.19, 1.20

Kaitlin Rupert kaitlin at fedoraproject.org
Tue Sep 23 17:55:06 UTC 2008


Author: kaitlin

Update of /cvs/pkgs/rpms/libvirt-cim/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv11558

Modified Files:
	libvirt-cim.spec 
Added Files:
	hyp_conn_fail.patch mem_parse.patch mig_prof_ver.patch 
	rm_def_virtdev.patch rm_eafp_err.patch sdc_unsup.patch 
	vsmigser_schema.patch 
Log Message:
Add new patches needed for release 0.5.1-5.  Also update rpm spec to include new patches.



hyp_conn_fail.patch:

--- NEW FILE hyp_conn_fail.patch ---
# HG changeset patch
# User Dan Smith <danms at us.ibm.com>
# Date 1220551376 25200
# Node ID f0f2c7bf7ec73c937ec24c2c7e1d1c455174c39c
# Parent  f54687a160bf4a80558e14ed58ae5b60c00781ec
Fix case where connecting to hypervisor fails in VSMS functions

In the associations, we want to silently exit when we can't connect to the
hypervisor because of the way the CIMOM implements the association
traversal.  In VSMS, where the user has specifically invoked a method on
a particular reference, that is not the correct behavior.

Signed-off-by: Dan Smith <danms at us.ibm.com>

diff -r f54687a160bf -r f0f2c7bf7ec7 src/Virt_VirtualSystemManagementService.c
--- a/src/Virt_VirtualSystemManagementService.c	Thu Sep 04 11:02:54 2008 -0700
+++ b/src/Virt_VirtualSystemManagementService.c	Thu Sep 04 11:02:56 2008 -0700
@@ -1029,6 +1029,7 @@
         CMPIInstance *sys;
         CMPIArray *res;
         CMPIStatus s;
+        uint32_t rc = CIM_SVPC_RETURN_FAILED;
 
         CU_DEBUG("DefineSystem");
 
@@ -1054,6 +1055,10 @@
                            "ComputerSystemCreatedIndication",
                            reference);
  out:
+        if (s.rc == CMPI_RC_OK)
+                rc = CIM_SVPC_RETURN_COMPLETED;
+        CMReturnData(results, &rc, CMPI_uint32);
+
         return s;
 }
 
@@ -1538,16 +1543,22 @@
 
 static CMPIStatus _update_resource_settings(const CMPIObjectPath *ref,
                                             CMPIArray *resources,
+                                            const CMPIResult *results,
                                             resmod_fn func)
 {
         int i;
         virConnectPtr conn = NULL;
         CMPIStatus s;
         int count;
+        uint32_t rc = CIM_SVPC_RETURN_FAILED;
 
         conn = connect_by_classname(_BROKER, CLASSNAME(ref), &s);
-        if (conn == NULL)
+        if (conn == NULL) {
+                cu_statusf(_BROKER, &s,
+                           CMPI_RC_ERR_FAILED,
+                           "Unable to connect to hypervisor");
                 goto out;
+        }
 
         count = CMGetArrayCount(resources, NULL);
 
@@ -1596,6 +1607,11 @@
 
         }
  out:
+        if (s.rc == CMPI_RC_OK)
+                rc = CIM_SVPC_RETURN_COMPLETED;
+
+        CMReturnData(results, &rc, CMPI_uint32);
+
         virConnectClose(conn);
 
         return s;
@@ -1603,6 +1619,7 @@
 
 static CMPIStatus update_resource_settings(const CMPIObjectPath *ref,
                                            const CMPIArgs *argsin,
+                                           const CMPIResult *results,
                                            resmod_fn func)
 {
         CMPIArray *arr;
@@ -1615,7 +1632,7 @@
                 goto out;
         }
 
-        s = _update_resource_settings(ref, arr, func);
+        s = _update_resource_settings(ref, arr, results, func);
 
  out:
         return s;
@@ -1689,7 +1706,10 @@
                                         const CMPIArgs *argsin,
                                         CMPIArgs *argsout)
 {
-        return update_resource_settings(reference, argsin, resource_add);
+        return update_resource_settings(reference,
+                                        argsin,
+                                        results,
+                                        resource_add);
 }
 
 static CMPIStatus mod_resource_settings(CMPIMethodMI *self,
@@ -1699,7 +1719,10 @@
                                         const CMPIArgs *argsin,
                                         CMPIArgs *argsout)
 {
-        return update_resource_settings(reference, argsin, resource_mod);
+        return update_resource_settings(reference,
+                                        argsin,
+                                        results,
+                                        resource_mod);
 }
 
 static CMPIStatus rm_resource_settings(CMPIMethodMI *self,
@@ -1728,7 +1751,10 @@
         if (s.rc != CMPI_RC_OK)
                 goto out;
 
-        s = _update_resource_settings(reference, resource_arr, resource_del);
+        s = _update_resource_settings(reference,
+                                      resource_arr,
+                                      results,
+                                      resource_del);
  out:
         return s;
 }
diff -r f54687a160bf -r f0f2c7bf7ec7 src/svpc_types.h
--- a/src/svpc_types.h	Thu Sep 04 11:02:54 2008 -0700
+++ b/src/svpc_types.h	Thu Sep 04 11:02:56 2008 -0700
@@ -45,6 +45,7 @@
 #define CIM_VSSD_RECOVERY_PRESERVE 123
 
 #define CIM_SVPC_RETURN_JOB_STARTED   4096
+#define CIM_SVPC_RETURN_FAILED           2
 #define CIM_SVPC_RETURN_COMPLETED        0
 
 #define CIM_EC_CHAR_DEFAULT 2

mem_parse.patch:

--- NEW FILE mem_parse.patch ---
# HG changeset patch
# User Kaitlin Rupert <karupert at us.ibm.com>
# Date 1220392087 25200
# Node ID 2796fd3e2eaa202206430ad59c01dd01cd982ccd
# Parent  2db1158cea318cfee11a77724c97a0b4758ffb2c
Fix memory XML parsing so that max_size is set to the memory value...

And size is set to the value of currentMem.

Signed-off-by: Kaitlin Rupert <karupert at us.ibm.com>

diff -r 2db1158cea31 -r 2796fd3e2eaa libxkutil/device_parsing.c
--- a/libxkutil/device_parsing.c	Fri Aug 29 08:16:56 2008 -0700
+++ b/libxkutil/device_parsing.c	Tue Sep 02 14:48:07 2008 -0700
@@ -407,9 +407,9 @@
 
         content = get_node_content(node);
 
-        if (XSTREQ(node->name, "memory"))
+        if (XSTREQ(node->name, "currentMemory"))
                 sscanf(content, "%" PRIu64, &mdev->size);
-        else if (XSTREQ(node->name, "currentMemory"))
+        else if (XSTREQ(node->name, "memory"))
                 sscanf(content, "%" PRIu64, &mdev->maxsize);
 
         free(content);

mig_prof_ver.patch:

--- NEW FILE mig_prof_ver.patch ---
# HG changeset patch
# User Dan Smith <danms at us.ibm.com>
# Date 1220551374 25200
# Node ID f54687a160bf4a80558e14ed58ae5b60c00781ec
# Parent  2796fd3e2eaa202206430ad59c01dd01cd982ccd
Update migration profile version

Signed-off-by: Dan Smith <danms at us.ibm.com>

diff -r 2796fd3e2eaa -r f54687a160bf src/profiles.h
--- a/src/profiles.h	Tue Sep 02 14:48:07 2008 -0700
+++ b/src/profiles.h	Thu Sep 04 11:02:54 2008 -0700
@@ -73,9 +73,9 @@
 
 struct reg_prof VirtualSystemMigration = {
         .reg_org = 2,
-        .reg_id = "CIM:DSP1081-VirtualSystemMigration-1.0",
+        .reg_id = "CIM:DSP1081-VirtualSystemMigration-0.8.1",
         .reg_name = "Virtual System Migration",
-        .reg_version = "1.0",
+        .reg_version = "0.8.1",
         .scoping_class = NULL,
         .scoping_profile = &SystemVirtualization
 };

rm_def_virtdev.patch:

--- NEW FILE rm_def_virtdev.patch ---
# HG changeset patch
# User Dan Smith <danms at us.ibm.com>
# Date 1221063953 25200
# Node ID b3f75efd7baf6dd6e1b023fdb91163f699c1a7c9
# Parent  e4e78fce79575db03c1629d625a53ec13f33992b
Remove the default implied VirtualDevice on DiskRASD

I'm not sure what I was thinking when I allowed the client to not specify
a VirtualDevice for a given disk, but this patch removes that and turns
it into an error.

The Address field needs to have similar semantics, but will be a little
more complicated for CDROM and thus will be handled in the upcoming set.

Signed-off-by: Dan Smith <danms at us.ibm.com>

diff -r e4e78fce7957 -r b3f75efd7baf src/Virt_VirtualSystemManagementService.c
--- a/src/Virt_VirtualSystemManagementService.c	Fri Sep 05 11:55:57 2008 -0700
+++ b/src/Virt_VirtualSystemManagementService.c	Wed Sep 10 09:25:53 2008 -0700
@@ -440,7 +440,7 @@
         const char *val = NULL;
 
         if (cu_get_str_prop(inst, "VirtualDevice", &val) != CMPI_RC_OK)
-                val = "hda";
+                return "Missing `VirtualDevice' property";
 
         free(dev->dev.disk.virtual_dev);
         dev->dev.disk.virtual_dev = strdup(val);

rm_eafp_err.patch:

--- NEW FILE rm_eafp_err.patch ---
# HG changeset patch
# User Dan Smith <danms at us.ibm.com>
# Date 1221064059 25200
# Node ID 6a8e14dc94847ac449a65a28f83e6f8ee2b22fbd
# Parent  5d114b296a8228d1e591e1908fbecd4a96152e5e
Eliminate error status on EAFP when no pool link exists

I think that the proper behavior is to just not return anything instead of an
error.  Since not being affiliated with a pool isn't necessarily an error, we
shouldn't kill an entire associaton operation as a result.

Signed-off-by: Dan Smith <danms at us.ibm.com>

diff -r 5d114b296a82 -r 6a8e14dc9484 src/Virt_ElementAllocatedFromPool.c
--- a/src/Virt_ElementAllocatedFromPool.c	Wed Sep 10 09:27:19 2008 -0700
+++ b/src/Virt_ElementAllocatedFromPool.c	Wed Sep 10 09:27:39 2008 -0700
@@ -75,9 +75,7 @@
 
         poolid = pool_member_of(_BROKER, CLASSNAME(ref), type, id);
         if (poolid == NULL) {
-                cu_statusf(_BROKER, &s,
-                           CMPI_RC_ERR_FAILED,
-                           "Unknown pool membership for `%s'", id);
+                CU_DEBUG("No pool membership for `%s'", id);
                 goto out;
         }
 

sdc_unsup.patch:

--- NEW FILE sdc_unsup.patch ---
# HG changeset patch
# User Dan Smith <danms at us.ibm.com>
# Date 1221066318 25200
# Node ID 86aa60d7eb8c85c8ebeab009c231b9abe1afe156
# Parent  6a8e14dc94847ac449a65a28f83e6f8ee2b22fbd
Make SDC not return UNSUPPORTED for the rasd_to_alloc_cap case

Pegasus treats this as a soft error and ignores it, but SFCB halts
the entire association process (as would probably be expected).

Signed-off-by: Dan Smith <danms at us.ibm.com>

diff -r 6a8e14dc9484 -r 86aa60d7eb8c src/Virt_SettingsDefineCapabilities.c
--- a/src/Virt_SettingsDefineCapabilities.c	Wed Sep 10 09:27:39 2008 -0700
+++ b/src/Virt_SettingsDefineCapabilities.c	Wed Sep 10 10:05:18 2008 -0700
@@ -1002,7 +1002,7 @@
                                     struct std_assoc_info *info,
                                     struct inst_list *list)
 {
-        RETURN_UNSUPPORTED();
+        return (CMPIStatus){CMPI_RC_OK, NULL};
 }
 
 static CMPIStatus migrate_cap_to_vsmsd(const CMPIObjectPath *ref,

vsmigser_schema.patch:

--- NEW FILE vsmigser_schema.patch ---
# HG changeset patch
# User Dan Smith <danms at us.ibm.com>
# Date 1220021032 25200
# Node ID e2c21aedef202a43dfc29f64d4849589ca581292
# Parent  a8130304d2f225657fd8c58c0eedb5d0eea37b7f
Fix VSMigrationService schema to remove duplicate method name

Signed-off-by: Dan Smith <danms at us.ibm.com>

diff -r a8130304d2f2 -r e2c21aedef20 schema/VSMigrationService.mof
--- a/schema/VSMigrationService.mof	Fri Aug 22 10:50:48 2008 -0700
+++ b/schema/VSMigrationService.mof	Fri Aug 29 07:43:52 2008 -0700
@@ -49,7 +49,7 @@
 	       CIM_ConcreteJob REF Job
       );
 
-      uint32 MigrateVirtualSystemToHost(
+      uint32 MigrateVirtualSystemToSystem(
 	     [In]
 	       CIM_ComputerSystem REF ComputerSystem,
 	     [In]


Index: libvirt-cim.spec
===================================================================
RCS file: /cvs/pkgs/rpms/libvirt-cim/devel/libvirt-cim.spec,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -r1.19 -r1.20
--- libvirt-cim.spec	28 Aug 2008 15:56:44 -0000	1.19
+++ libvirt-cim.spec	23 Sep 2008 17:55:06 -0000	1.20
@@ -3,7 +3,7 @@
 Summary: A CIM provider for libvirt
 Name: libvirt-cim
 Version: 0.5.1
-Release: 4%{?dist}
+Release: 5%{?dist}
 License: LGPLv2+
 Group: Development/Libraries
 Source: libvirt-cim-%{version}.tar.gz
@@ -28,6 +28,13 @@
 Patch8: add_shutdown_rsc.patch
 Patch9: vsmc_add_remove.patch
 Patch10: override_refconf.patch
+Patch11: vsmigser_schema.patch
+Patch12: mem_parse.patch
+Patch13: mig_prof_ver.patch
+Patch14: hyp_conn_fail.patch
+Patch15: rm_def_virtdev.patch
+Patch16: rm_eafp_err.patch
+Patch17: sdc_unsup.patch
 
 %description
 Libvirt-cim is a CMPI CIM provider that implements the DMTF SVPC
@@ -50,6 +57,13 @@
 %patch8 -p1
 %patch9 -p1
 %patch10 -p1
+%patch11 -p1
+%patch12 -p1
+%patch13 -p1
+%patch14 -p1
+%patch15 -p1
+%patch16 -p1
+%patch17 -p1
 
 %build
 %configure --disable-werror
@@ -114,7 +128,7 @@
 
 %files 
 %defattr(-, root, root)
-/etc/libvirt/cim
+%{_sysconfdir}/libvirt/cim
 
 %doc README COPYING doc/CodingStyle doc/SubmittingPatches
 #%doc base_schema/README.DMTF
@@ -131,6 +145,15 @@
 /etc/ld.so.conf.d/libvirt-cim.conf
 
 %changelog
+* Tue Sep 23 2008 Kaitlin Rupert <kaitlin at us.ibm.com> - 0.5.1-5
+- Added vsmigser_schema patch to remove dup method name from VSMigrationService
+- Added mem_parse patch to set proper mem max_size and mem values
+- Added mig_prof_ver patch to report the proper Migration Profile version
+- Added hyp_conn_fail patch to fix when not connecting to hyp returns a failure
+- Added rm_def_virtdev patch to remove default DiskRADSD virtual device
+- Added rm_eafp_err patch to remove error status when EAFP no pool link exists
+- Added sdc_unsup patch to make SDC not return unsup for RASD to AC case
+
 * Wed Aug 27 2008 Kaitlin Rupert <kaitlin at us.ibm.com> - 0.5.1-4
 - Added nostate patch to consider XenFV no state guests as running guests
 - Added createsnap_override patch to add vendor defined values to CreateSnapshot




More information about the fedora-extras-commits mailing list