]> git.proxmox.com Git - mirror_qemu.git/blob - migration/savevm.h
Merge remote-tracking branch 'remotes/juanquintela/tags/migration/20170531' into...
[mirror_qemu.git] / migration / savevm.h
1 /*
2 * QEMU save vm functions
3 *
4 * Copyright (c) 2003-2008 Fabrice Bellard
5 * Copyright (c) 2009-2017 Red Hat Inc
6 *
7 * Authors:
8 * Juan Quintela <quintela@redhat.com>
9 *
10 * This work is licensed under the terms of the GNU GPL, version 2 or later.
11 * See the COPYING file in the top-level directory.
12 */
13
14 #ifndef MIGRATION_SAVEVM_H
15 #define MIGRATION_SAVEVM_H
16
17 bool qemu_savevm_state_blocked(Error **errp);
18 void qemu_savevm_state_begin(QEMUFile *f);
19 void qemu_savevm_state_header(QEMUFile *f);
20 int qemu_savevm_state_iterate(QEMUFile *f, bool postcopy);
21 void qemu_savevm_state_cleanup(void);
22 void qemu_savevm_state_complete_postcopy(QEMUFile *f);
23 void qemu_savevm_state_complete_precopy(QEMUFile *f, bool iterable_only);
24 void qemu_savevm_state_pending(QEMUFile *f, uint64_t max_size,
25 uint64_t *res_non_postcopiable,
26 uint64_t *res_postcopiable);
27 void qemu_savevm_send_ping(QEMUFile *f, uint32_t value);
28 void qemu_savevm_send_open_return_path(QEMUFile *f);
29 int qemu_savevm_send_packaged(QEMUFile *f, const uint8_t *buf, size_t len);
30 void qemu_savevm_send_postcopy_advise(QEMUFile *f);
31 void qemu_savevm_send_postcopy_listen(QEMUFile *f);
32 void qemu_savevm_send_postcopy_run(QEMUFile *f);
33
34 void qemu_savevm_send_postcopy_ram_discard(QEMUFile *f, const char *name,
35 uint16_t len,
36 uint64_t *start_list,
37 uint64_t *length_list);
38
39 int qemu_loadvm_state(QEMUFile *f);
40
41 #endif