diff options
author | Juan Quintela <quintela@redhat.com> | 2023-02-22 17:18:05 +0100 |
---|---|---|
committer | Juan Quintela <quintela@redhat.com> | 2023-04-24 15:01:46 +0200 |
commit | c938157713e723165a42cb6e8364adb6fcbd0e22 (patch) | |
tree | 832551053912293e9e61f3e24a32801690ba58ce /migration | |
parent | 5d39f44d7ac5c63f53d4d0900ceba9521bc27e49 (diff) | |
download | qemu-c938157713e723165a42cb6e8364adb6fcbd0e22.zip qemu-c938157713e723165a42cb6e8364adb6fcbd0e22.tar.gz qemu-c938157713e723165a42cb6e8364adb6fcbd0e22.tar.bz2 |
migration: move migration_global_dump() to migration-hmp-cmds.c
It is only used there, so we can make it static.
Once there, remove spice.h that it is not used.
Signed-off-by: Juan Quintela <quintela@redhat.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
fix David Edmonson ui/qemu-spice.h unintended removal
Diffstat (limited to 'migration')
-rw-r--r-- | migration/migration-hmp-cmds.c | 22 | ||||
-rw-r--r-- | migration/migration.c | 19 |
2 files changed, 21 insertions, 20 deletions
diff --git a/migration/migration-hmp-cmds.c b/migration/migration-hmp-cmds.c index 72519ea..71da919 100644 --- a/migration/migration-hmp-cmds.c +++ b/migration/migration-hmp-cmds.c @@ -15,7 +15,6 @@ #include "qemu/osdep.h" #include "block/qapi.h" -#include "migration/misc.h" #include "migration/snapshot.h" #include "monitor/hmp.h" #include "monitor/monitor.h" @@ -30,6 +29,27 @@ #include "qemu/sockets.h" #include "sysemu/runstate.h" #include "ui/qemu-spice.h" +#include "sysemu/sysemu.h" +#include "migration.h" + +static void migration_global_dump(Monitor *mon) +{ + MigrationState *ms = migrate_get_current(); + + monitor_printf(mon, "globals:\n"); + monitor_printf(mon, "store-global-state: %s\n", + ms->store_global_state ? "on" : "off"); + monitor_printf(mon, "only-migratable: %s\n", + only_migratable ? "on" : "off"); + monitor_printf(mon, "send-configuration: %s\n", + ms->send_configuration ? "on" : "off"); + monitor_printf(mon, "send-section-footer: %s\n", + ms->send_section_footer ? "on" : "off"); + monitor_printf(mon, "decompress-error-check: %s\n", + ms->decompress_error_check ? "on" : "off"); + monitor_printf(mon, "clear-bitmap-shift: %u\n", + ms->clear_bitmap_shift); +} void hmp_info_migrate(Monitor *mon, const QDict *qdict) { diff --git a/migration/migration.c b/migration/migration.c index 9ec6c1e..a867631 100644 --- a/migration/migration.c +++ b/migration/migration.c @@ -4416,25 +4416,6 @@ void migrate_fd_connect(MigrationState *s, Error *error_in) s->migration_thread_running = true; } -void migration_global_dump(Monitor *mon) -{ - MigrationState *ms = migrate_get_current(); - - monitor_printf(mon, "globals:\n"); - monitor_printf(mon, "store-global-state: %s\n", - ms->store_global_state ? "on" : "off"); - monitor_printf(mon, "only-migratable: %s\n", - only_migratable ? "on" : "off"); - monitor_printf(mon, "send-configuration: %s\n", - ms->send_configuration ? "on" : "off"); - monitor_printf(mon, "send-section-footer: %s\n", - ms->send_section_footer ? "on" : "off"); - monitor_printf(mon, "decompress-error-check: %s\n", - ms->decompress_error_check ? "on" : "off"); - monitor_printf(mon, "clear-bitmap-shift: %u\n", - ms->clear_bitmap_shift); -} - #define DEFINE_PROP_MIG_CAP(name, x) \ DEFINE_PROP_BOOL(name, MigrationState, capabilities[x], false) |