diff options
author | Fabiano Rosas <farosas@suse.de> | 2024-04-30 11:27:33 -0300 |
---|---|---|
committer | Fabiano Rosas <farosas@suse.de> | 2024-05-08 09:20:58 -0300 |
commit | 61c4e39f7301f67408024346ad3eb5335aec0311 (patch) | |
tree | 32d0cbc7db41d2a8152025440e12a4005d7adc5a /migration/migration.c | |
parent | f7b1cd3c2ebbc102b8edfacd5c5cd10c04dc887d (diff) |
migration: Remove 'inc' option from migrate command
The block incremental option for block migration has been deprecated
in 8.2 in favor of using the block-mirror feature. Remove it now.
Deprecation commit 40101f320d ("migration: migrate 'inc' command
option is deprecated.").
Reviewed-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
Diffstat (limited to 'migration/migration.c')
-rw-r--r-- | migration/migration.c | 24 |
1 files changed, 7 insertions, 17 deletions
diff --git a/migration/migration.c b/migration/migration.c index a4be929e40..11a13fa20c 100644 --- a/migration/migration.c +++ b/migration/migration.c @@ -1935,14 +1935,9 @@ bool migration_is_blocked(Error **errp) } /* Returns true if continue to migrate, or false if error detected */ -static bool migrate_prepare(MigrationState *s, bool blk, bool blk_inc, - bool resume, Error **errp) +static bool migrate_prepare(MigrationState *s, bool blk, bool resume, + Error **errp) { - if (blk_inc) { - warn_report("parameter 'inc' is deprecated;" - " use blockdev-mirror with NBD instead"); - } - if (blk) { warn_report("parameter 'blk' is deprecated;" " use blockdev-mirror with NBD instead"); @@ -2032,12 +2027,12 @@ static bool migrate_prepare(MigrationState *s, bool blk, bool blk_inc, } } - if (blk || blk_inc) { + if (blk) { if (migrate_colo()) { error_setg(errp, "No disk migration is required in COLO mode"); return false; } - if (migrate_block() || migrate_block_incremental()) { + if (migrate_block()) { error_setg(errp, "Command options are incompatible with " "current migration capabilities"); return false; @@ -2048,10 +2043,6 @@ static bool migrate_prepare(MigrationState *s, bool blk, bool blk_inc, s->must_remove_block_options = true; } - if (blk_inc) { - migrate_set_block_incremental(true); - } - if (migrate_init(s, errp)) { return false; } @@ -2061,8 +2052,8 @@ static bool migrate_prepare(MigrationState *s, bool blk, bool blk_inc, void qmp_migrate(const char *uri, bool has_channels, MigrationChannelList *channels, bool has_blk, bool blk, - bool has_inc, bool inc, bool has_detach, bool detach, - bool has_resume, bool resume, Error **errp) + bool has_detach, bool detach, bool has_resume, bool resume, + Error **errp) { bool resume_requested; Error *local_err = NULL; @@ -2101,8 +2092,7 @@ void qmp_migrate(const char *uri, bool has_channels, } resume_requested = has_resume && resume; - if (!migrate_prepare(s, has_blk && blk, has_inc && inc, - resume_requested, errp)) { + if (!migrate_prepare(s, has_blk && blk, resume_requested, errp)) { /* Error detected, put into errp */ return; } |