diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2013-02-22 17:36:41 +0100 |
---|---|---|
committer | Juan Quintela <quintela@redhat.com> | 2013-03-11 13:32:02 +0100 |
commit | f8bbc1286337a8506162b5785babe6f2a7de2476 (patch) | |
tree | 15b6553d15211d4bc73afcfa1a18a3e4b875cc21 /include/migration | |
parent | 3f2d38faab97f4d676c41868a8243997b2aab7cb (diff) | |
download | hqemu-f8bbc1286337a8506162b5785babe6f2a7de2476.zip hqemu-f8bbc1286337a8506162b5785babe6f2a7de2476.tar.gz |
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 <owasserm@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Diffstat (limited to 'include/migration')
-rw-r--r-- | include/migration/migration.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/include/migration/migration.h b/include/migration/migration.h index cec8643..1f8f305 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; |