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

[libvirt] [PATCH 3/5] qemu: domain: Initialize proper element in qemuDomainPrepareStorageSourceBlockdev



We are preparing a certain disk source passed in as '@src' so the
individual functions should use that rather than disk->src which
corresponds to the top level element of the chain only.

Without this change TLS and persistent reservations would not work for
backing images of a chain when using -blockdev.

Signed-off-by: Peter Krempa <pkrempa redhat com>
---
 src/qemu/qemu_domain.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
index 77814a0c2a..382da53b7a 100644
--- a/src/qemu/qemu_domain.c
+++ b/src/qemu/qemu_domain.c
@@ -13462,10 +13462,10 @@ qemuDomainPrepareStorageSourceBlockdev(virDomainDiskDefPtr disk,
                                              src->nodeformat) < 0)
         return -1;

-    if (qemuDomainPrepareStorageSourcePR(disk->src, priv, src->nodestorage) < 0)
+    if (qemuDomainPrepareStorageSourcePR(src, priv, src->nodestorage) < 0)
         return -1;

-    if (qemuDomainPrepareStorageSourceTLS(disk->src, cfg, src->nodestorage,
+    if (qemuDomainPrepareStorageSourceTLS(src, cfg, src->nodestorage,
                                           priv->qemuCaps) < 0)
         return -1;

-- 
2.19.2


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