render / rpms / libvirt

Forked from rpms/libvirt 9 months ago
Clone
3e5111
From 93313904b77e40a1ebb7b0cf6fdcadf34d6cb175 Mon Sep 17 00:00:00 2001
3e5111
Message-Id: <93313904b77e40a1ebb7b0cf6fdcadf34d6cb175@dist-git>
3e5111
From: Jiri Denemark <jdenemar@redhat.com>
3e5111
Date: Tue, 4 Apr 2017 19:43:13 +0200
3e5111
Subject: [PATCH] qemu: Properly reset TLS in qemuProcessRecoverMigrationIn
3e5111
3e5111
There is no async job running when a freshly started libvirtd is trying
3e5111
to recover from an interrupted incoming migration. While at it, let's
3e5111
call qemuMigrationResetTLS every time we don't kill the domain. This is
3e5111
not strictly necessary since TLS is not supported when v2 migration
3e5111
protocol is used, but doing so makes more sense.
3e5111
3e5111
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
3e5111
(cherry picked from commit 59b28ecab845adb6fefe3280675f95d1f2135e3b)
3e5111
3e5111
https://bugzilla.redhat.com/show_bug.cgi?id=1425003
3e5111
3e5111
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
3e5111
---
3e5111
 src/qemu/qemu_process.c | 4 +---
3e5111
 1 file changed, 1 insertion(+), 3 deletions(-)
3e5111
3e5111
diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c
3e5111
index 039b3911c..0b9b4f76a 100644
3e5111
--- a/src/qemu/qemu_process.c
3e5111
+++ b/src/qemu/qemu_process.c
3e5111
@@ -2973,9 +2973,6 @@ qemuProcessRecoverMigrationIn(virQEMUDriverPtr driver,
3e5111
         /* migration finished, we started resuming the domain but didn't
3e5111
          * confirm success or failure yet; killing it seems safest unless
3e5111
          * we already started guest CPUs or we were in post-copy mode */
3e5111
-        ignore_value(qemuMigrationResetTLS(driver, vm,
3e5111
-                                           QEMU_ASYNC_JOB_MIGRATION_IN,
3e5111
-                                           NULL, NULL));
3e5111
         if (postcopy) {
3e5111
             qemuMigrationPostcopyFailed(driver, vm);
3e5111
         } else if (state != VIR_DOMAIN_RUNNING) {
3e5111
@@ -2985,6 +2982,7 @@ qemuProcessRecoverMigrationIn(virQEMUDriverPtr driver,
3e5111
         break;
3e5111
     }
3e5111
 
3e5111
+    qemuMigrationResetTLS(driver, vm, QEMU_ASYNC_JOB_NONE, NULL, NULL);
3e5111
     return 0;
3e5111
 }
3e5111
 
3e5111
-- 
3e5111
2.12.2
3e5111