mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 08:13:54 -06:00
migration: move only_migratable to MigrationState
One less global variable, and it does only matter with migration. We keep the old "--only-migratable" option, but also now we support: -global migration.only-migratable=true Currently still keep the old interface. Hmm, now vl.c has no way to access migrate_get_current(). Export a function for it to setup only_migratable. Reviewed-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Peter Xu <peterx@redhat.com> Message-Id: <1498536619-14548-7-git-send-email-peterx@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
This commit is contained in:
parent
5272298c48
commit
3df663e575
6 changed files with 20 additions and 5 deletions
|
@ -2336,7 +2336,7 @@ void vmstate_register_ram_global(MemoryRegion *mr)
|
|||
bool vmstate_check_only_migratable(const VMStateDescription *vmsd)
|
||||
{
|
||||
/* check needed if --only-migratable is specified */
|
||||
if (!only_migratable) {
|
||||
if (!migrate_get_current()->only_migratable) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue