[Libvirt-cim] [PATCH] (#3) Fix RASD provider unregistration

Kaitlin Rupert kaitlin at linux.vnet.ibm.com
Fri Nov 14 20:29:40 UTC 2008


# HG changeset patch
# User Kaitlin Rupert <karupert at us.ibm.com>
# Date 1225926818 28800
# Node ID 5680eb18d7ea2971acf4fbdb50e3e69f5c014ef0
# Parent  ce7c7e1b1779e43176254108c271ab1e9501390f
(#3) Fix RASD provider unregistration.

Since <>_ResourceAllocationSettingData is listed first in the mof, it doesn't
get properly unregistered because <>_ProcResourceAllocationSettingData haven't
been unregistered yet.

Updates from 2 to 3:
 -Build mof and reg list in reverse instead of building them forward and then
  reversing the list

Updates from 1 to 2:
 -Fix provider_register.sh to reverse the list when uninstalling
 -Move superclass definition for RASD to its own mof

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

diff -r ce7c7e1b1779 -r 5680eb18d7ea Makefile.am
--- a/Makefile.am	Thu Nov 13 13:50:04 2008 -0800
+++ b/Makefile.am	Wed Nov 05 15:13:38 2008 -0800
@@ -27,6 +27,7 @@
 	schema/ElementConformsToProfile.mof \
 	schema/ComputerSystemIndication.mof \
 	schema/ComputerSystemMigrationIndication.mof \
+	schema/Virt_ResourceAllocationSettingData.mof \
 	schema/ResourceAllocationSettingData.mof \
 	schema/ResourcePoolConfigurationService.mof \
 	schema/ResourcePoolConfigurationCapabilities.mof \
diff -r ce7c7e1b1779 -r 5680eb18d7ea provider-register.sh
--- a/provider-register.sh	Thu Nov 13 13:50:04 2008 -0800
+++ b/provider-register.sh	Wed Nov 05 15:13:38 2008 -0800
@@ -233,9 +233,9 @@
       fi
       if test $mofmode = 1
       then
-	  mymofs="$mymofs $1"
+          mymofs="$1 $mymofs"
       else
-	  myregs="$myregs $1"
+          myregs="$1 $myregs"
       fi
       shift
     done
diff -r ce7c7e1b1779 -r 5680eb18d7ea schema/ResourceAllocationSettingData.mof
--- a/schema/ResourceAllocationSettingData.mof	Thu Nov 13 13:50:04 2008 -0800
+++ b/schema/ResourceAllocationSettingData.mof	Wed Nov 05 15:13:38 2008 -0800
@@ -1,16 +1,4 @@
 // Copyright IBM Corp. 2007
-
-class Xen_ResourceAllocationSettingData : CIM_ResourceAllocationSettingData
-{
-};
-
-class KVM_ResourceAllocationSettingData : CIM_ResourceAllocationSettingData
-{
-};
-
-class LXC_ResourceAllocationSettingData : CIM_ResourceAllocationSettingData
-{
-};
 
 [Description ("Xen virtual disk configuration"),
  Provider("cmpi::Virt_RASD")
diff -r ce7c7e1b1779 -r 5680eb18d7ea schema/Virt_ResourceAllocationSettingData.mof
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/schema/Virt_ResourceAllocationSettingData.mof	Wed Nov 05 15:13:38 2008 -0800
@@ -0,0 +1,14 @@
+// Copyright IBM Corp. 2007
+
+class Xen_ResourceAllocationSettingData : CIM_ResourceAllocationSettingData
+{
+};
+
+class KVM_ResourceAllocationSettingData : CIM_ResourceAllocationSettingData
+{
+};
+
+class LXC_ResourceAllocationSettingData : CIM_ResourceAllocationSettingData
+{
+};
+




More information about the Libvirt-cim mailing list