Eduardo,

What happens when you try to do a dynamic update on a defined guest after applying this patch? I am guessing that libvirt should fail with similar message.
In any case, libvirt-cim should not be doing any check like the one you patched. It should just call appropriate libvirt API.

-Sharad

libvirt-cim-bounces@redhat.com wrote on 09/20/2011 01:53:00 PM:

> "Eduardo Lima \(Etrunko\)" <eblima@linux.vnet.ibm.com>

> Sent by: libvirt-cim-bounces@redhat.com
>

> 09/20/2011 01:53 PM
>
> Please respond to
> List for discussion and development of libvirt CIM <libvirt-cim@redhat.com>

>
> To

>
> libvirt-cim@redhat.com

>
> cc

>
> Subject

>
> [Libvirt-cim] [PATCH] VirtualSystemManagementService: Always update
> domain device information

>
>  src/Virt_VirtualSystemManagementService.c |  9 ---------
>  1 files changed, 0 insertions(+), 9 deletions(-)
>
>
> # HG changeset patch
> # User Eduardo Lima (Etrunko) <eblima@br.ibm.com>
> # Date 1316551891 10800
> # Node ID 25c6de6ebf094bf602e95ddf01dd39a6c5c1804a
> # Parent  9a59a56e226f3f800ff7214b81ab5f2fe6362fcc
> VirtualSystemManagementService: Always update domain device information
>
> I noticed that a call to ModifyResourceSettings was causing devices
> description
> to be lost. It happens that there was an explicit check in the code that
> resulted in the device information to be updated only if the specified  domain
> was running.
>
> This patch removes that block and now the resulting domain xml after the
> ModifyResourceSettings call will keep the device information.
>
> Signed-off-by: Eduardo Lima (Etrunko) <eblima@br.ibm.com>
>
> diff --git a/src/Virt_VirtualSystemManagementService.c b/src/
> Virt_VirtualSystemManagementService.c
> --- a/src/Virt_VirtualSystemManagementService.c
> +++ b/src/Virt_VirtualSystemManagementService.c
> @@ -2349,15 +2349,6 @@
>  
>          update_dominfo(dominfo, refcn);
>  
> -        if (!domain_online(dom)) {
> -                CU_DEBUG("VS `%s' not online; skipping dynamic update",
> -                         dominfo->name);
> -                cu_statusf(_BROKER, &s,
> -                           CMPI_RC_OK,
> -                           "");
> -                goto out;
> -        }
> -
>          CU_DEBUG("Doing dynamic device update for `%s'", dominfo->name);
>  
>          if (func(dom, dev) == 0) {
>
> _______________________________________________
> Libvirt-cim mailing list
> Libvirt-cim@redhat.com
> https://www.redhat.com/mailman/listinfo/libvirt-cim