Set the 'block' migration capability to 'true' instead.
Signed-off-by: Juan Quintela <quintela(a)redhat.com>
---
docs/about/deprecated.rst | 7 +++++++
qapi/migration.json | 10 +++++++---
migration/migration.c | 5 +++++
3 files changed, 19 insertions(+), 3 deletions(-)
diff --git a/docs/about/deprecated.rst b/docs/about/deprecated.rst
index cc0001041f..f727db958e 100644
--- a/docs/about/deprecated.rst
+++ b/docs/about/deprecated.rst
@@ -440,3 +440,10 @@ The new way to modify migration is using migration parameters.
``inc`` functionality can be achieved by setting the
``block-incremental`` migration parameter to ``true``.
+``blk`` migrate command option (since 8.1)
+''''''''''''''''''''''''''''''''''''''''''
+
+The new way to modify migration is using migration parameters.
+``blk`` functionality can be achieved by setting the
+``block`` migration capability to ``true``.
+
diff --git a/qapi/migration.json b/qapi/migration.json
index 8b30f748ef..291af9407e 100644
--- a/qapi/migration.json
+++ b/qapi/migration.json
@@ -1477,7 +1477,9 @@
#
# @uri: the Uniform Resource Identifier of the destination VM
#
-# @blk: do block migration (full disk copy)
+# @blk: do block migration (full disk copy). This option is
+# deprecated. Set the 'block' migration capability to 'true'
+# instead.
#
# @inc: incremental disk copy migration. This option is deprecated.
# Set the 'block-incremetantal' migration parameter to 'true'
@@ -1491,7 +1493,8 @@
# Features:
#
# @deprecated: option @inc should be enabled by setting the
-# 'block-incremental' migration parameter to 'true'.
+# 'block-incremental' migration parameter to 'true', option @blk
+# should be enabled by setting the 'block' capability to 'true'.
#
# Returns: nothing on success
#
@@ -1514,7 +1517,8 @@
# <- { "return": {} }
##
{ 'command': 'migrate',
- 'data': {'uri': 'str', '*blk': 'bool',
+ 'data': {'uri': 'str',
+ '*blk': { 'type': 'bool', 'features':
['deprecated'] },
'*inc': { 'type': 'bool', 'features':
['deprecated'] },
'*detach': 'bool', '*resume': 'bool' } }
diff --git a/migration/migration.c b/migration/migration.c
index abc40e6ef6..4c7e8ff5ee 100644
--- a/migration/migration.c
+++ b/migration/migration.c
@@ -1563,6 +1563,11 @@ static bool migrate_prepare(MigrationState *s, bool blk, bool
blk_inc,
" instead.");
}
+ if (blk) {
+ warn_report("-blk migrate option is deprecated, set the "
+ "'block' capability to 'true' instead.");
+ }
+
if (resume) {
if (s->state != MIGRATION_STATUS_POSTCOPY_PAUSED) {
error_setg(errp, "Cannot resume if there is no "
--
2.40.1