It's only usage is in a !QEMU_CAPS_DEVICE code path. Remove that
code, and blacklist it
---
src/qemu/qemu_capabilities.c | 3 ---
src/qemu/qemu_capabilities.h | 2 +-
src/qemu/qemu_command.c | 20 +++++++++-----------
tests/qemucapabilitiesdata/caps_1.2.2-1.caps | 1 -
tests/qemucapabilitiesdata/caps_1.3.1-1.caps | 1 -
tests/qemucapabilitiesdata/caps_1.4.2-1.caps | 1 -
tests/qemucapabilitiesdata/caps_1.5.3-1.caps | 1 -
tests/qemucapabilitiesdata/caps_1.6.0-1.caps | 1 -
tests/qemucapabilitiesdata/caps_1.6.50-1.caps | 1 -
tests/qemucapabilitiesdata/caps_2.1.1-1.caps | 1 -
tests/qemucapabilitiesdata/caps_2.4.0-1.caps | 1 -
tests/qemucapabilitiesdata/caps_2.5.0-1.caps | 1 -
tests/qemucapabilitiesdata/caps_2.6.0-1.caps | 1 -
tests/qemuhelptest.c | 8 --------
14 files changed, 10 insertions(+), 33 deletions(-)
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
index 3099e34..8c29165 100644
--- a/src/qemu/qemu_capabilities.c
+++ b/src/qemu/qemu_capabilities.c
@@ -1156,8 +1156,6 @@ virQEMUCapsComputeCmdFlags(const char *help,
if (strstr(help, "-chardev spiceport"))
virQEMUCapsSet(qemuCaps, QEMU_CAPS_CHARDEV_SPICEPORT);
}
- if (strstr(help, "-balloon"))
- virQEMUCapsSet(qemuCaps, QEMU_CAPS_BALLOON);
if (strstr(help, "-device")) {
virQEMUCapsSet(qemuCaps, QEMU_CAPS_DEVICE);
/*
@@ -3217,7 +3215,6 @@ virQEMUCapsInitQMPBasic(virQEMUCapsPtr qemuCaps)
virQEMUCapsSet(qemuCaps, QEMU_CAPS_DRIVE_SERIAL);
virQEMUCapsSet(qemuCaps, QEMU_CAPS_CHARDEV);
virQEMUCapsSet(qemuCaps, QEMU_CAPS_MONITOR_JSON);
- virQEMUCapsSet(qemuCaps, QEMU_CAPS_BALLOON);
virQEMUCapsSet(qemuCaps, QEMU_CAPS_DEVICE);
virQEMUCapsSet(qemuCaps, QEMU_CAPS_SDL);
virQEMUCapsSet(qemuCaps, QEMU_CAPS_SMP_TOPOLOGY);
diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h
index e5353de..bca4ef4 100644
--- a/src/qemu/qemu_capabilities.h
+++ b/src/qemu/qemu_capabilities.h
@@ -81,7 +81,7 @@ typedef enum {
QEMU_CAPS_MONITOR_JSON, /* JSON mode for monitor */
/* 25 */
- QEMU_CAPS_BALLOON, /* -balloon available */
+ X_QEMU_CAPS_BALLOON, /* -balloon available */
QEMU_CAPS_DEVICE, /* Is the new -device arg available */
QEMU_CAPS_SDL, /* Is the new -sdl arg available */
QEMU_CAPS_SMP_TOPOLOGY, /* -smp has sockets/cores/threads */
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index 733d498..4007621 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -10953,24 +10953,22 @@ qemuBuildCommandLine(virConnectPtr conn,
if (def->memballoon &&
def->memballoon->model != VIR_DOMAIN_MEMBALLOON_MODEL_NONE) {
+ char *optstr;
+
if (def->memballoon->model != VIR_DOMAIN_MEMBALLOON_MODEL_VIRTIO) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
_("Memory balloon device type '%s' is not
supported by this version of qemu"),
virDomainMemballoonModelTypeToString(def->memballoon->model));
goto error;
}
- if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE)) {
- char *optstr;
- virCommandAddArg(cmd, "-device");
- optstr = qemuBuildMemballoonDevStr(def, def->memballoon, qemuCaps);
- if (!optstr)
- goto error;
- virCommandAddArg(cmd, optstr);
- VIR_FREE(optstr);
- } else if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_BALLOON)) {
- virCommandAddArgList(cmd, "-balloon", "virtio", NULL);
- }
+ virCommandAddArg(cmd, "-device");
+
+ optstr = qemuBuildMemballoonDevStr(def, def->memballoon, qemuCaps);
+ if (!optstr)
+ goto error;
+ virCommandAddArg(cmd, optstr);
+ VIR_FREE(optstr);
}
for (i = 0; i < def->nrngs; i++) {
diff --git a/tests/qemucapabilitiesdata/caps_1.2.2-1.caps
b/tests/qemucapabilitiesdata/caps_1.2.2-1.caps
index 34ddd80..af93904 100644
--- a/tests/qemucapabilitiesdata/caps_1.2.2-1.caps
+++ b/tests/qemucapabilitiesdata/caps_1.2.2-1.caps
@@ -4,7 +4,6 @@
<flag name='chardev'/>
<flag name='enable-kvm'/>
<flag name='monitor-json'/>
- <flag name='balloon'/>
<flag name='device'/>
<flag name='sdl'/>
<flag name='smp-topology'/>
diff --git a/tests/qemucapabilitiesdata/caps_1.3.1-1.caps
b/tests/qemucapabilitiesdata/caps_1.3.1-1.caps
index cb8eac9..87d9a89 100644
--- a/tests/qemucapabilitiesdata/caps_1.3.1-1.caps
+++ b/tests/qemucapabilitiesdata/caps_1.3.1-1.caps
@@ -4,7 +4,6 @@
<flag name='chardev'/>
<flag name='enable-kvm'/>
<flag name='monitor-json'/>
- <flag name='balloon'/>
<flag name='device'/>
<flag name='sdl'/>
<flag name='smp-topology'/>
diff --git a/tests/qemucapabilitiesdata/caps_1.4.2-1.caps
b/tests/qemucapabilitiesdata/caps_1.4.2-1.caps
index 86982f1..ae7f4a8 100644
--- a/tests/qemucapabilitiesdata/caps_1.4.2-1.caps
+++ b/tests/qemucapabilitiesdata/caps_1.4.2-1.caps
@@ -4,7 +4,6 @@
<flag name='chardev'/>
<flag name='enable-kvm'/>
<flag name='monitor-json'/>
- <flag name='balloon'/>
<flag name='device'/>
<flag name='sdl'/>
<flag name='smp-topology'/>
diff --git a/tests/qemucapabilitiesdata/caps_1.5.3-1.caps
b/tests/qemucapabilitiesdata/caps_1.5.3-1.caps
index 5401d65..0db8a48 100644
--- a/tests/qemucapabilitiesdata/caps_1.5.3-1.caps
+++ b/tests/qemucapabilitiesdata/caps_1.5.3-1.caps
@@ -4,7 +4,6 @@
<flag name='chardev'/>
<flag name='enable-kvm'/>
<flag name='monitor-json'/>
- <flag name='balloon'/>
<flag name='device'/>
<flag name='sdl'/>
<flag name='smp-topology'/>
diff --git a/tests/qemucapabilitiesdata/caps_1.6.0-1.caps
b/tests/qemucapabilitiesdata/caps_1.6.0-1.caps
index 63536a7..23e6920 100644
--- a/tests/qemucapabilitiesdata/caps_1.6.0-1.caps
+++ b/tests/qemucapabilitiesdata/caps_1.6.0-1.caps
@@ -4,7 +4,6 @@
<flag name='chardev'/>
<flag name='enable-kvm'/>
<flag name='monitor-json'/>
- <flag name='balloon'/>
<flag name='device'/>
<flag name='sdl'/>
<flag name='smp-topology'/>
diff --git a/tests/qemucapabilitiesdata/caps_1.6.50-1.caps
b/tests/qemucapabilitiesdata/caps_1.6.50-1.caps
index 6717a94..db56973 100644
--- a/tests/qemucapabilitiesdata/caps_1.6.50-1.caps
+++ b/tests/qemucapabilitiesdata/caps_1.6.50-1.caps
@@ -4,7 +4,6 @@
<flag name='chardev'/>
<flag name='enable-kvm'/>
<flag name='monitor-json'/>
- <flag name='balloon'/>
<flag name='device'/>
<flag name='sdl'/>
<flag name='smp-topology'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.1.1-1.caps
b/tests/qemucapabilitiesdata/caps_2.1.1-1.caps
index 332b85a..c98a7a5 100644
--- a/tests/qemucapabilitiesdata/caps_2.1.1-1.caps
+++ b/tests/qemucapabilitiesdata/caps_2.1.1-1.caps
@@ -4,7 +4,6 @@
<flag name='chardev'/>
<flag name='enable-kvm'/>
<flag name='monitor-json'/>
- <flag name='balloon'/>
<flag name='device'/>
<flag name='sdl'/>
<flag name='smp-topology'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.4.0-1.caps
b/tests/qemucapabilitiesdata/caps_2.4.0-1.caps
index e411542..a8e9c16 100644
--- a/tests/qemucapabilitiesdata/caps_2.4.0-1.caps
+++ b/tests/qemucapabilitiesdata/caps_2.4.0-1.caps
@@ -4,7 +4,6 @@
<flag name='chardev'/>
<flag name='enable-kvm'/>
<flag name='monitor-json'/>
- <flag name='balloon'/>
<flag name='device'/>
<flag name='sdl'/>
<flag name='smp-topology'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.5.0-1.caps
b/tests/qemucapabilitiesdata/caps_2.5.0-1.caps
index 931bc4f..15f56a3 100644
--- a/tests/qemucapabilitiesdata/caps_2.5.0-1.caps
+++ b/tests/qemucapabilitiesdata/caps_2.5.0-1.caps
@@ -4,7 +4,6 @@
<flag name='chardev'/>
<flag name='enable-kvm'/>
<flag name='monitor-json'/>
- <flag name='balloon'/>
<flag name='device'/>
<flag name='sdl'/>
<flag name='smp-topology'/>
diff --git a/tests/qemucapabilitiesdata/caps_2.6.0-1.caps
b/tests/qemucapabilitiesdata/caps_2.6.0-1.caps
index f32d5aa..9d5c15c 100644
--- a/tests/qemucapabilitiesdata/caps_2.6.0-1.caps
+++ b/tests/qemucapabilitiesdata/caps_2.6.0-1.caps
@@ -4,7 +4,6 @@
<flag name='chardev'/>
<flag name='enable-kvm'/>
<flag name='monitor-json'/>
- <flag name='balloon'/>
<flag name='device'/>
<flag name='sdl'/>
<flag name='smp-topology'/>
diff --git a/tests/qemuhelptest.c b/tests/qemuhelptest.c
index 35fc9c7..26455d5 100644
--- a/tests/qemuhelptest.c
+++ b/tests/qemuhelptest.c
@@ -157,7 +157,6 @@ mymain(void)
QEMU_CAPS_ENABLE_KVM,
QEMU_CAPS_SDL,
QEMU_CAPS_CHARDEV,
- QEMU_CAPS_BALLOON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
QEMU_CAPS_RTC,
@@ -183,7 +182,6 @@ mymain(void)
QEMU_CAPS_CHARDEV,
QEMU_CAPS_ENABLE_KVM,
QEMU_CAPS_MONITOR_JSON,
- QEMU_CAPS_BALLOON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
QEMU_CAPS_NETDEV,
@@ -231,7 +229,6 @@ mymain(void)
QEMU_CAPS_MEM_PATH,
QEMU_CAPS_SDL,
QEMU_CAPS_CHARDEV,
- QEMU_CAPS_BALLOON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
QEMU_CAPS_RTC,
@@ -263,7 +260,6 @@ mymain(void)
QEMU_CAPS_CHARDEV,
QEMU_CAPS_ENABLE_KVM,
QEMU_CAPS_MONITOR_JSON,
- QEMU_CAPS_BALLOON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
QEMU_CAPS_NETDEV,
@@ -321,7 +317,6 @@ mymain(void)
QEMU_CAPS_CHARDEV,
QEMU_CAPS_ENABLE_KVM,
QEMU_CAPS_MONITOR_JSON,
- QEMU_CAPS_BALLOON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
QEMU_CAPS_NETDEV,
@@ -376,7 +371,6 @@ mymain(void)
QEMU_CAPS_MEM_PATH,
QEMU_CAPS_CHARDEV,
QEMU_CAPS_ENABLE_KVM,
- QEMU_CAPS_BALLOON,
QEMU_CAPS_MONITOR_JSON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
@@ -440,7 +434,6 @@ mymain(void)
QEMU_CAPS_CHARDEV,
QEMU_CAPS_ENABLE_KVM,
QEMU_CAPS_MONITOR_JSON,
- QEMU_CAPS_BALLOON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
QEMU_CAPS_NETDEV,
@@ -519,7 +512,6 @@ mymain(void)
QEMU_CAPS_CHARDEV,
QEMU_CAPS_ENABLE_KVM,
QEMU_CAPS_MONITOR_JSON,
- QEMU_CAPS_BALLOON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
QEMU_CAPS_NETDEV,
--
2.5.0