[libvirt] [PATCHv6 2/3] libvirt/qemu - support persistent modification of qemu disks

KAMEZAWA Hiroyuki kamezawa.hiroyu at jp.fujitsu.com
Thu Mar 24 08:52:39 UTC 2011


On Thu, 24 Mar 2011 16:49:29 +0800
Wen Congyang <wency at cn.fujitsu.com> wrote:

> 
> Sometimes, qemuDomainAssignPCIAddress() failed, and it does not report error.
> 
> qemuDomainAssignPCIAddress() calls qemuDomainPCIAddressSetCreate()
> that calls virDomainDeviceInfoIterate()
> that calls qemuCollectPCIAddress()
> that calls virHashAddEntry()
> that calls virHashAddOrUpdateEntry()
> 
> When the pci address of two drivers are the same, virHashAddOrUpdateEntry() will fail.
>     if (found) {
>         if (is_update) {
>             if (table->dataFree)
>                 table->dataFree(insert->payload, insert->name);
>             insert->payload = userdata;
>             return (0);
>         } else {
>             return (-1);  <==== we do not report error here.
>         }
>     }

Then, do you have recomendation ? Just retuns error without any hint
is bad behavior.

Thanks,
-Kame




More information about the libvir-list mailing list