diff options
author | Andreas Färber <afaerber@suse.de> | 2012-12-23 00:39:34 +0100 |
---|---|---|
committer | Andreas Färber <afaerber@suse.de> | 2012-12-23 00:40:49 +0100 |
commit | 501a7ce7270955be151c442c27620fa7af2f3ce5 (patch) | |
tree | 0374e4d581a0246074d55712b81baf01f3c439b6 /savevm.c | |
parent | 62e0c095450f6a7eb37914991f3f7966aa4da7a1 (diff) | |
parent | 36f25d2537c40c6c47f4abee5d31a24863d1adf7 (diff) | |
download | qemu-501a7ce7270955be151c442c27620fa7af2f3ce5.zip qemu-501a7ce7270955be151c442c27620fa7af2f3ce5.tar.gz qemu-501a7ce7270955be151c442c27620fa7af2f3ce5.tar.bz2 |
Merge branch 'master' of git://git.qemu.org/qemu into qom-cpu
Adapt header include paths.
Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'savevm.c')
-rw-r--r-- | savevm.c | 47 |
1 files changed, 30 insertions, 17 deletions
@@ -72,21 +72,20 @@ #include "qemu-common.h" #include "hw/hw.h" #include "hw/qdev.h" -#include "net.h" -#include "monitor.h" -#include "sysemu.h" -#include "qemu-timer.h" -#include "qemu-char.h" +#include "net/net.h" +#include "monitor/monitor.h" +#include "sysemu/sysemu.h" +#include "qemu/timer.h" #include "audio/audio.h" -#include "migration.h" -#include "qemu_socket.h" -#include "qemu-queue.h" -#include "qemu-timer.h" -#include "cpus.h" -#include "memory.h" +#include "migration/migration.h" +#include "qemu/sockets.h" +#include "qemu/queue.h" +#include "qemu/timer.h" +#include "sysemu/cpus.h" +#include "exec/memory.h" #include "qmp-commands.h" #include "trace.h" -#include "bitops.h" +#include "qemu/bitops.h" #define SELF_ANNOUNCE_ROUNDS 5 @@ -556,11 +555,6 @@ int qemu_fclose(QEMUFile *f) return ret; } -int qemu_file_put_notify(QEMUFile *f) -{ - return f->ops->put_buffer(f->opaque, NULL, 0, 0); -} - void qemu_put_buffer(QEMUFile *f, const uint8_t *buf, int size) { int l; @@ -1759,6 +1753,25 @@ int qemu_savevm_state_complete(QEMUFile *f) return qemu_file_get_error(f); } +uint64_t qemu_savevm_state_pending(QEMUFile *f, uint64_t max_size) +{ + SaveStateEntry *se; + uint64_t ret = 0; + + QTAILQ_FOREACH(se, &savevm_handlers, entry) { + if (!se->ops || !se->ops->save_live_pending) { + continue; + } + if (se->ops && se->ops->is_active) { + if (!se->ops->is_active(se->opaque)) { + continue; + } + } + ret += se->ops->save_live_pending(f, se->opaque, max_size); + } + return ret; +} + void qemu_savevm_state_cancel(QEMUFile *f) { SaveStateEntry *se; |