Skip to content

Commit

Permalink
migration: Move constants to savevm.h
Browse files Browse the repository at this point in the history
Signed-off-by: Juan Quintela <[email protected]>
Reviewed-by: Philippe Mathieu-Daudé <[email protected]>
Reviewed-by: Laurent Vivier <[email protected]>
  • Loading branch information
Juan Quintela committed Jun 13, 2017
1 parent b772274 commit c3d2e2e
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 15 deletions.
15 changes: 0 additions & 15 deletions include/migration/migration.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,21 +22,6 @@
#include "exec/cpu-common.h"
#include "qemu/coroutine_int.h"

#define QEMU_VM_FILE_MAGIC 0x5145564d
#define QEMU_VM_FILE_VERSION_COMPAT 0x00000002
#define QEMU_VM_FILE_VERSION 0x00000003

#define QEMU_VM_EOF 0x00
#define QEMU_VM_SECTION_START 0x01
#define QEMU_VM_SECTION_PART 0x02
#define QEMU_VM_SECTION_END 0x03
#define QEMU_VM_SECTION_FULL 0x04
#define QEMU_VM_SUBSECTION 0x05
#define QEMU_VM_VMDESCRIPTION 0x06
#define QEMU_VM_CONFIGURATION 0x07
#define QEMU_VM_COMMAND 0x08
#define QEMU_VM_SECTION_FOOTER 0x7e

/* Messages sent on the return path from destination to source */
enum mig_rp_message_type {
MIG_RP_MSG_INVALID = 0, /* Must be 0 */
Expand Down
15 changes: 15 additions & 0 deletions migration/savevm.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,21 @@
#ifndef MIGRATION_SAVEVM_H
#define MIGRATION_SAVEVM_H

#define QEMU_VM_FILE_MAGIC 0x5145564d
#define QEMU_VM_FILE_VERSION_COMPAT 0x00000002
#define QEMU_VM_FILE_VERSION 0x00000003

#define QEMU_VM_EOF 0x00
#define QEMU_VM_SECTION_START 0x01
#define QEMU_VM_SECTION_PART 0x02
#define QEMU_VM_SECTION_END 0x03
#define QEMU_VM_SECTION_FULL 0x04
#define QEMU_VM_SUBSECTION 0x05
#define QEMU_VM_VMDESCRIPTION 0x06
#define QEMU_VM_CONFIGURATION 0x07
#define QEMU_VM_COMMAND 0x08
#define QEMU_VM_SECTION_FOOTER 0x7e

bool qemu_savevm_state_blocked(Error **errp);
void qemu_savevm_state_begin(QEMUFile *f);
void qemu_savevm_state_header(QEMUFile *f);
Expand Down
1 change: 1 addition & 0 deletions migration/vmstate.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
#include "qemu-common.h"
#include "migration/migration.h"
#include "migration/vmstate.h"
#include "migration/savevm.h"
#include "qemu-file.h"
#include "qemu/bitops.h"
#include "qemu/error-report.h"
Expand Down
1 change: 1 addition & 0 deletions tests/test-vmstate.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
#include "migration/qemu-file-types.h"
#include "../migration/qemu-file.h"
#include "../migration/qemu-file-channel.h"
#include "../migration/savevm.h"
#include "qemu/coroutine.h"
#include "io/channel-file.h"

Expand Down

0 comments on commit c3d2e2e

Please sign in to comment.