We require QEMU >= 0.15.0, assume every QEMU supports it.
Sadly that does not let us trivially drop qemuMonitor's
priv->monJSON bool, because of qemuDomainQemuAttach.
Signed-off-by: Ján Tomko <jtomko(a)redhat.com>
---
src/qemu/qemu_capabilities.c | 1 -
src/qemu/qemu_capabilities.h | 2 +-
src/qemu/qemu_command.c | 6 +-----
src/qemu/qemu_driver.c | 18 +++++++-----------
src/qemu/qemu_process.c | 2 +-
tests/qemucapabilitiesdata/caps_1.3.1.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_1.4.2.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_1.5.3.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_1.6.0.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_1.7.0.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.1.1.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.10.0.aarch64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.10.0.ppc64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.10.0.s390x.xml | 1 -
tests/qemucapabilitiesdata/caps_2.10.0.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.11.0.s390x.xml | 1 -
tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml | 1 -
tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.4.0.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.5.0.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.6.0.aarch64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.6.0.ppc64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.6.0.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.7.0.s390x.xml | 1 -
tests/qemucapabilitiesdata/caps_2.7.0.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.8.0.s390x.xml | 1 -
tests/qemucapabilitiesdata/caps_2.8.0.x86_64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.9.0.ppc64.xml | 1 -
tests/qemucapabilitiesdata/caps_2.9.0.s390x.xml | 1 -
tests/qemucapabilitiesdata/caps_2.9.0.x86_64.xml | 1 -
tests/qemuxml2argvdata/aarch64-aavmf-virtio-mmio.args | 2 +-
tests/qemuxml2argvdata/aarch64-acpi-uefi.args | 2 +-
[... lots of other args files]
tests/qemuxml2argvdata/watchdog-injectnmi.args | 2 +-
tests/qemuxml2argvdata/watchdog.args | 2 +-
tests/qemuxml2argvdata/x86-kvm-32-on-64.args | 2 +-
tests/qemuxml2argvtest.c | 14 ++++----------
634 files changed, 615 insertions(+), 657 deletions(-)
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
index f51364e58..334c3c135 100644
--- a/src/qemu/qemu_capabilities.c
+++ b/src/qemu/qemu_capabilities.c
@@ -3635,7 +3635,6 @@ virQEMUCapsInitQMPBasic(virQEMUCapsPtr qemuCaps)
{
virQEMUCapsSet(qemuCaps, QEMU_CAPS_MEM_PATH);
virQEMUCapsSet(qemuCaps, QEMU_CAPS_DRIVE_SERIAL);
- virQEMUCapsSet(qemuCaps, QEMU_CAPS_MONITOR_JSON);
virQEMUCapsSet(qemuCaps, QEMU_CAPS_SDL);
virQEMUCapsSet(qemuCaps, QEMU_CAPS_RTC);
virQEMUCapsSet(qemuCaps, QEMU_CAPS_VHOST_NET);
diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h
index 532024e72..df8c197cd 100644
--- a/src/qemu/qemu_capabilities.h
+++ b/src/qemu/qemu_capabilities.h
@@ -80,7 +80,7 @@ typedef enum {
X_QEMU_CAPS_MIGRATE_QEMU_UNIX, /* qemu migration via unix sockets */
X_QEMU_CAPS_CHARDEV, /* Is the new -chardev arg available */
QEMU_CAPS_ENABLE_KVM, /* -enable-kvm flag */
- QEMU_CAPS_MONITOR_JSON, /* JSON mode for monitor */
+ X_QEMU_CAPS_MONITOR_JSON, /* JSON mode for monitor */
/* 25 */
X_QEMU_CAPS_BALLOON, /* -balloon available */
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index 3dda9156d..8b883b208 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -1646,15 +1646,11 @@ qemuBuildDiskThrottling(virDomainDiskDefPtr disk,
static void
qemuBuildDiskFrontendAttributeErrorPolicy(virDomainDiskDefPtr disk,
- virQEMUCapsPtr qemuCaps,
virBufferPtr buf)
{
const char *wpolicy = NULL;
const char *rpolicy = NULL;
- if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_MONITOR_JSON))
- return;
-
if (disk->error_policy)
wpolicy = virDomainDiskErrorPolicyTypeToString(disk->error_policy);
@@ -1704,7 +1700,7 @@ qemuBuildDiskFrontendAttributes(virDomainDiskDefPtr disk,
virBufferEscape(buf, '\\', " ", "%s",
disk->serial);
}
- qemuBuildDiskFrontendAttributeErrorPolicy(disk, qemuCaps, buf);
+ qemuBuildDiskFrontendAttributeErrorPolicy(disk, buf);
}
diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
index 7bcc4936d..5a07da087 100644
--- a/src/qemu/qemu_driver.c
+++ b/src/qemu/qemu_driver.c
@@ -2123,19 +2123,15 @@ qemuDomainReboot(virDomainPtr dom, unsigned int flags)
if ((!useAgent) ||
(ret < 0 && (acpiRequested || !flags))) {
#if WITH_YAJL
- if (virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_MONITOR_JSON)) {
- if (!virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_NO_SHUTDOWN)) {
- virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
- _("ACPI reboot is not supported with this QEMU
binary"));
- goto endjob;
- }
- } else {
-#endif
- virReportError(VIR_ERR_OPERATION_INVALID, "%s",
- _("ACPI reboot is not supported without the JSON
monitor"));
+ if (!virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_NO_SHUTDOWN)) {
+ virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
+ _("ACPI reboot is not supported with this QEMU
binary"));
goto endjob;
-#if WITH_YAJL
}
+#else
+ virReportError(VIR_ERR_OPERATION_INVALID, "%s",
+ _("ACPI reboot is not supported without the JSON
monitor"));
+ goto endjob;
#endif
qemuDomainSetFakeReboot(driver, vm, isReboot);
qemuDomainObjEnterMonitor(driver, vm);
diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c
index 13c9e5a56..61e3be4e1 100644
--- a/src/qemu/qemu_process.c
+++ b/src/qemu/qemu_process.c
@@ -5717,7 +5717,7 @@ qemuProcessPrepareDomain(virQEMUDriverPtr driver,
if (qemuProcessPrepareMonitorChr(priv->monConfig, priv->libDir) < 0)
goto cleanup;
- priv->monJSON = virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_MONITOR_JSON);
+ priv->monJSON = true;
priv->monError = false;
priv->monStart = 0;
priv->gotShutdown = false;
diff --git a/tests/qemucapabilitiesdata/caps_1.3.1.x86_64.xml
b/tests/qemucapabilitiesdata/caps_1.3.1.x86_64.xml
index 3b667498a..ccd76cf8f 100644
--- a/tests/qemucapabilitiesdata/caps_1.3.1.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_1.3.1.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_1.4.2.x86_64.xml
b/tests/qemucapabilitiesdata/caps_1.4.2.x86_64.xml
index f84b7b9bb..7691d01ca 100644
--- a/tests/qemucapabilitiesdata/caps_1.4.2.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_1.4.2.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_1.5.3.x86_64.xml
b/tests/qemucapabilitiesdata/caps_1.5.3.x86_64.xml
index 983c2f75c..46b88f218 100644
--- a/tests/qemucapabilitiesdata/caps_1.5.3.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_1.5.3.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_1.6.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_1.6.0.x86_64.xml
index 751c9c005..47ac2eaf2 100644
--- a/tests/qemucapabilitiesdata/caps_1.6.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_1.6.0.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_1.7.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_1.7.0.x86_64.xml
index 792cdf77c..7b5ac5c4e 100644
--- a/tests/qemucapabilitiesdata/caps_1.7.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_1.7.0.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.1.1.x86_64.xml
b/tests/qemucapabilitiesdata/caps_2.1.1.x86_64.xml
index 4be6ccf18..69c7e2258 100644
--- a/tests/qemucapabilitiesdata/caps_2.1.1.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.1.1.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.10.0.aarch64.xml
b/tests/qemucapabilitiesdata/caps_2.10.0.aarch64.xml
index 91458b593..900f5fbbc 100644
--- a/tests/qemucapabilitiesdata/caps_2.10.0.aarch64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.10.0.aarch64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.10.0.ppc64.xml
b/tests/qemucapabilitiesdata/caps_2.10.0.ppc64.xml
index 7e843887a..8408a3476 100644
--- a/tests/qemucapabilitiesdata/caps_2.10.0.ppc64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.10.0.ppc64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.10.0.s390x.xml
b/tests/qemucapabilitiesdata/caps_2.10.0.s390x.xml
index f13e09cb2..d0a07be5a 100644
--- a/tests/qemucapabilitiesdata/caps_2.10.0.s390x.xml
+++ b/tests/qemucapabilitiesdata/caps_2.10.0.s390x.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.10.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_2.10.0.x86_64.xml
index dca324aa1..59900c4a4 100644
--- a/tests/qemucapabilitiesdata/caps_2.10.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.10.0.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.11.0.s390x.xml
b/tests/qemucapabilitiesdata/caps_2.11.0.s390x.xml
index f1fe5aa07..3aaf8abfc 100644
--- a/tests/qemucapabilitiesdata/caps_2.11.0.s390x.xml
+++ b/tests/qemucapabilitiesdata/caps_2.11.0.s390x.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml
b/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml
index 1270d3d63..d765aa08f 100644
--- a/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml
b/tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml
index 0292fcd49..195566568 100644
--- a/tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml
b/tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml
index 0798c5512..7a5f4bb2f 100644
--- a/tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml
+++ b/tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml
@@ -6,7 +6,6 @@
<flag name='mem-path'/>
<flag name='drive-serial'/>
<flag name='enable-kvm'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml
index f4865b2b2..c32effb6c 100644
--- a/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.4.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_2.4.0.x86_64.xml
index 39ddfdeba..b9f3b65e5 100644
--- a/tests/qemucapabilitiesdata/caps_2.4.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.4.0.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.5.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_2.5.0.x86_64.xml
index 8bf11d86b..c524588d7 100644
--- a/tests/qemucapabilitiesdata/caps_2.5.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.5.0.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.6.0.aarch64.xml
b/tests/qemucapabilitiesdata/caps_2.6.0.aarch64.xml
index 46c095fd9..59aed9b1f 100644
--- a/tests/qemucapabilitiesdata/caps_2.6.0.aarch64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.6.0.aarch64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.6.0.ppc64.xml
b/tests/qemucapabilitiesdata/caps_2.6.0.ppc64.xml
index a69c3e383..fb1333fec 100644
--- a/tests/qemucapabilitiesdata/caps_2.6.0.ppc64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.6.0.ppc64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.6.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_2.6.0.x86_64.xml
index fcbccb54f..89d032467 100644
--- a/tests/qemucapabilitiesdata/caps_2.6.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.6.0.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.7.0.s390x.xml
b/tests/qemucapabilitiesdata/caps_2.7.0.s390x.xml
index b82d3ebce..0ce1780f9 100644
--- a/tests/qemucapabilitiesdata/caps_2.7.0.s390x.xml
+++ b/tests/qemucapabilitiesdata/caps_2.7.0.s390x.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.7.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_2.7.0.x86_64.xml
index 30bb7d787..da1b370c1 100644
--- a/tests/qemucapabilitiesdata/caps_2.7.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.7.0.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.8.0.s390x.xml
b/tests/qemucapabilitiesdata/caps_2.8.0.s390x.xml
index f701835a3..c532e5cee 100644
--- a/tests/qemucapabilitiesdata/caps_2.8.0.s390x.xml
+++ b/tests/qemucapabilitiesdata/caps_2.8.0.s390x.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.8.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_2.8.0.x86_64.xml
index 096bc32f9..9fd8684bb 100644
--- a/tests/qemucapabilitiesdata/caps_2.8.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.8.0.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.9.0.ppc64.xml
b/tests/qemucapabilitiesdata/caps_2.9.0.ppc64.xml
index 4e1d10a4d..9fa07c8e7 100644
--- a/tests/qemucapabilitiesdata/caps_2.9.0.ppc64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.9.0.ppc64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.9.0.s390x.xml
b/tests/qemucapabilitiesdata/caps_2.9.0.s390x.xml
index 0e8272885..d534e4714 100644
--- a/tests/qemucapabilitiesdata/caps_2.9.0.s390x.xml
+++ b/tests/qemucapabilitiesdata/caps_2.9.0.s390x.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.9.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_2.9.0.x86_64.xml
index 1a39067b9..fa7c4fd65 100644
--- a/tests/qemucapabilitiesdata/caps_2.9.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.9.0.x86_64.xml
@@ -6,7 +6,6 @@
<flag name='kvm'/>
<flag name='mem-path'/>
<flag name='drive-serial'/>
- <flag name='monitor-json'/>
<flag name='sdl'/>
<flag name='rtc'/>
<flag name='vhost-net'/>
diff --git a/tests/qemuxml2argvdata/aarch64-aavmf-virtio-mmio.args
b/tests/qemuxml2argvdata/aarch64-aavmf-virtio-mmio.args
index f192dd006..21a3f591d 100644
--- a/tests/qemuxml2argvdata/aarch64-aavmf-virtio-mmio.args
+++ b/tests/qemuxml2argvdata/aarch64-aavmf-virtio-mmio.args
@@ -17,7 +17,7 @@ QEMU_AUDIO_DRV=none \
-nodefaults \
-chardev socket,id=charmonitor,\
path=/tmp/lib/domain--1-aarch64test/monitor.sock,server,nowait \
--mon chardev=charmonitor,id=monitor,mode=readline \
+-mon chardev=charmonitor,id=monitor,mode=control \
-no-acpi \
-boot c \
-kernel /aarch64.kernel \
diff --git a/tests/qemuxml2argvdata/aarch64-acpi-uefi.args
b/tests/qemuxml2argvdata/aarch64-acpi-uefi.args
index d715a97b7..0d3b47768 100644
--- a/tests/qemuxml2argvdata/aarch64-acpi-uefi.args
+++ b/tests/qemuxml2argvdata/aarch64-acpi-uefi.args
@@ -20,5 +20,5 @@ unit=1 \
-nodefaults \
-chardev socket,id=charmonitor,path=/tmp/lib/domain--1-guest/monitor.sock,\
server,nowait \
--mon chardev=charmonitor,id=monitor,mode=readline \
+-mon chardev=charmonitor,id=monitor,mode=control \
-boot c
diff --git a/tests/qemuxml2argvdata/aarch64-cpu-passthrough.args
b/tests/qemuxml2argvdata/aarch64-cpu-passthrough.args
index 511b27c22..5f2240de9 100644
--- a/tests/qemuxml2argvdata/aarch64-cpu-passthrough.args
+++ b/tests/qemuxml2argvdata/aarch64-cpu-passthrough.args
@@ -17,7 +17,7 @@ QEMU_AUDIO_DRV=none \
-nodefaults \
-chardev socket,id=charmonitor,\
path=/tmp/lib/domain--1-aarch64test/monitor.sock,server,nowait \
--mon chardev=charmonitor,id=monitor,mode=readline \
+-mon chardev=charmonitor,id=monitor,mode=control \
-no-acpi \
-boot c \
-drive file=/aarch64.raw,format=raw,if=none,id=drive-virtio-disk0 \
[...]
diff --git a/tests/qemuxml2argvdata/watchdog.args b/tests/qemuxml2argvdata/watchdog.args
index c7565e1c7..73854f9e3 100644
--- a/tests/qemuxml2argvdata/watchdog.args
+++ b/tests/qemuxml2argvdata/watchdog.args
@@ -15,7 +15,7 @@ QEMU_AUDIO_DRV=none \
-nodefaults \
-chardev socket,id=charmonitor,path=/tmp/lib/domain--1-QEMUGuest1/monitor.sock,\
server,nowait \
--mon chardev=charmonitor,id=monitor,mode=readline \
+-mon chardev=charmonitor,id=monitor,mode=control \
-no-acpi \
-boot c \
-usb \
diff --git a/tests/qemuxml2argvdata/x86-kvm-32-on-64.args
b/tests/qemuxml2argvdata/x86-kvm-32-on-64.args
index 5b644b0a6..fe89e1fc3 100644
--- a/tests/qemuxml2argvdata/x86-kvm-32-on-64.args
+++ b/tests/qemuxml2argvdata/x86-kvm-32-on-64.args
@@ -16,6 +16,6 @@ QEMU_AUDIO_DRV=none \
-nodefaults \
-chardev socket,id=charmonitor,path=/tmp/lib/domain--1-kvm/monitor.sock,server,\
nowait \
--mon chardev=charmonitor,id=monitor,mode=readline \
+-mon chardev=charmonitor,id=monitor,mode=control \
-no-acpi \
-boot c
diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
index 21de3e6cf..73d385214 100644
--- a/tests/qemuxml2argvtest.c
+++ b/tests/qemuxml2argvtest.c
@@ -431,8 +431,7 @@ testCompareXMLToArgv(const void *data)
virSetConnectSecret(conn);
virSetConnectStorage(conn);
- if (virQEMUCapsGet(info->qemuCaps, QEMU_CAPS_MONITOR_JSON))
- flags |= FLAG_JSON;
+ flags |= FLAG_JSON;
if (virQEMUCapsGet(info->qemuCaps, QEMU_CAPS_ENABLE_FIPS))
flags |= FLAG_FIPS;
@@ -916,12 +915,9 @@ mymain(void)
DO_TEST_PARSE_ERROR("disk-drive-shared-qcow", NONE);
DO_TEST("disk-drive-shared-locking",
QEMU_CAPS_VIRTIO_SCSI, QEMU_CAPS_DISK_SHARE_RW);
- DO_TEST("disk-drive-error-policy-stop",
- QEMU_CAPS_MONITOR_JSON);
- DO_TEST("disk-drive-error-policy-enospace",
- QEMU_CAPS_MONITOR_JSON);
- DO_TEST("disk-drive-error-policy-wreport-rignore",
- QEMU_CAPS_MONITOR_JSON);
+ DO_TEST("disk-drive-error-policy-stop", NONE);
+ DO_TEST("disk-drive-error-policy-enospace", NONE);
+ DO_TEST("disk-drive-error-policy-wreport-rignore", NONE);
DO_TEST("disk-drive-cache-v2-wt", NONE);
DO_TEST("disk-drive-cache-v2-wb", NONE);
DO_TEST("disk-drive-cache-v2-none", NONE);
@@ -1750,10 +1746,8 @@ mymain(void)
QEMU_CAPS_SCSI_LSI);
DO_TEST("monitor-json",
- QEMU_CAPS_MONITOR_JSON,
QEMU_CAPS_NODEFCONFIG);
DO_TEST("no-shutdown",
- QEMU_CAPS_MONITOR_JSON,
QEMU_CAPS_NODEFCONFIG,
QEMU_CAPS_NO_SHUTDOWN);
--
2.16.1