From f8bbc1286337a8506162b5785babe6f2a7de2476 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Fri, 22 Feb 2013 17:36:41 +0100 Subject: migration: use QEMUFile for migration channel lifetime As a start, use QEMUFile to store the destination and close it. qemu_get_fd gets a file descriptor that will be used by the write callbacks. Reviewed-by: Orit Wasserman Reviewed-by: Juan Quintela Signed-off-by: Paolo Bonzini Signed-off-by: Juan Quintela --- include/migration/migration.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/migration/migration.h b/include/migration/migration.h index cec8643870..1f8f305ac9 100644 --- a/include/migration/migration.h +++ b/include/migration/migration.h @@ -38,12 +38,13 @@ struct MigrationState QEMUBH *cleanup_bh; QEMUFile *file; + QEMUFile *migration_file; + int fd; - int state; int (*get_error)(MigrationState *s); - int (*close)(MigrationState *s); int (*write)(MigrationState *s, const void *buff, size_t size); - void *opaque; + + int state; MigrationParams params; int64_t total_time; int64_t downtime; -- cgit v1.2.3