Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp868891ybp; Wed, 9 Oct 2019 05:35:38 -0700 (PDT) X-Google-Smtp-Source: APXvYqy2sAtdCntsZAbWwitGJKmXM5Y0hh7gXjb5xlPhvUywomGJQfBfolQMGW7/uYo44KPS5HzB X-Received: by 2002:a17:906:4d50:: with SMTP id b16mr2548010ejv.245.1570624537957; Wed, 09 Oct 2019 05:35:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570624537; cv=none; d=google.com; s=arc-20160816; b=zv330xhFPMhaYEiTSW9YBjWyV2vrYN8ANQamha9eZfKLWiPI4nxl3uWOGBfabXDZOM wEP8DC1SuC66Es3Z0h7GQ6jB7kGKiFPEfmsnuIyT/qjU1LW5IRacOMofHMuWF7gGoZ3N KnFbXPgs2bcvLsD1AIfdJ1tBbyDqV2IdH1aLMUQpM5WbBBY7V2wxGJMj2eDISPx5Q8dD gymdxq2i7K1FFIST2qu6z5ZDsZkPvzPSLdnobSPkC+ZfCL0ur+ogaXXLbbOEAzu0IYdr Y+RUAa+dtQV6kKejg/48befVb5VcKFOpPdzphV/E0KakE/I4lkASuhkSModU/74UncFS 3gMw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=M4DGzZVz3C9CsIT3+orcem5mC7xRelRKri3ygcgFcYg=; b=tQPuDvclgkdcQM1f2B7VQSZLTxH1J6cyb+eAbnWN4yd7wTGBO2aPFGt3qRY4yk2Mcm 06mrqn1eocwpXL8kS+hxc2QrCg+GxK+LNoB69awQrJXZSNcEvkBoamshHVMH3nxVYATO JT59Pg2kNi17aR69bxBlTc8IBKbN5iRR2o9R2QN2DJr+s8Lc8Pz04s1P28+S96uU1jdu UYbM23UpCd3JljkAjSP6w33P5J1SuOaoz9RrXRSRuMwB+lnORdMfVjJqgYmsS2m9RmYJ udlcsWAnvtGBFVxThP+WzbSosvadBZek7wSGyDjtpF2mAidQTJkv4ZhK7uwh5LXwSIum 8D2w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Z6Vl8jzw; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o2si1039589ejm.367.2019.10.09.05.35.13; Wed, 09 Oct 2019 05:35:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Z6Vl8jzw; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731273AbfJIMe2 (ORCPT + 99 others); Wed, 9 Oct 2019 08:34:28 -0400 Received: from mail-wr1-f66.google.com ([209.85.221.66]:43834 "EHLO mail-wr1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731229AbfJIMe2 (ORCPT ); Wed, 9 Oct 2019 08:34:28 -0400 Received: by mail-wr1-f66.google.com with SMTP id j18so2732000wrq.10; Wed, 09 Oct 2019 05:34:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=M4DGzZVz3C9CsIT3+orcem5mC7xRelRKri3ygcgFcYg=; b=Z6Vl8jzwQZv1XXQ8Mh9He/cTpu97fQsfQ1cBmapxrThVkgpqVmy7iiglrNrsC5cwvA 6IBWyUGhvzVd5dfOS6+lL1zTXjc4zliF5u8ROdz7wF+d4iNr9lc+3q+kGVj91ZHEOJCU KWEBZTD6ETHecKoRnKjnjDsrMTsfHZXE4IasyxVGusXKO6jWu7i2N62HMTD3W1mTxpUt aIEBA3zVKnhpy140JOHqe+f8Tq0cE/s4Enn5W0O54FTnsp1Jvvw1Q5tB7FkVnOsNisXr 7mme3cylQ/y7LAc4TxD/ZIps/GWHqcE/hGZ/tggDg4aWu/kUBfnDGjUZtYpFbe2CjSc6 Y0mQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=M4DGzZVz3C9CsIT3+orcem5mC7xRelRKri3ygcgFcYg=; b=GxkxmNJYLoEOrb1HJ7jBuSDj1avHb8+wALE6IOuaxHu+zPyB1GWQk7Rf94X/KVzeTU zWdBI3bC2Urlbnq/2dbtEMQeG5U6yWPfj8ICQBf3XRBwyfnKCjRXv0bVLtReYELIxX+x 0+nGSIEFHr2I9iWy+k4pUyCjUc49ffxLqOwmp5p7nRDPX0vY6gTGHA6UKzl+jWu1moXH IRxnavb+4Q/NYUMtgOthDRutfsl8oIkvp3jp55rOJa6LEjS7U4nflh8b0u61D+G3uBdG oIJWMKKs7hhN9QoJMM01YNozxseUYftnz6NGdx/t1ThbclRxCmDVAgMm5WxFgETeYAJH xhcw== X-Gm-Message-State: APjAAAU8ELRbfMtD6aNa2FYUNADY6lvd7PYAEd20ZVSldr5JURAbmcKs yu9uRJGM5BLE/XdLFhOAbCY= X-Received: by 2002:adf:e284:: with SMTP id v4mr2653792wri.21.1570624466138; Wed, 09 Oct 2019 05:34:26 -0700 (PDT) Received: from localhost ([51.15.41.238]) by smtp.gmail.com with ESMTPSA id t13sm4438023wra.70.2019.10.09.05.34.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Oct 2019 05:34:25 -0700 (PDT) Date: Wed, 9 Oct 2019 13:34:23 +0100 From: Stefan Hajnoczi To: Stefano Garzarella Cc: netdev@vger.kernel.org, Sasha Levin , linux-hyperv@vger.kernel.org, Stephen Hemminger , kvm@vger.kernel.org, "Michael S. Tsirkin" , Dexuan Cui , Haiyang Zhang , linux-kernel@vger.kernel.org, virtualization@lists.linux-foundation.org, Stefan Hajnoczi , "David S. Miller" , Jorgen Hansen Subject: Re: [RFC PATCH 08/13] vsock: move vsock_insert_unbound() in the vsock_create() Message-ID: <20191009123423.GI5747@stefanha-x1.localdomain> References: <20190927112703.17745-1-sgarzare@redhat.com> <20190927112703.17745-9-sgarzare@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="+PbGPm1eXpwOoWkI" Content-Disposition: inline In-Reply-To: <20190927112703.17745-9-sgarzare@redhat.com> User-Agent: Mutt/1.12.1 (2019-06-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --+PbGPm1eXpwOoWkI Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Sep 27, 2019 at 01:26:58PM +0200, Stefano Garzarella wrote: > vsock_insert_unbound() was called only when 'sock' parameter of > __vsock_create() was not null. This only happened when > __vsock_create() was called by vsock_create(). >=20 > In order to simplify the multi-transports support, this patch > moves vsock_insert_unbound() at the end of vsock_create(). >=20 > Signed-off-by: Stefano Garzarella > --- > net/vmw_vsock/af_vsock.c | 13 +++++++++---- > 1 file changed, 9 insertions(+), 4 deletions(-) Maybe transports shouldn't call __vsock_create() directly. They always pass NULL as the parent socket, so we could have a more specific function that transports call without a parent sock argument. This would eliminate any concern over moving vsock_insert_unbound() out of this function. In any case, I've checked the code and this patch is correct. Reviewed-by: Stefan Hajnoczi --+PbGPm1eXpwOoWkI Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEhpWov9P5fNqsNXdanKSrs4Grc8gFAl2d088ACgkQnKSrs4Gr c8jGUgf/flGT/To2png0jPgQV5oe1jDDk+0D39ubcCGjdMLuOwLdwey4BUbOWK3I KFEzw7U6CmXNnW15vqqckacUNgL6OXgHKrOxKpiwYvonz2/C0JNLMaTIbsSfcR8u sXWnnoihq8NTRIJhSxHFaWgqBLWFW8G3sAfFA2oCIiNI8HQhewIy0Sfh2vfuyypU SjCHAwlodeIMuEmeIlTUEd4RKWqZ3dDAOs5xnl87OWUdzTtgmKEccQLZSvJ/t2Qi QVVO07S3r7ASe2bpjmTgQuV1ZZ3iz/jyFOYAD3WmE6D6a+afcU+4gUTa9Tbu1TL4 en7c7jB5XF98CqjwO5kjMLozykqVWg== =Fgki -----END PGP SIGNATURE----- --+PbGPm1eXpwOoWkI--