mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 07:43:54 -06:00
migration: Allow to suppress vmdesc submission
We now always send a JSON blob describing the migration file format as part of the migration stream. However, some tools built around QEMU have proven to stumble over this. This patch gives the user the chance to disable said self-describing part of the migration stream. To disable vmdesc submission, just add -machine suppress-vmdesc=on to your QEMU command line. Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: Juan Quintela <quintela@redhat.com>
This commit is contained in:
parent
1925cebc4b
commit
9850c6047b
4 changed files with 34 additions and 4 deletions
|
@ -254,6 +254,20 @@ static void machine_set_iommu(Object *obj, bool value, Error **errp)
|
|||
ms->iommu = value;
|
||||
}
|
||||
|
||||
static void machine_set_suppress_vmdesc(Object *obj, bool value, Error **errp)
|
||||
{
|
||||
MachineState *ms = MACHINE(obj);
|
||||
|
||||
ms->suppress_vmdesc = value;
|
||||
}
|
||||
|
||||
static bool machine_get_suppress_vmdesc(Object *obj, Error **errp)
|
||||
{
|
||||
MachineState *ms = MACHINE(obj);
|
||||
|
||||
return ms->suppress_vmdesc;
|
||||
}
|
||||
|
||||
static int error_on_sysbus_device(SysBusDevice *sbdev, void *opaque)
|
||||
{
|
||||
error_report("Option '-device %s' cannot be handled by this machine",
|
||||
|
@ -377,6 +391,12 @@ static void machine_initfn(Object *obj)
|
|||
object_property_set_description(obj, "iommu",
|
||||
"Set on/off to enable/disable Intel IOMMU (VT-d)",
|
||||
NULL);
|
||||
object_property_add_bool(obj, "suppress-vmdesc",
|
||||
machine_get_suppress_vmdesc,
|
||||
machine_set_suppress_vmdesc, NULL);
|
||||
object_property_set_description(obj, "suppress-vmdesc",
|
||||
"Set on to disable self-describing migration",
|
||||
NULL);
|
||||
|
||||
/* Register notifier when init is done for sysbus sanity checks */
|
||||
ms->sysbus_notifier.notify = machine_init_notify;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue