From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andy King Subject: [PATCH 4/4] VSOCK: Don't reject PF_VSOCK protocol Date: Mon, 18 Feb 2013 08:04:13 -0800 Message-ID: <1361203453-1347-5-git-send-email-acking@vmware.com> References: <1361203453-1347-1-git-send-email-acking@vmware.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: pv-drivers@vmware.com, Andy King , davem@davemloft.net To: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, virtualization@lists.linux-foundation.org Return-path: In-Reply-To: <1361203453-1347-1-git-send-email-acking@vmware.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: virtualization-bounces@lists.linux-foundation.org Errors-To: virtualization-bounces@lists.linux-foundation.org List-Id: netdev.vger.kernel.org Allow our own family as the protocol value for socket creation. Reported-by: Gerd Hoffmann Signed-off-by: Andy King --- net/vmw_vsock/af_vsock.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/net/vmw_vsock/af_vsock.c b/net/vmw_vsock/af_vsock.c index c1b9e55..ca511c4 100644 --- a/net/vmw_vsock/af_vsock.c +++ b/net/vmw_vsock/af_vsock.c @@ -1860,7 +1860,7 @@ static int vsock_create(struct net *net, struct socket *sock, if (!sock) return -EINVAL; - if (protocol) + if (protocol && protocol != PF_VSOCK) return -EPROTONOSUPPORT; switch (sock->type) { -- 1.7.4.1