os-cmpi-xen

changeset 133:3d8f3aba0dd8

Added property filter in setproperties function of cmpilify providers.

Fixed inadvertent commit of cmpilify.c that contained unimplemented log functions.

Some general cleanup of cmpilify providers.

Signed-off-by: Jim Fehlig <jfehlig@novell.com>
author Jim Fehlig <jfehlig@novell.com>
date Thu Jul 19 15:17:54 2007 -0600 (2007-07-19)
parents 1b777fd695b9
children 3a6f2019ef11
files src/Xen_ComputerSystemCapabilities.c src/Xen_ComputerSystemSettingData.c src/Xen_Disk.c src/Xen_DiskSettingData.c src/Xen_Memory.c src/Xen_MemorySettingData.c src/Xen_Processor.c src/Xen_ProcessorSettingData.c src/Xen_VirtualSystemManagementCapabilities.c src/cmpilify.c src/cmpilify.h
line diff
     1.1 --- a/src/Xen_ComputerSystemCapabilities.c	Thu Jul 19 11:35:05 2007 -0600
     1.2 +++ b/src/Xen_ComputerSystemCapabilities.c	Thu Jul 19 15:17:54 2007 -0600
     1.3 @@ -46,6 +46,10 @@ static const CMPIInstanceMI* mi;
     1.4  #include "xen_utils.h"
     1.5  
     1.6  
     1.7 +/* Class keys */
     1.8 +static const char *keys[] = {"InstanceID", NULL};
     1.9 +
    1.10 +
    1.11  /* Xen session object.  Initialize when the provider is loaded, close when
    1.12   * provider unloaded. */
    1.13  static xen_utils_session *session = NULL;
    1.14 @@ -213,14 +217,15 @@ static CMPIrc setproperties(CMPIInstance
    1.15     xen_vm_record *vm_rec = (xen_vm_record *)res;
    1.16     CMPIArray *statesSupported = CMNewArray(_BROKER, 6, CMPI_uint16, NULL);
    1.17     
    1.18 -   (void)properties;
    1.19 -   
    1.20     if (vm_rec == NULL)
    1.21        return CMPI_RC_ERR_FAILED;
    1.22  
    1.23     if (CMIsNullObject(inst))
    1.24        return CMPI_RC_ERR_FAILED;
    1.25  
    1.26 +   /* Setup a filter to only return the desired properties. */
    1.27 +   CMSetPropertyFilter(inst, properties, keys);
    1.28 +
    1.29    /* Set the CMPIInstance properties from the resource data. */
    1.30     CMSetProperty(inst, "InstanceID", (CMPIValue *)vm_rec->name_label, CMPI_chars);
    1.31     CMSetProperty(inst, "ElementName", (CMPIValue *)vm_rec->name_label, CMPI_chars);
    1.32 @@ -283,9 +288,6 @@ static void releaseid(void* res_id)
    1.33  }
    1.34  
    1.35  
    1.36 -/* NULL-terminated list of keys for this class. */
    1.37 -static char * keys[] = {"InstanceID", NULL};
    1.38 -
    1.39  /* Setup CMPILIFY function tables and instance provider entry point.*/
    1.40  /* CMPILIFYInstance1ROMIStub(<CLASS>,<PROVIDERNAME>,<KEYS>,<MIHANDLE>) */
    1.41  CMPILIFYInstanceMIStub(Xen_ComputerSystemCapabilities, Xen_ComputerSystemCapabilities, keys, mi)
     2.1 --- a/src/Xen_ComputerSystemSettingData.c	Thu Jul 19 11:35:05 2007 -0600
     2.2 +++ b/src/Xen_ComputerSystemSettingData.c	Thu Jul 19 15:17:54 2007 -0600
     2.3 @@ -66,6 +66,10 @@ typedef struct {
     2.4  } cs_resources;
     2.5  
     2.6  
     2.7 +/* Class keys */
     2.8 +static const char *keys[] = {"InstanceID", NULL};
     2.9 +
    2.10 +
    2.11  /* Xen session object.  Initialize when the provider is loaded, close when
    2.12   * provider unloaded. */
    2.13  static xen_utils_session *session = NULL;
    2.14 @@ -656,8 +660,6 @@ static CMPIrc setproperties(CMPIInstance
    2.15     char *map_val;
    2.16     int bool_val;
    2.17  
    2.18 -   (void)properties;
    2.19 -   
    2.20     if (res == NULL)
    2.21        return CMPI_RC_ERR_FAILED;
    2.22  
    2.23 @@ -669,6 +671,9 @@ static CMPIrc setproperties(CMPIInstance
    2.24     
    2.25     xen_vm_record *vm_rec = ((cs_resource *)res)->u.vm_rec;
    2.26  
    2.27 +   /* Setup a filter to only return the desired properties. */
    2.28 +   CMSetPropertyFilter(inst, properties, keys);
    2.29 +
    2.30     /* Set the CMPIInstance properties from the resource data. */
    2.31     snprintf(buf, 1024, "Xen:%s", vm_rec->name_label);
    2.32     CMSetProperty(inst, "InstanceID", (CMPIValue *)buf, CMPI_chars);
    2.33 @@ -789,6 +794,4 @@ static void releaseid(void* res_id)
    2.34  
    2.35  /* Setup CMPILIFY function tables and instance provider entry point.*/
    2.36  /* CMPILIFYInstanceMIStub(<CLASS>,<PROVIDER_NAME>,<keys>,<CMPIInstanceMI_HANDLE>) */
    2.37 -static char * keys[] = {"InstanceID", NULL};
    2.38 -
    2.39  CMPILIFYInstanceMIStub(Xen_ComputerSystemSettingData, Xen_ComputerSystemSettingData, keys, mi)
     3.1 --- a/src/Xen_Disk.c	Thu Jul 19 11:35:05 2007 -0600
     3.2 +++ b/src/Xen_Disk.c	Thu Jul 19 15:17:54 2007 -0600
     3.3 @@ -58,6 +58,11 @@ typedef struct {
     3.4  } vbd_resources;
     3.5  
     3.6  
     3.7 +/* Class keys */
     3.8 +static const char *keys[] = {"SystemCreationClassName", "SystemName",
     3.9 +                             "CreationClassName", "DeviceID", NULL};
    3.10 +
    3.11 +
    3.12  /* Xen session object.  Initialize when the provider is loaded, close when
    3.13   * provider unloaded. */
    3.14  static xen_utils_session *session = NULL;
    3.15 @@ -333,8 +338,6 @@ static CMPIrc setproperties(CMPIInstance
    3.16     xen_vbd_record *vbd_rec = (xen_vbd_record *)res;
    3.17     char buf[MAX_INSTANCEID_LEN];
    3.18     
    3.19 -   (void)properties;
    3.20 -   
    3.21     if (vbd_rec == NULL || CMIsNullObject(inst))
    3.22        return CMPI_RC_ERR_FAILED;
    3.23  
    3.24 @@ -355,6 +358,9 @@ static CMPIrc setproperties(CMPIInstance
    3.25        alloced_vm_rec = vm_rec;
    3.26     }
    3.27  
    3.28 +   /* Setup a filter to only return the desired properties. */
    3.29 +   CMSetPropertyFilter(inst, properties, keys);
    3.30 +
    3.31     CMSetProperty(inst, "SystemCreationClassName",
    3.32                   (CMPIValue *)"Xen_ComputerSystem", CMPI_chars);
    3.33     CMSetProperty(inst, "SystemName",
    3.34 @@ -447,7 +453,4 @@ static void releaseid(void* res_id)
    3.35  
    3.36  /* Setup CMPILIFY function tables and instance provider entry point.*/
    3.37  /* CMPILIFYInstanceMIStub(<CLASS>,<PROVIDER_NAME>,<keys>,<CMPIInstanceMI_HANDLE>) */
    3.38 -static char * keys[] = {"SystemCreationClassName", "SystemName",
    3.39 -                        "CreationClassName", "DeviceID", NULL};
    3.40 -
    3.41  CMPILIFYInstanceMIStub(Xen_Disk, Xen_Disk, keys, mi)
     4.1 --- a/src/Xen_DiskSettingData.c	Thu Jul 19 11:35:05 2007 -0600
     4.2 +++ b/src/Xen_DiskSettingData.c	Thu Jul 19 15:17:54 2007 -0600
     4.3 @@ -68,6 +68,10 @@ typedef struct {
     4.4  } vbd_resources;
     4.5  
     4.6  
     4.7 +/* Class keys */
     4.8 +static const char *keys[] = {"InstanceID", NULL};
     4.9 +
    4.10 +
    4.11  /* Xen session object.  Initialize when the provider is loaded, close when
    4.12   * provider unloaded. */
    4.13  static xen_utils_session *session = NULL;
    4.14 @@ -336,6 +340,8 @@ static CMPIrc modify(const void *res_id,
    4.15     xen_vbd_record *target_vbd_rec;
    4.16     char *tmp_str = NULL;
    4.17     
    4.18 +   (void)properties;
    4.19 +   
    4.20     if (CMIsNullObject(target_inst) || disk_resource == NULL ||
    4.21         disk_resource->is_vbd_record)
    4.22        return CMPI_RC_ERR_FAILED;
    4.23 @@ -447,8 +453,6 @@ static CMPIrc setproperties(CMPIInstance
    4.24     char buf[MAX_INSTANCEID_LEN];
    4.25     xen_vbd_record *vbd_rec;
    4.26     
    4.27 -   (void)properties;
    4.28 -   
    4.29     if (CMIsNullObject(inst) || disk_resource == NULL ||
    4.30         !disk_resource->is_vbd_record)
    4.31        return CMPI_RC_ERR_FAILED;
    4.32 @@ -471,6 +475,9 @@ static CMPIrc setproperties(CMPIInstance
    4.33        free(name);
    4.34     }
    4.35  
    4.36 +   /* Setup a filter to only return the desired properties. */
    4.37 +   CMSetPropertyFilter(inst, properties, keys);
    4.38 +
    4.39     /* Set the CMPIInstance properties from the resource data. */
    4.40     CMSetProperty(inst, "InstanceID",(CMPIValue *)buf, CMPI_chars);
    4.41     CMSetProperty(inst, "ElementName",(CMPIValue *)vbd_rec->device, CMPI_chars);
    4.42 @@ -567,6 +574,4 @@ static void releaseid(void* res_id)
    4.43  
    4.44  /* Setup CMPILIFY function tables and instance provider entry point.*/
    4.45  /* CMPILIFYInstanceMIStub(<CLASS>,<PROVIDER_NAME>,<keys>,<CMPIInstanceMI_HANDLE>) */
    4.46 -static char * keys[] = {"InstanceID", NULL};
    4.47 -
    4.48  CMPILIFYInstanceMIStub(Xen_DiskSettingData, Xen_DiskSettingData, keys, mi)
     5.1 --- a/src/Xen_Memory.c	Thu Jul 19 11:35:05 2007 -0600
     5.2 +++ b/src/Xen_Memory.c	Thu Jul 19 15:17:54 2007 -0600
     5.3 @@ -57,6 +57,11 @@ typedef struct {
     5.4  } memory_resources;
     5.5  
     5.6  
     5.7 +/* Class keys */
     5.8 +static const char *keys[] = {"SystemCreationClassName", "SystemName",
     5.9 +                             "CreationClassName", "DeviceID", NULL};
    5.10 +
    5.11 +
    5.12  /* Xen session object.  Initialize when the provider is loaded, close when
    5.13   * provider unloaded. */
    5.14  static xen_utils_session *session = NULL;
    5.15 @@ -90,6 +95,8 @@ static CMPIrc begin(void **res_list, con
    5.16  {
    5.17     memory_resources *resources;
    5.18     
    5.19 +   (void)properties;
    5.20 +   
    5.21     if (!xen_utils_validate_session(&session)) {
    5.22        _SBLIM_TRACE(_SBLIM_TRACE_LEVEL_ERROR,
    5.23                     ("--- Unable to establish connection with Xend"));
    5.24 @@ -130,6 +137,8 @@ static CMPIrc getnext(void *res_list, vo
    5.25  {
    5.26     memory_resources *resources = (memory_resources *)res_list;
    5.27  
    5.28 +   (void)properties;
    5.29 +   
    5.30     if (resources == NULL)
    5.31        return CMPI_RC_ERR_FAILED;
    5.32  
    5.33 @@ -168,6 +177,8 @@ static CMPIrc get(const void *res_id, vo
    5.34     CMPIData data;
    5.35     CMPIStatus status = {CMPI_RC_OK, NULL};
    5.36     char *prop_val;
    5.37 +
    5.38 +   (void)properties;
    5.39     
    5.40     if (CMIsNullObject(inst) || res == NULL)
    5.41        return CMPI_RC_ERR_FAILED;
    5.42 @@ -265,14 +276,15 @@ static CMPIrc setproperties(CMPIInstance
    5.43  {
    5.44     xen_vm_record *vm_rec = (xen_vm_record *)res;
    5.45  
    5.46 -   (void)properties;
    5.47 -   
    5.48     if (vm_rec == NULL)
    5.49        return CMPI_RC_ERR_FAILED;
    5.50  
    5.51     if (CMIsNullObject(inst))
    5.52        return CMPI_RC_ERR_FAILED;
    5.53  
    5.54 +   /* Setup a filter to only return the desired properties. */
    5.55 +   CMSetPropertyFilter(inst, properties, keys);
    5.56 +
    5.57     /* Set the CMPIInstance properties from the resource data. */
    5.58     CMSetProperty(inst, "SystemCreationClassName",
    5.59                   (CMPIValue *)"Xen_ComputerSystem", CMPI_chars);
    5.60 @@ -349,7 +361,4 @@ static void releaseid(void* res_id)
    5.61  
    5.62  /* Setup CMPILIFY function tables and instance provider entry point.*/
    5.63  /* CMPILIFYInstanceMIStub(<CLASS>,<PROVIDER_NAME>,<keys>,<CMPIInstanceMI_HANDLE>) */
    5.64 -static char * keys[] = {"SystemCreationClassName", "SystemName",
    5.65 -                        "CreationClassName", "DeviceID", NULL};
    5.66 -
    5.67  CMPILIFYInstanceMIStub(Xen_Memory, Xen_Memory, keys, mi)
     6.1 --- a/src/Xen_MemorySettingData.c	Thu Jul 19 11:35:05 2007 -0600
     6.2 +++ b/src/Xen_MemorySettingData.c	Thu Jul 19 15:17:54 2007 -0600
     6.3 @@ -68,6 +68,10 @@ typedef struct {
     6.4  } memory_resources;
     6.5  
     6.6  
     6.7 +/* Class keys */
     6.8 +static const char *keys[] = {"InstanceID", NULL};
     6.9 +
    6.10 +
    6.11  /* Xen session object.  Initialize when the provider is loaded, close when
    6.12   * provider unloaded. */
    6.13  static xen_utils_session *session = NULL;
    6.14 @@ -406,8 +410,6 @@ static CMPIrc setproperties(CMPIInstance
    6.15  {
    6.16     char buf[1024];
    6.17  
    6.18 -   (void)properties;
    6.19 -   
    6.20     if (res == NULL)
    6.21        return CMPI_RC_ERR_FAILED;
    6.22  
    6.23 @@ -419,6 +421,9 @@ static CMPIrc setproperties(CMPIInstance
    6.24     
    6.25     xen_vm_record *vm_rec = ((memory_resource *)res)->u.vm_rec;
    6.26  
    6.27 +   /* Setup a filter to only return the desired properties. */
    6.28 +   CMSetPropertyFilter(inst, properties, keys);
    6.29 +
    6.30     /* Set the CMPIInstance properties from the resource data. */
    6.31     snprintf(buf, 1024, "Xen:%s:Memory0", vm_rec->name_label);
    6.32     CMSetProperty(inst, "InstanceID", (CMPIValue *)buf, CMPI_chars);
    6.33 @@ -500,6 +505,4 @@ static void releaseid(void* res_id)
    6.34  
    6.35  /* Setup CMPILIFY function tables and instance provider entry point.*/
    6.36  /* CMPILIFYInstanceMIStub(<CLASS>,<PROVIDER_NAME>,<keys>,<CMPIInstanceMI_HANDLE>) */
    6.37 -static char * keys[] = {"InstanceID", NULL};
    6.38 -
    6.39  CMPILIFYInstanceMIStub(Xen_MemorySettingData, Xen_MemorySettingData, keys, mi)
     7.1 --- a/src/Xen_Processor.c	Thu Jul 19 11:35:05 2007 -0600
     7.2 +++ b/src/Xen_Processor.c	Thu Jul 19 15:17:54 2007 -0600
     7.3 @@ -65,6 +65,11 @@ typedef struct {
     7.4  } vcpu_resources;
     7.5  
     7.6  
     7.7 +/* Class keys */
     7.8 +static const char *keys[] = {"SystemCreationClassName", "SystemName",
     7.9 +                             "CreationClassName", "DeviceID", NULL};
    7.10 +
    7.11 +
    7.12  /* Xen session object.  Initialize when the provider is loaded, close when
    7.13   * provider unloaded. */
    7.14  static xen_utils_session *session = NULL;
    7.15 @@ -118,6 +123,8 @@ static CMPIrc begin(void **res_list, con
    7.16     size_t vm_ndx;
    7.17     int64_t vcpus_ndx;
    7.18     
    7.19 +   (void)properties;
    7.20 +   
    7.21     if (!xen_utils_validate_session(&session)) {
    7.22        _SBLIM_TRACE(_SBLIM_TRACE_LEVEL_ERROR,
    7.23                     ("--- Unable to establish connection with Xend"));
    7.24 @@ -216,6 +223,8 @@ static CMPIrc getnext(void *res_list, vo
    7.25     vcpu_resources *resources = (vcpu_resources *)res_list;
    7.26     vcpu_resource *resource;
    7.27  
    7.28 +   (void)properties;
    7.29 +   
    7.30     if (resources == NULL)
    7.31        return CMPI_RC_ERR_FAILED;
    7.32  
    7.33 @@ -250,6 +259,8 @@ static CMPIrc get(const void *res_id, vo
    7.34     char *prop_val;
    7.35     vcpu_resource *resource;
    7.36     
    7.37 +   (void)properties;
    7.38 +   
    7.39     if (CMIsNullObject(inst) || res == NULL)
    7.40        return CMPI_RC_ERR_FAILED;
    7.41  
    7.42 @@ -392,6 +403,9 @@ static CMPIrc setproperties(CMPIInstance
    7.43  
    7.44     vcpu_resource *resource = (vcpu_resource *)res;
    7.45  
    7.46 +   /* Setup a filter to only return the desired properties. */
    7.47 +   CMSetPropertyFilter(inst, properties, keys);
    7.48 +
    7.49     /* Set the CMPIInstance properties from the resource data. */
    7.50     CMSetProperty(inst, "SystemCreationClassName",
    7.51                   (CMPIValue *)"Xen_ComputerSystem", CMPI_chars);
    7.52 @@ -447,7 +461,4 @@ static void releaseid(void* res_id)
    7.53  
    7.54  /* Setup CMPILIFY function tables and instance provider entry point.*/
    7.55  /* CMPILIFYInstanceMIStub(<CLASS>,<PROVIDER_NAME>,<keys>,<CMPIInstanceMI_HANDLE>) */
    7.56 -static char * keys[] = {"SystemCreationClassName", "SystemName",
    7.57 -                        "CreationClassName", "DeviceID", NULL};
    7.58 -
    7.59  CMPILIFYInstanceMIStub(Xen_Processor, Xen_Processor, keys, mi)
     8.1 --- a/src/Xen_ProcessorSettingData.c	Thu Jul 19 11:35:05 2007 -0600
     8.2 +++ b/src/Xen_ProcessorSettingData.c	Thu Jul 19 15:17:54 2007 -0600
     8.3 @@ -70,6 +70,10 @@ typedef struct {
     8.4  } vcpu_resources;
     8.5  
     8.6  
     8.7 +/* Class keys */
     8.8 +static const char *keys[] = {"InstanceID", NULL};
     8.9 +
    8.10 +
    8.11  /* Xen session object.  Initialize when the provider is loaded, close when
    8.12   * provider unloaded. */
    8.13  static xen_utils_session *session = NULL;
    8.14 @@ -103,6 +107,8 @@ static CMPIrc begin(void **res_list, con
    8.15  {
    8.16     vcpu_resources *resources;
    8.17     
    8.18 +   (void)properties;
    8.19 +   
    8.20     if (!xen_utils_validate_session(&session)) {
    8.21        _SBLIM_TRACE(_SBLIM_TRACE_LEVEL_ERROR,
    8.22                     ("--- Unable to establish connection with Xend"));
    8.23 @@ -144,6 +150,8 @@ static CMPIrc getnext(void *res_list, vo
    8.24     vcpu_resources *resources = (vcpu_resources *)res_list;
    8.25     vcpu_resource *resource;
    8.26  
    8.27 +   (void)properties;
    8.28 +   
    8.29     if (resources == NULL)
    8.30        return CMPI_RC_ERR_FAILED;
    8.31  
    8.32 @@ -184,6 +192,8 @@ static CMPIrc get(const void *res_id, vo
    8.33     vcpu_resource *resource;
    8.34     char sys_name[MAX_SYSTEM_NAME_LEN];
    8.35     
    8.36 +   (void)properties;
    8.37 +   
    8.38     if (CMIsNullObject(inst) || res == NULL)
    8.39        return CMPI_RC_ERR_FAILED;
    8.40  
    8.41 @@ -284,6 +294,8 @@ static CMPIrc modify(const void *res_id,
    8.42     char sys_name[MAX_SYSTEM_NAME_LEN];
    8.43     char buf[64];
    8.44  
    8.45 +   (void)properties;
    8.46 +   
    8.47     if (CMIsNullObject(target_inst) || resource == NULL ||
    8.48         resource->is_vm_record)
    8.49        return CMPI_RC_ERR_FAILED;
    8.50 @@ -413,6 +425,9 @@ static CMPIrc setproperties(CMPIInstance
    8.51     
    8.52     xen_vm_record *vm_rec = ((vcpu_resource *)res)->u.vm_rec;
    8.53  
    8.54 +   /* Setup a filter to only return the desired properties. */
    8.55 +   CMSetPropertyFilter(inst, properties, keys);
    8.56 +
    8.57     /* Set the CMPIInstance properties from the resource data. */
    8.58     snprintf(buf, MAX_INSTANCEID_LEN, "Xen:%s:Processor", vm_rec->name_label);
    8.59     CMSetProperty(inst, "InstanceID", (CMPIValue *)buf, CMPI_chars);
    8.60 @@ -516,6 +531,4 @@ static void releaseid(void* res_id)
    8.61  
    8.62  /* Setup CMPILIFY function tables and instance provider entry point.*/
    8.63  /* CMPILIFYInstanceMIStub(<CLASS>,<PROVIDER_NAME>,<keys>,<CMPIInstanceMI_HANDLE>) */
    8.64 -static char * keys[] = {"InstanceID", NULL};
    8.65 -
    8.66  CMPILIFYInstanceMIStub(Xen_ProcessorSettingData, Xen_ProcessorSettingData, keys, mi)
     9.1 --- a/src/Xen_VirtualSystemManagementCapabilities.c	Thu Jul 19 11:35:05 2007 -0600
     9.2 +++ b/src/Xen_VirtualSystemManagementCapabilities.c	Thu Jul 19 15:17:54 2007 -0600
     9.3 @@ -47,6 +47,10 @@ static const CMPIInstanceMI* mi;
     9.4  #include "xen_utils.h"
     9.5  
     9.6  
     9.7 +/* Class keys */
     9.8 +static const char *keys[] = {"InstanceID", NULL};
     9.9 +
    9.10 +
    9.11  /* Xen session object.  Initialize when the provider is loaded, close when
    9.12   * provider unloaded. */
    9.13  static xen_utils_session *session = NULL;
    9.14 @@ -81,6 +85,8 @@ static CMPIrc get(void **res, const char
    9.15  {
    9.16     xen_host_record *host_rec;
    9.17  
    9.18 +   (void)properties;
    9.19 +   
    9.20     if (!xen_utils_validate_session(&session)) {
    9.21        _SBLIM_TRACE(_SBLIM_TRACE_LEVEL_ERROR,
    9.22                     ("--- Unable to establish connection with Xend"));
    9.23 @@ -123,6 +129,9 @@ static CMPIrc setproperties(CMPIInstance
    9.24  
    9.25     host_rec = (xen_host_record *)res;
    9.26     
    9.27 +   /* Setup a filter to only return the desired properties. */
    9.28 +   CMSetPropertyFilter(inst, properties, keys);
    9.29 +
    9.30     /* Set the CMPIInstance properties from the resource data. */
    9.31     if (host_rec->name_label) {
    9.32        CMSetProperty(inst, "InstanceID",
    9.33 @@ -199,9 +208,6 @@ static CMPIrc setproperties(CMPIInstance
    9.34  }
    9.35  
    9.36  
    9.37 -/* NULL-terminated list of keys for this class. */
    9.38 -static char * keys[] = {"InstanceID", NULL};
    9.39 -
    9.40  /* Setup CMPILIFY function tables and instance provider entry point.*/
    9.41  /* CMPILIFYInstance1ROMIStub(<CLASS>,<PROVIDERNAME>,<KEYS>,<MIHANDLE>) */
    9.42  CMPILIFYInstance1ROMIStub(Xen_VirtualSystemManagementCapabilities, Xen_VirtualSystemManagementCapabilities, keys, mi)
    10.1 --- a/src/cmpilify.c	Thu Jul 19 11:35:05 2007 -0600
    10.2 +++ b/src/cmpilify.c	Thu Jul 19 15:17:54 2007 -0600
    10.3 @@ -936,7 +936,7 @@ static CMPIStatus gettargetinfo
    10.4     CMPIObjectPath* tmpop;
    10.5     CMPIInstance* srcinst;
    10.6  
    10.7 -   CMPILIFY_LOGENTER();
    10.8 +   _SBLIM_ENTER("gettargetinfo");
    10.9  
   10.10     srccn = CMGetCharPtr(CMGetClassName(op, &status));
   10.11     srcns = CMGetCharPtr(CMGetNameSpace(op, &status));
   10.12 @@ -1002,7 +1002,7 @@ static CMPIStatus gettargetinfo
   10.13     }
   10.14  
   10.15   exit:
   10.16 -   CMPILIFY_LOGEXITSTATUS(status);
   10.17 +   _SBLIM_RETURNSTATUS(status);
   10.18  }
   10.19  
   10.20  /* ------------------------------------------------------------------------- */
   10.21 @@ -1011,7 +1011,7 @@ CMPIStatus CMPILIFYAssociation_cleanup
   10.22          (CMPIInstanceMI* mi, const CMPIContext* ctx, CMPIBoolean terminating)
   10.23  {
   10.24     CMPIStatus status = {CMPI_RC_OK, NULL};
   10.25 -   CMPILIFY_LOGENTER();
   10.26 +   _SBLIM_ENTER("CMPILIFYAssociation_cleanup");
   10.27  
   10.28     /* Run resource provider's unload(). */
   10.29     if (_FT->unload(terminating == CMPI_true) != CMPI_RC_OK)
   10.30 @@ -1019,7 +1019,7 @@ CMPIStatus CMPILIFYAssociation_cleanup
   10.31                             CMPI_RC_ERR_FAILED : CMPI_RC_DO_NOT_UNLOAD,
   10.32                             "CMPILIFY unload() failed");
   10.33  
   10.34 -   CMPILIFY_LOGEXITSTATUS(status);
   10.35 +   _SBLIM_RETURNSTATUS(status);
   10.36  }
   10.37  
   10.38  /* ------------------------------------------------------------------------- */
   10.39 @@ -1036,7 +1036,7 @@ CMPIStatus CMPILIFYAssociation_enumInsta
   10.40     CMPIEnumeration* enm;
   10.41     CMPIData data;
   10.42  
   10.43 -   CMPILIFY_LOGENTER();
   10.44 +   _SBLIM_ENTER("CMPILIFYAssociation_enumInstanceNames");
   10.45  
   10.46     /* Determine target class: LHS or RHS. */
   10.47     op = CMNewObjectPath(_BROKER, _LHSNAMESPACE, _LHSCLASS, &status);
   10.48 @@ -1077,7 +1077,7 @@ if (!CMHasNext(enm,NULL))
   10.49  
   10.50     CMReturnDone(rslt);
   10.51   exit:
   10.52 -   CMPILIFY_LOGEXITSTATUS(status);
   10.53 +   _SBLIM_RETURNSTATUS(status);
   10.54  }
   10.55  
   10.56  /* ------------------------------------------------------------------------- */
   10.57 @@ -1095,7 +1095,7 @@ CMPIStatus CMPILIFYAssociation_enumInsta
   10.58     CMPIEnumeration* enm;
   10.59     CMPIData data;
   10.60  
   10.61 -   CMPILIFY_LOGENTER();
   10.62 +   _SBLIM_ENTER("CMPILIFYAssociation_enumInstances");
   10.63  
   10.64     /* Determine target class: LHS or RHS. */
   10.65     op = CMNewObjectPath(_BROKER, _LHSNAMESPACE, _LHSCLASS, &status);
   10.66 @@ -1138,7 +1138,7 @@ if (!CMHasNext(enm,NULL))
   10.67  
   10.68     CMReturnDone(rslt);
   10.69   exit:
   10.70 -   CMPILIFY_LOGEXITSTATUS(status);
   10.71 +   _SBLIM_RETURNSTATUS(status);
   10.72  }
   10.73  
   10.74  /* ------------------------------------------------------------------------- */
   10.75 @@ -1148,8 +1148,8 @@ CMPIStatus CMPILIFYAssociation_getInstan
   10.76          const CMPIObjectPath* ref, const char** properties)
   10.77  {
   10.78     CMPIStatus status = {CMPI_RC_ERR_NOT_SUPPORTED, NULL};
   10.79 -   CMPILIFY_LOGENTER();
   10.80 -   CMPILIFY_LOGEXITSTATUS(status);
   10.81 +   _SBLIM_ENTER("CMPILIFYAssociation_getInstance");
   10.82 +   _SBLIM_RETURNSTATUS(status);
   10.83  }
   10.84  
   10.85  /* ------------------------------------------------------------------------- */
   10.86 @@ -1159,8 +1159,8 @@ CMPIStatus CMPILIFYAssociation_createIns
   10.87          const CMPIObjectPath* ref, const CMPIInstance* inst)
   10.88  {
   10.89     CMPIStatus status = {CMPI_RC_ERR_NOT_SUPPORTED, NULL};
   10.90 -   CMPILIFY_LOGENTER();
   10.91 -   CMPILIFY_LOGEXITSTATUS(status);
   10.92 +   _SBLIM_ENTER("CMPILIFYAssociation_createInstance");
   10.93 +   _SBLIM_RETURNSTATUS(status);
   10.94  }
   10.95  
   10.96  /* ------------------------------------------------------------------------- */
   10.97 @@ -1171,8 +1171,8 @@ CMPIStatus CMPILIFYAssociation_modifyIns
   10.98          const char** properties)
   10.99  {
  10.100     CMPIStatus status = {CMPI_RC_ERR_NOT_SUPPORTED, NULL};
  10.101 -   CMPILIFY_LOGENTER();
  10.102 -   CMPILIFY_LOGEXITSTATUS(status);
  10.103 +   _SBLIM_ENTER("CMPILIFYAssociation_modifyInstance");
  10.104 +   _SBLIM_RETURNSTATUS(status);
  10.105  }
  10.106  
  10.107  /* ------------------------------------------------------------------------- */
  10.108 @@ -1182,8 +1182,8 @@ CMPIStatus CMPILIFYAssociation_deleteIns
  10.109          const CMPIObjectPath* ref)
  10.110  {
  10.111     CMPIStatus status = {CMPI_RC_ERR_NOT_SUPPORTED, NULL};
  10.112 -   CMPILIFY_LOGENTER();
  10.113 -   CMPILIFY_LOGEXITSTATUS(status);
  10.114 +   _SBLIM_ENTER("CMPILIFYAssociation_deleteInstance");
  10.115 +   _SBLIM_RETURNSTATUS(status);
  10.116  }
  10.117  
  10.118  /* ------------------------------------------------------------------------- */
  10.119 @@ -1193,8 +1193,8 @@ CMPIStatus CMPILIFYAssociation_execQuery
  10.120          const CMPIObjectPath* ref, const char* lang, const char* query)
  10.121  {
  10.122     CMPIStatus status = {CMPI_RC_ERR_NOT_SUPPORTED, NULL};
  10.123 -   CMPILIFY_LOGENTER();
  10.124 -   CMPILIFY_LOGEXITSTATUS(status);
  10.125 +   _SBLIM_ENTER("CMPILIFYAssociation_execQuery");
  10.126 +   _SBLIM_RETURNSTATUS(status);
  10.127  }
  10.128  
  10.129  /* ------------------------------------------------------------------------- */
  10.130 @@ -1204,14 +1204,14 @@ CMPIStatus CMPILIFYAssociation_associati
  10.131          CMPIBoolean terminating)
  10.132  {
  10.133     CMPIStatus status = {CMPI_RC_OK, NULL};
  10.134 -   CMPILIFY_LOGENTER();
  10.135 +   _SBLIM_ENTER("CMPILIFYAssociation_associationCleanup");
  10.136  
  10.137     if (_FT->unload(terminating == CMPI_true) != CMPI_RC_OK)
  10.138        CMSetStatusWithChars(_BROKER, &status, (terminating == CMPI_true)?
  10.139                             CMPI_RC_ERR_FAILED : CMPI_RC_DO_NOT_UNLOAD,
  10.140                             "CMPILIFY unload() failed");
  10.141  
  10.142 -   CMPILIFY_LOGEXITSTATUS(status);
  10.143 +   _SBLIM_RETURNSTATUS(status);
  10.144  }
  10.145  
  10.146  /* ------------------------------------------------------------------------- */
  10.147 @@ -1232,7 +1232,7 @@ CMPIStatus CMPILIFYAssociation_associato
  10.148     CMPIData data;
  10.149     CMPIInstance* tmpinst;
  10.150  
  10.151 -   CMPILIFY_LOGENTER();
  10.152 +   _SBLIM_ENTER("CMPILIFYAssociation_associators");
  10.153  
  10.154     status = gettargetinfo(mi,ctx,op,assocClass,resultClass,role,resultRole,
  10.155                            &trgcn, &trgns, &query, &lang);
  10.156 @@ -1269,7 +1269,7 @@ CMPIStatus CMPILIFYAssociation_associato
  10.157   exit:
  10.158     if (query) free(query);
  10.159     if (lang) free(lang);
  10.160 -   CMPILIFY_LOGEXITSTATUS(status);
  10.161 +   _SBLIM_RETURNSTATUS(status);
  10.162  }
  10.163  
  10.164  /* ------------------------------------------------------------------------- */
  10.165 @@ -1289,7 +1289,7 @@ CMPIStatus CMPILIFYAssociation_associato
  10.166     CMPIData data;
  10.167     CMPIInstance* tmpinst;
  10.168  
  10.169 -   CMPILIFY_LOGENTER();
  10.170 +   _SBLIM_ENTER("CMPILIFYAssociation_associatorNames");
  10.171  
  10.172     status = gettargetinfo(mi,ctx,op,assocClass,resultClass,role,resultRole,
  10.173                            &trgcn, &trgns, &query, &lang);
  10.174 @@ -1327,7 +1327,7 @@ CMPIStatus CMPILIFYAssociation_associato
  10.175   exit:
  10.176     if (query) free(query);
  10.177     if (lang) free(lang);
  10.178 -   CMPILIFY_LOGEXITSTATUS(status);
  10.179 +   _SBLIM_RETURNSTATUS(status);
  10.180  }
  10.181  
  10.182  /* ------------------------------------------------------------------------- */
  10.183 @@ -1350,7 +1350,7 @@ CMPIStatus CMPILIFYAssociation_reference
  10.184     CMPIObjectPath* assocop;
  10.185     CMPIInstance* associnst;
  10.186    
  10.187 -   CMPILIFY_LOGENTER();
  10.188 +   _SBLIM_ENTER("CMPILIFYAssociation_references");
  10.189  
  10.190     status = gettargetinfo(mi,ctx,op,NULL,resultClass,role,NULL,
  10.191                            &trgcn, &trgns, &query, &lang);
  10.192 @@ -1413,7 +1413,7 @@ CMPIStatus CMPILIFYAssociation_reference
  10.193   exit:
  10.194     if (query) free(query);
  10.195     if (lang) free(lang);
  10.196 -   CMPILIFY_LOGEXITSTATUS(status);
  10.197 +   _SBLIM_RETURNSTATUS(status);
  10.198  }
  10.199  
  10.200  /* ------------------------------------------------------------------------- */
  10.201 @@ -1434,7 +1434,7 @@ CMPIStatus CMPILIFYAssociation_reference
  10.202     char* ns;
  10.203     CMPIObjectPath* assocop;
  10.204  
  10.205 -   CMPILIFY_LOGENTER();
  10.206 +   _SBLIM_ENTER("CMPILIFYAssociation_referenceNames");
  10.207  
  10.208     status = gettargetinfo(mi,ctx,op,NULL,resultClass,role,NULL,
  10.209                            &trgcn, &trgns, &query, &lang);
  10.210 @@ -1491,5 +1491,5 @@ CMPIStatus CMPILIFYAssociation_reference
  10.211   exit:
  10.212     if (query) free(query);
  10.213     if (lang) free(lang);
  10.214 -   CMPILIFY_LOGEXITSTATUS(status);
  10.215 +   _SBLIM_RETURNSTATUS(status);
  10.216  }
    11.1 --- a/src/cmpilify.h	Thu Jul 19 11:35:05 2007 -0600
    11.2 +++ b/src/cmpilify.h	Thu Jul 19 15:17:54 2007 -0600
    11.3 @@ -50,7 +50,7 @@ typedef struct {
    11.4     void* hdl;                     /* Handle to implementation-specific data. */
    11.5     const CMPIBroker* brkr;    /* CIMOM handle, initialized on provider load. */
    11.6     char* cn;                               /* Instance provider's CIM class. */
    11.7 -   char** kys;                    /* NULL terminated list of CIM class keys. */
    11.8 +   const char** kys;           /* NULL terminated list of CIM class keys. */
    11.9     CMPILIFYInstanceMIFT* ft;        /* Abstract resource API function table. */
   11.10  } CMPILIFYInstanceMI;
   11.11  
   11.12 @@ -170,7 +170,7 @@ typedef struct {
   11.13     void* hdl;                     /* Handle to implementation-specific data. */
   11.14     const CMPIBroker* brkr;    /* CIMOM handle, initialized on provider load. */
   11.15     char* cn;                               /* Instance provider's CIM class. */
   11.16 -   char** kys;                    /* NULL terminated list of CIM class keys. */
   11.17 +   const char** kys;          /* NULL terminated list of CIM class keys. */
   11.18     CMPILIFYInstance1ROMIFT* ft;     /* Abstract resource API function table. */
   11.19  } CMPILIFYInstance1ROMI;
   11.20