aboutsummaryrefslogtreecommitdiff
path: root/migration/migration.c
diff options
context:
space:
mode:
authorAlexey Perevalov <a.perevalov@samsung.com>2018-03-22 21:17:22 +0300
committerDr. David Alan Gilbert <dgilbert@redhat.com>2018-04-25 18:02:12 +0100
commitf22f928ec929c425c5aa402b5cc4d6d1fa4be238 (patch)
tree9d1ced39355b3d2c1a6e7258538216ad60f84242 /migration/migration.c
parent4743c23509a51bd4ee85cc272287a41917d1be35 (diff)
downloadqemu-f22f928ec929c425c5aa402b5cc4d6d1fa4be238.zip
qemu-f22f928ec929c425c5aa402b5cc4d6d1fa4be238.tar.gz
qemu-f22f928ec929c425c5aa402b5cc4d6d1fa4be238.tar.bz2
migration: introduce postcopy-blocktime capability
Right now it could be used on destination side to enable vCPU blocktime calculation for postcopy live migration. vCPU blocktime - it's time since vCPU thread was put into interruptible sleep, till memory page was copied and thread awake. Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Signed-off-by: Alexey Perevalov <a.perevalov@samsung.com> Reviewed-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com> Message-Id: <1521742647-25550-2-git-send-email-a.perevalov@samsung.com> Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Diffstat (limited to 'migration/migration.c')
-rw-r--r--migration/migration.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/migration/migration.c b/migration/migration.c
index 52a5092..bf2e8db 100644
--- a/migration/migration.c
+++ b/migration/migration.c
@@ -1541,6 +1541,15 @@ bool migrate_zero_blocks(void)
return s->enabled_capabilities[MIGRATION_CAPABILITY_ZERO_BLOCKS];
}
+bool migrate_postcopy_blocktime(void)
+{
+ MigrationState *s;
+
+ s = migrate_get_current();
+
+ return s->enabled_capabilities[MIGRATION_CAPABILITY_POSTCOPY_BLOCKTIME];
+}
+
bool migrate_use_compression(void)
{
MigrationState *s;