Introduced back in 2010 by QEMU commit:
commit a697a334b3c4d3250e6420f5d38550ea10eb5319
virtio-net: Introduce a new bottom half packet TX
Released in QEMU 0.14.0
Signed-off-by: Ján Tomko <jtomko(a)redhat.com>
---
src/qemu/qemu_command.c | 36 +++++++++++++++++-------------------
src/qemu/qemu_validate.c | 8 --------
tests/qemuxml2argvtest.c | 3 +--
tests/qemuxml2xmltest.c | 2 +-
4 files changed, 19 insertions(+), 30 deletions(-)
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index c5e41ac619..812176ab99 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -3680,28 +3680,26 @@ qemuBuildNicDevProps(virDomainDef *def,
unsigned long long vectors = 0;
virTristateSwitch failover = VIR_TRISTATE_SWITCH_ABSENT;
- if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_VIRTIO_TX_ALG)) {
- switch (net->driver.virtio.txmode) {
- case VIR_DOMAIN_NET_VIRTIO_TX_MODE_IOTHREAD:
- tx = "bh";
- break;
+ switch (net->driver.virtio.txmode) {
+ case VIR_DOMAIN_NET_VIRTIO_TX_MODE_IOTHREAD:
+ tx = "bh";
+ break;
- case VIR_DOMAIN_NET_VIRTIO_TX_MODE_TIMER:
- tx = "timer";
- break;
+ case VIR_DOMAIN_NET_VIRTIO_TX_MODE_TIMER:
+ tx = "timer";
+ break;
- case VIR_DOMAIN_NET_VIRTIO_TX_MODE_DEFAULT:
- break;
+ case VIR_DOMAIN_NET_VIRTIO_TX_MODE_DEFAULT:
+ break;
- case VIR_DOMAIN_NET_VIRTIO_TX_MODE_LAST:
- default:
- /* this should never happen, if it does, we need
- * to add another case to this switch.
- */
- virReportEnumRangeError(virDomainNetVirtioTxModeType,
- net->driver.virtio.txmode);
- return NULL;
- }
+ case VIR_DOMAIN_NET_VIRTIO_TX_MODE_LAST:
+ default:
+ /* this should never happen, if it does, we need
+ * to add another case to this switch.
+ */
+ virReportEnumRangeError(virDomainNetVirtioTxModeType,
+ net->driver.virtio.txmode);
+ return NULL;
}
if (net->driver.virtio.queues > 1) {
diff --git a/src/qemu/qemu_validate.c b/src/qemu/qemu_validate.c
index fb9fbab100..6e457f3814 100644
--- a/src/qemu/qemu_validate.c
+++ b/src/qemu/qemu_validate.c
@@ -1928,14 +1928,6 @@ qemuValidateDomainDeviceDefNetwork(const virDomainNetDef *net,
}
if (virDomainNetIsVirtioModel(net)) {
- if (net->driver.virtio.txmode &&
- !virQEMUCapsGet(qemuCaps, QEMU_CAPS_VIRTIO_TX_ALG)) {
- virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
- _("virtio-net-pci 'tx' option not supported in
"
- "this QEMU binary"));
- return -1;
- }
-
if (net->driver.virtio.rx_queue_size) {
if (!VIR_IS_POW2(net->driver.virtio.rx_queue_size)) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
index be083acf14..8933e373f7 100644
--- a/tests/qemuxml2argvtest.c
+++ b/tests/qemuxml2argvtest.c
@@ -1529,8 +1529,7 @@ mymain(void)
DO_TEST_CAPS_ARCH_LATEST_FULL("net-user", "x86_64", ARG_FLAGS,
FLAG_SLIRP_HELPER);
DO_TEST_NOCAPS("net-user-addr");
DO_TEST_NOCAPS("net-virtio");
- DO_TEST("net-virtio-device",
- QEMU_CAPS_VIRTIO_TX_ALG);
+ DO_TEST_NOCAPS("net-virtio-device");
DO_TEST_NOCAPS("net-virtio-disable-offloads");
DO_TEST_NOCAPS("net-virtio-netdev");
DO_TEST("net-virtio-ccw", QEMU_CAPS_CCW);
diff --git a/tests/qemuxml2xmltest.c b/tests/qemuxml2xmltest.c
index b55715e0f5..af0e2c930f 100644
--- a/tests/qemuxml2xmltest.c
+++ b/tests/qemuxml2xmltest.c
@@ -464,7 +464,7 @@ mymain(void)
DO_TEST_NOCAPS("net-user");
DO_TEST_NOCAPS("net-user-addr");
DO_TEST_NOCAPS("net-virtio");
- DO_TEST("net-virtio-device", QEMU_CAPS_VIRTIO_TX_ALG);
+ DO_TEST_NOCAPS("net-virtio-device");
DO_TEST_NOCAPS("net-virtio-disable-offloads");
DO_TEST_NOCAPS("net-eth");
DO_TEST_NOCAPS("net-eth-ifname");
--
2.37.1