]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.4-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 7 Feb 2018 19:36:38 +0000 (11:36 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 7 Feb 2018 19:36:38 +0000 (11:36 -0800)
added patches:
vhost_net-stop-device-during-reset-owner.patch

queue-4.4/series
queue-4.4/vhost_net-stop-device-during-reset-owner.patch [new file with mode: 0644]

index 67ac75d5b7e6cf48bb3d4e3b849f32bda31e085f..67df348dc6e8988fd9a52eb37283981aea8d7f19 100644 (file)
@@ -30,3 +30,4 @@ qlcnic-fix-deadlock-bug.patch
 r8169-fix-rtl8168ep-take-too-long-to-complete-driver-initialization.patch
 tcp-release-sk_frag.page-in-tcp_disconnect.patch
 ipv6-fix-so_reuseport-udp-socket-with-implicit-sk_ipv6only.patch
+vhost_net-stop-device-during-reset-owner.patch
diff --git a/queue-4.4/vhost_net-stop-device-during-reset-owner.patch b/queue-4.4/vhost_net-stop-device-during-reset-owner.patch
new file mode 100644 (file)
index 0000000..6a70009
--- /dev/null
@@ -0,0 +1,34 @@
+From foo@baz Wed Feb  7 11:22:35 PST 2018
+From: Jason Wang <jasowang@redhat.com>
+Date: Thu, 25 Jan 2018 22:03:52 +0800
+Subject: vhost_net: stop device during reset owner
+
+From: Jason Wang <jasowang@redhat.com>
+
+
+[ Upstream commit 4cd879515d686849eec5f718aeac62a70b067d82 ]
+
+We don't stop device before reset owner, this means we could try to
+serve any virtqueue kick before reset dev->worker. This will result a
+warn since the work was pending at llist during owner resetting. Fix
+this by stopping device during owner reset.
+
+Reported-by: syzbot+eb17c6162478cc50632c@syzkaller.appspotmail.com
+Fixes: 3a4d5c94e9593 ("vhost_net: a kernel-level virtio server")
+Signed-off-by: Jason Wang <jasowang@redhat.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/vhost/net.c |    1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/drivers/vhost/net.c
++++ b/drivers/vhost/net.c
+@@ -981,6 +981,7 @@ static long vhost_net_reset_owner(struct
+       }
+       vhost_net_stop(n, &tx_sock, &rx_sock);
+       vhost_net_flush(n);
++      vhost_dev_stop(&n->dev);
+       vhost_dev_reset_owner(&n->dev, memory);
+       vhost_net_vq_reset(n);
+ done: