From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.kernel.org ([198.145.29.99]:42780 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726614AbeLKGiq (ORCPT ); Tue, 11 Dec 2018 01:38:46 -0500 Date: Tue, 11 Dec 2018 07:38:42 +0100 From: Greg KH To: Lepton Wu Cc: stable@vger.kernel.org, stefanha@redhat.com Subject: Re: [PATCH] VSOCK: bind to random port for VMADDR_PORT_ANY Message-ID: <20181211063842.GA4688@kroah.com> References: <20181211020631.178905-1-ytht.net@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20181211020631.178905-1-ytht.net@gmail.com> Sender: stable-owner@vger.kernel.org List-ID: On Mon, Dec 10, 2018 at 06:06:31PM -0800, Lepton Wu wrote: > The old code always starts from fixed port for VMADDR_PORT_ANY. Sometimes > when VMM crashed, there is still orphaned vsock which is waiting for > close timer, then it could cause connection time out for new started VM > if they are trying to connect to same port with same guest cid since the > new packets could hit that orphaned vsock. We could also fix this by doing > more in vhost_vsock_reset_orphans, but any way, it should be better to start > from a random local port instead of a fixed one. > > Signed-off-by: Lepton Wu > --- > net/vmw_vsock/af_vsock.c | 6 +++++- > 1 file changed, 5 insertions(+), 1 deletion(-) This is not the correct way to submit patches for inclusion in the stable kernel tree. Please read: https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html for how to do this properly.