From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753262AbdJTOif (ORCPT ); Fri, 20 Oct 2017 10:38:35 -0400 Received: from aserp1040.oracle.com ([141.146.126.69]:41404 "EHLO aserp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752614AbdJTOib (ORCPT ); Fri, 20 Oct 2017 10:38:31 -0400 Subject: Re: [PATCH v5 06/13] xen/pvcalls: implement bind command To: Stefano Stabellini References: <1507336227-20477-1-git-send-email-sstabellini@kernel.org> <1507336227-20477-6-git-send-email-sstabellini@kernel.org> Cc: xen-devel@lists.xen.org, linux-kernel@vger.kernel.org, jgross@suse.com, Stefano Stabellini From: Boris Ostrovsky Message-ID: Date: Fri, 20 Oct 2017 10:40:05 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-Source-IP: aserv0022.oracle.com [141.146.126.234] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/19/2017 09:31 PM, Stefano Stabellini wrote: > On Tue, 17 Oct 2017, Boris Ostrovsky wrote: >> On 10/06/2017 08:30 PM, Stefano Stabellini wrote: >>> +int pvcalls_front_bind(struct socket *sock, struct sockaddr *addr, int addr_len) >>> +{ >>> + struct pvcalls_bedata *bedata; >>> + struct sock_mapping *map = NULL; >>> + struct xen_pvcalls_request *req; >>> + int notify, req_id, ret; >>> + >>> + if (addr->sa_family != AF_INET || sock->type != SOCK_STREAM) >>> + return -ENOTSUPP; >>> + >>> + pvcalls_enter(); >>> + if (!pvcalls_front_dev) { >>> + pvcalls_exit(); >>> + return -ENOTCONN; >> The connect patch returns -ENETUNREACH here. Is there a deliberate >> distinction between these cases? > No, there isn't a deliberate distinction. Actually, all other commands > return ENOTCONN for this error, we might as well be consistent and > change ENETUNREACH to ENOTCONN for connect. > > If you agree, I'll make the change to the connect patch, and add your > reviewed-by here. It's already there ;-) -boris > > > >> Other than that >> >> Reviewed-by: Boris Ostrovsky