On 05/17/2017 10:38 AM, Juan Quintela wrote: > Create one capability for block migration and one parameter for > incremental block migration. > > Signed-off-by: Juan Quintela > > --- > > @@ -1207,6 +1242,26 @@ void qmp_migrate(const char *uri, bool has_blk, bool blk, > return; > } > > + if (((has_blk && blk) || (has_inc && inc)) > + && (migrate_use_block() || migrate_use_block_incremental())) { > + error_setg(errp, "Command options are incompatible with current " > + "migration capabilities"); > + return; > + } > + > + if ((has_blk && blk) || (has_inc & inc)) { > + migrate_set_block_enabled(true, &local_err); > + if (local_err) { > + error_propagate(errp, local_err); > + return; > + } > + s->must_remove_block_options = true; > + } You wrote: if (A && B) { error; } if (A) { stuff; } I might have done: if (A) { if (B) { error; } stuff; } but it's the same either way. > +++ b/qapi-schema.json > @@ -894,11 +894,18 @@ > # @release-ram: if enabled, qemu will free the migrated ram pages on the source > # during postcopy-ram migration. (since 2.9) > # > +# @block: If enabled, QEMU will also migrate the contents of all block > +# devices. Default is disabled. A possible alternative are s/are/uses/ > +# mirror jobs to a builtin NBD server on the destination, which > +# are more flexible. s/are more flexible/offers more flexibility/ > +# (Since 2.10) > +# > # Since: 1.2 > ## > { 'enum': 'MigrationCapability', > 'data': ['xbzrle', 'rdma-pin-all', 'auto-converge', 'zero-blocks', > - 'compress', 'events', 'postcopy-ram', 'x-colo', 'release-ram'] } > + 'compress', 'events', 'postcopy-ram', 'x-colo', 'release-ram', > + 'block' ] } > The grammar touchups can be done in preparing the pull request, if there is no other reason for a respin. Reviewed-by: Eric Blake -- Eric Blake, Principal Software Engineer Red Hat, Inc. +1-919-301-3266 Virtualization: qemu.org | libvirt.org