[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20161213171534.772245868@linuxfoundation.org>
Date: Tue, 13 Dec 2016 09:16:15 -0800
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: linux-kernel@...r.kernel.org
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
stable@...r.kernel.org, Stefan Hajnoczi <stefanha@...hat.com>,
Peng Tao <bergwolf@...il.com>,
"David S. Miller" <davem@...emloft.net>
Subject: [PATCH 4.8 14/33] vhost-vsock: fix orphan connection reset
4.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Peng Tao <bergwolf@...il.com>
commit c4587631c7bad47c045e081d1553cd73a23be59a upstream.
local_addr.svm_cid is host cid. We should check guest cid instead,
which is remote_addr.svm_cid. Otherwise we end up resetting all
connections to all guests.
Reviewed-by: Stefan Hajnoczi <stefanha@...hat.com>
Signed-off-by: Peng Tao <bergwolf@...il.com>
Signed-off-by: David S. Miller <davem@...emloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
---
drivers/vhost/vsock.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/vhost/vsock.c
+++ b/drivers/vhost/vsock.c
@@ -506,7 +506,7 @@ static void vhost_vsock_reset_orphans(st
* executing.
*/
- if (!vhost_vsock_get(vsk->local_addr.svm_cid)) {
+ if (!vhost_vsock_get(vsk->remote_addr.svm_cid)) {
sock_set_flag(sk, SOCK_DONE);
vsk->peer_shutdown = SHUTDOWN_MASK;
sk->sk_state = SS_UNCONNECTED;
Powered by blists - more mailing lists