8dca018b68
Mostly minor changes, bigger ones summarized: * QEMU's internal backup code now uses a new async system, which allows parallel requests - the default max_workers settings is 64, I chose less, since 64 put enough stress on QEMU that the guest became practically unusable during the backup, and 16 still shows quite a nice measureable performance improvement. Little code changes for us though. * 'malformed' QAPI parameters/functions are now a build error (i.e. using '_' vs '-'), I chose to just whitelist our calls in the name of backwards compatibility. * monitor OOB race fix now uses the upstream variant, cherry-picked from origin/master since it's not in 6.0 by default * last patch fixes a bug with snapshot rollback related to the new yank system Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
54 lines
2.0 KiB
Diff
54 lines
2.0 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Dietmar Maurer <dietmar@proxmox.com>
|
|
Date: Mon, 6 Apr 2020 12:16:44 +0200
|
|
Subject: [PATCH] PVE: qapi: modify query machines
|
|
|
|
provide '*is-current' in MachineInfo struct
|
|
|
|
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
|
Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
|
|
---
|
|
hw/core/machine-qmp-cmds.c | 6 ++++++
|
|
qapi/machine.json | 4 +++-
|
|
2 files changed, 9 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/hw/core/machine-qmp-cmds.c b/hw/core/machine-qmp-cmds.c
|
|
index 68a942595a..76195de9e0 100644
|
|
--- a/hw/core/machine-qmp-cmds.c
|
|
+++ b/hw/core/machine-qmp-cmds.c
|
|
@@ -100,6 +100,12 @@ MachineInfoList *qmp_query_machines(Error **errp)
|
|
info->hotpluggable_cpus = mc->has_hotpluggable_cpus;
|
|
info->numa_mem_supported = mc->numa_mem_supported;
|
|
info->deprecated = !!mc->deprecation_reason;
|
|
+
|
|
+ if (strcmp(mc->name, MACHINE_GET_CLASS(current_machine)->name) == 0) {
|
|
+ info->has_is_current = true;
|
|
+ info->is_current = true;
|
|
+ }
|
|
+
|
|
if (mc->default_cpu_type) {
|
|
info->default_cpu_type = g_strdup(mc->default_cpu_type);
|
|
info->has_default_cpu_type = true;
|
|
diff --git a/qapi/machine.json b/qapi/machine.json
|
|
index f8da4a0d98..6e7e93d68f 100644
|
|
--- a/qapi/machine.json
|
|
+++ b/qapi/machine.json
|
|
@@ -141,6 +141,8 @@
|
|
#
|
|
# @is-default: whether the machine is default
|
|
#
|
|
+# @is-current: whether this machine is currently used
|
|
+#
|
|
# @cpu-max: maximum number of CPUs supported by the machine type
|
|
# (since 1.5)
|
|
#
|
|
@@ -162,7 +164,7 @@
|
|
##
|
|
{ 'struct': 'MachineInfo',
|
|
'data': { 'name': 'str', '*alias': 'str',
|
|
- '*is-default': 'bool', 'cpu-max': 'int',
|
|
+ '*is-default': 'bool', '*is-current': 'bool', 'cpu-max': 'int',
|
|
'hotpluggable-cpus': 'bool', 'numa-mem-supported': 'bool',
|
|
'deprecated': 'bool', '*default-cpu-type': 'str',
|
|
'*default-ram-id': 'str' } }
|