Re: [PATCH v2 05/10] qemu_hotplug: generate ccw address list on demand

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Jul 23, 2016 at 03:47:10AM +0200, Tomasz Flendrich wrote:
Dropping the caching of ccw address set.
Instead of using the cached address set, functions in qemu_hotplug.c
now recalculate it on demand.
---
src/qemu/qemu_hotplug.c | 26 +++++++++++++++++++++-----
1 file changed, 21 insertions(+), 5 deletions(-)

diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c
index 5c82361..3deeb0b 100644
--- a/src/qemu/qemu_hotplug.c
+++ b/src/qemu/qemu_hotplug.c
@@ -337,7 +338,9 @@ qemuDomainAttachVirtioDiskDevice(virConnectPtr conn,
        goto cleanup;

    if (disk->info.type == VIR_DOMAIN_DEVICE_ADDRESS_TYPE_CCW) {
-        if (virDomainCCWAddressAssign(&disk->info, priv->ccwaddrs,
+        if (!(ccwaddrs = qemuDomainCCWAddrSetCreateFromDomain(vm->def)))
+            goto error;
+        if (virDomainCCWAddressAssign(&disk->info, ccwaddrs,
                                      !disk->info.addr.ccw.assigned) < 0)

Ideally, we would create a wrapper for these two functions but that's
just a nit for the future.  Also just a guess, maybe it'll turn out that
we won't need it at all...

ACK

Attachment: signature.asc
Description: Digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]