virtio-net: delete also control queue when TX/RX deleted
RH-Author: Julia Suvorova <jusual@redhat.com> Message-id: <20200219213431.11913-5-jusual@redhat.com> Patchwork-id: 93983 O-Subject: [RHEL-AV-8.2.0 qemu-kvm PATCH 4/4] virtio-net: delete also control queue when TX/RX deleted Bugzilla: 1791590 RH-Acked-by: Danilo de Paula <ddepaula@redhat.com> RH-Acked-by: Stefano Garzarella <sgarzare@redhat.com> RH-Acked-by: Michael S. Tsirkin <mst@redhat.com> From: Yuri Benditovich <yuri.benditovich@daynix.com> https://bugzilla.redhat.com/show_bug.cgi?id=1708480 If the control queue is not deleted together with TX/RX, it later will be ignored in freeing cache resources and hot unplug will not be completed. Cc: qemu-stable@nongnu.org Signed-off-by: Yuri Benditovich <yuri.benditovich@daynix.com> Message-Id: <20191226043649.14481-3-yuri.benditovich@daynix.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> (cherry picked from commit d945d9f1731244ef341f74ede93120fc9de35913) Signed-off-by: Danilo C. L. de Paula <ddepaula@redhat.com>
This commit is contained in:
parent
f814f65ab1
commit
2e461358e3
49
virtio-net-delete-also-control-queue-when-TX-RX-dele.patch
Normal file
49
virtio-net-delete-also-control-queue-when-TX-RX-dele.patch
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
From 358e2bfe2e1a65b1e926163d7d1ffaefd601d874 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Julia Suvorova <jusual@redhat.com>
|
||||||
|
Date: Wed, 19 Feb 2020 21:34:31 +0000
|
||||||
|
Subject: [PATCH] virtio-net: delete also control queue when TX/RX deleted
|
||||||
|
|
||||||
|
RH-Author: Julia Suvorova <jusual@redhat.com>
|
||||||
|
Message-id: <20200219213431.11913-5-jusual@redhat.com>
|
||||||
|
Patchwork-id: 93983
|
||||||
|
O-Subject: [RHEL-AV-8.2.0 qemu-kvm PATCH 4/4] virtio-net: delete also control queue when TX/RX deleted
|
||||||
|
Bugzilla: 1791590
|
||||||
|
RH-Acked-by: Danilo de Paula <ddepaula@redhat.com>
|
||||||
|
RH-Acked-by: Stefano Garzarella <sgarzare@redhat.com>
|
||||||
|
RH-Acked-by: Michael S. Tsirkin <mst@redhat.com>
|
||||||
|
|
||||||
|
From: Yuri Benditovich <yuri.benditovich@daynix.com>
|
||||||
|
|
||||||
|
https://bugzilla.redhat.com/show_bug.cgi?id=1708480
|
||||||
|
If the control queue is not deleted together with TX/RX, it
|
||||||
|
later will be ignored in freeing cache resources and hot
|
||||||
|
unplug will not be completed.
|
||||||
|
|
||||||
|
Cc: qemu-stable@nongnu.org
|
||||||
|
Signed-off-by: Yuri Benditovich <yuri.benditovich@daynix.com>
|
||||||
|
Message-Id: <20191226043649.14481-3-yuri.benditovich@daynix.com>
|
||||||
|
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
|
||||||
|
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
|
||||||
|
(cherry picked from commit d945d9f1731244ef341f74ede93120fc9de35913)
|
||||||
|
Signed-off-by: Danilo C. L. de Paula <ddepaula@redhat.com>
|
||||||
|
---
|
||||||
|
hw/net/virtio-net.c | 3 ++-
|
||||||
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c
|
||||||
|
index 6adb0fe252..63f1bae99c 100644
|
||||||
|
--- a/hw/net/virtio-net.c
|
||||||
|
+++ b/hw/net/virtio-net.c
|
||||||
|
@@ -2803,7 +2803,8 @@ static void virtio_net_device_unrealize(DeviceState *dev, Error **errp)
|
||||||
|
for (i = 0; i < max_queues; i++) {
|
||||||
|
virtio_net_del_queue(n, i);
|
||||||
|
}
|
||||||
|
-
|
||||||
|
+ /* delete also control vq */
|
||||||
|
+ virtio_del_queue(vdev, max_queues * 2);
|
||||||
|
qemu_announce_timer_del(&n->announce_timer, false);
|
||||||
|
g_free(n->vqs);
|
||||||
|
qemu_del_nic(n->nic);
|
||||||
|
--
|
||||||
|
2.27.0
|
||||||
|
|
||||||
Loading…
x
Reference in New Issue
Block a user