}
/* Returns true if continue to migrate, or false if error detected */
-static bool migrate_prepare(MigrationState *s, bool blk, bool resume,
- Error **errp)
+static bool migrate_prepare(MigrationState *s, bool resume, Error **errp)
{
- if (blk) {
- warn_report("parameter 'blk' is deprecated;"
- " use blockdev-mirror with NBD instead");
- }
-
if (resume) {
if (s->state != MIGRATION_STATUS_POSTCOPY_PAUSED) {
error_setg(errp, "Cannot resume if there is no "
}
}
- if (blk) {
- if (migrate_colo()) {
- error_setg(errp, "No disk migration is required in COLO mode");
- return false;
- }
- if (migrate_block()) {
- error_setg(errp, "Command options are incompatible with "
- "current migration capabilities");
- return false;
- }
- if (!migrate_cap_set(MIGRATION_CAPABILITY_BLOCK, true, errp)) {
- return false;
- }
- s->must_remove_block_options = true;
- }
-
if (migrate_init(s, errp)) {
return false;
}
}
void qmp_migrate(const char *uri, bool has_channels,
- MigrationChannelList *channels, bool has_blk, bool blk,
- bool has_detach, bool detach, bool has_resume, bool resume,
- Error **errp)
+ MigrationChannelList *channels, bool has_detach, bool detach,
+ bool has_resume, bool resume, Error **errp)
{
bool resume_requested;
Error *local_err = NULL;
}
resume_requested = has_resume && resume;
- if (!migrate_prepare(s, has_blk && blk, resume_requested, errp)) {
+ if (!migrate_prepare(s, resume_requested, errp)) {
/* Error detected, put into errp */
return;
}