Message ID | 20171220154945.88410-7-vsementsov@virtuozzo.com |
---|---|
State | New |
Headers | show |
Series | None | expand |
On Wed, 12/20 18:49, Vladimir Sementsov-Ogievskiy wrote: > Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> > Reviewed-by: John Snow <jsnow@redhat.com> > Reviewed-by: Eric Blake <eblake@redhat.com> > Reviewed-by: Juan Quintela <quintela@redhat.com> > --- > qapi/migration.json | 6 +++++- > migration/migration.h | 1 + > migration/migration.c | 9 +++++++++ > 3 files changed, 15 insertions(+), 1 deletion(-) > > diff --git a/qapi/migration.json b/qapi/migration.json > index 03f57c9616..9f20b645a7 100644 > --- a/qapi/migration.json > +++ b/qapi/migration.json > @@ -352,12 +352,16 @@ > # > # @x-multifd: Use more than one fd for migration (since 2.11) > # > +# @dirty-bitmaps: If enabled, QEMU will migrate named dirty bitmaps. > +# (since 2.11) s/2.11/2.12/ But it should be fine to keep all r-b lines when you update that, and add one more: Reviewed-by: Fam Zheng <famz@redhat.com>
diff --git a/qapi/migration.json b/qapi/migration.json index 03f57c9616..9f20b645a7 100644 --- a/qapi/migration.json +++ b/qapi/migration.json @@ -352,12 +352,16 @@ # # @x-multifd: Use more than one fd for migration (since 2.11) # +# @dirty-bitmaps: If enabled, QEMU will migrate named dirty bitmaps. +# (since 2.11) +# # Since: 1.2 ## { 'enum': 'MigrationCapability', 'data': ['xbzrle', 'rdma-pin-all', 'auto-converge', 'zero-blocks', 'compress', 'events', 'postcopy-ram', 'x-colo', 'release-ram', - 'block', 'return-path', 'pause-before-switchover', 'x-multifd' ] } + 'block', 'return-path', 'pause-before-switchover', 'x-multifd', + 'dirty-bitmaps' ] } ## # @MigrationCapabilityStatus: diff --git a/migration/migration.h b/migration/migration.h index 663415fe48..50d1f01346 100644 --- a/migration/migration.h +++ b/migration/migration.h @@ -181,6 +181,7 @@ bool migrate_postcopy(void); bool migrate_release_ram(void); bool migrate_postcopy_ram(void); bool migrate_zero_blocks(void); +bool migrate_dirty_bitmaps(void); bool migrate_auto_converge(void); bool migrate_use_multifd(void); diff --git a/migration/migration.c b/migration/migration.c index e6c9be3cca..1526cd4bff 100644 --- a/migration/migration.c +++ b/migration/migration.c @@ -1544,6 +1544,15 @@ int migrate_decompress_threads(void) return s->parameters.decompress_threads; } +bool migrate_dirty_bitmaps(void) +{ + MigrationState *s; + + s = migrate_get_current(); + + return s->enabled_capabilities[MIGRATION_CAPABILITY_DIRTY_BITMAPS]; +} + bool migrate_use_events(void) { MigrationState *s;