[PATCH v2 07/29] migration: Run "file:" migration with a stopped VM

Fabiano Rosas posted 29 patches 2 years, 2 months ago
Maintainers: Juan Quintela <quintela@redhat.com>, Peter Xu <peterx@redhat.com>, Fabiano Rosas <farosas@suse.de>, Leonardo Bras <leobras@redhat.com>, Paolo Bonzini <pbonzini@redhat.com>, David Hildenbrand <david@redhat.com>, "Philippe Mathieu-Daudé" <philmd@linaro.org>, "Daniel P. Berrangé" <berrange@redhat.com>, Eric Blake <eblake@redhat.com>, Markus Armbruster <armbru@redhat.com>, Thomas Huth <thuth@redhat.com>, Laurent Vivier <lvivier@redhat.com>
There is a newer version of this series
[PATCH v2 07/29] migration: Run "file:" migration with a stopped VM
Posted by Fabiano Rosas 2 years, 2 months ago
The file migration is asynchronous, so it benefits from being done
with a stopped VM. Allow the file migration to take benefit of the
auto-pause capability.

Signed-off-by: Fabiano Rosas <farosas@suse.de>
---
 migration/migration.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/migration/migration.c b/migration/migration.c
index 8b0c3b0911..692fbc5ad6 100644
--- a/migration/migration.c
+++ b/migration/migration.c
@@ -135,6 +135,10 @@ static bool migration_should_pause(const char *uri)
      * migration.
      */
 
+    if (strstart(uri, "file:", NULL)) {
+        return true;
+    }
+
     return false;
 }
 
-- 
2.35.3