Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp4312778pxv; Tue, 20 Jul 2021 00:08:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyf9MFw6hclr9I1Xgr5mV+cLgZ61jAygoQ80k+1oZWYp5mtJqivlSOMOEu/S461viWhNVuv X-Received: by 2002:a17:906:1701:: with SMTP id c1mr30939150eje.425.1626764893258; Tue, 20 Jul 2021 00:08:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626764893; cv=none; d=google.com; s=arc-20160816; b=JsJOJXtOIuoPICueICdjM7YzE0ahMuC1Uf4fmX9oW+qorXQWgbeJdxjBvhVxOL4SYn C2t/63HRtXWNMHy2egMJUC3pYwRSaUfMhtRHRbVvz9dSuQeOGzQIrQ603ZcRCBeFm/hO 3eJNM20Nstw0XjuLWrRc1jO+RZmAL44LSzGEImoWuEL7wdFVnesFsl4ib/e2rxzIQnsx HieENPSE2CnLnl9pTm1GzmiaK4QX9x347UTAIOSik0YJR/d3R3cSWeNzbwiA6uL/sGw7 Raw2j/V03QGzaGNsHpvLfHC+Qf6dL2bkTX/vtLrmSSJ3ac8NvJPDnDMsWzlEOkZOR5VG 0Qiw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :mime-version:user-agent:date:message-id:from:references:cc:to :subject; bh=ZoREELJBCuiBYNaaYlDDsHJeAKMHJ7ojg4uyl8Xi0U8=; b=o51n/1sMZpbKqYy9Jgw9jks9HDRh2gYPyrYqFjYzQKlypeU1L0dxfNTMeURYi7YwY+ GZ0AXTjK/5Gd1N1Zm5IooYU9yJACwtuYF/ddGcpR3oueQS/LdHLh2sTGARlv7S9fzuQg PH4W2hMMotaYbEnoCgj5yS9Z8TwR0kGz/RGBxT7J/LWS4ciqwxL24z0nHcok+BrXqFlx UZ3x1A8HPvbCznWbwiS/caJVuO62/xaDYbBbTNDe7/rVEjEn5HCURE8So73P8gQvq2Tg 3mWrNzmZynKUhWbaPmoQ/kON+MXLM5AMf2+ngxGK3QI7uuImw+tL2XnWGiWuI8NR/IFs elZQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ck11si7670478ejb.397.2021.07.20.00.07.50; Tue, 20 Jul 2021 00:08:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241756AbhGTGZI (ORCPT + 99 others); Tue, 20 Jul 2021 02:25:08 -0400 Received: from out30-54.freemail.mail.aliyun.com ([115.124.30.54]:49988 "EHLO out30-54.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236706AbhGTGZA (ORCPT ); Tue, 20 Jul 2021 02:25:00 -0400 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R541e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=alimailimapcm10staff010182156082;MF=xianting.tian@linux.alibaba.com;NM=1;PH=DS;RN=9;SR=0;TI=SMTPD_---0UgOhihj_1626764737; Received: from B-LB6YLVDL-0141.local(mailfrom:xianting.tian@linux.alibaba.com fp:SMTPD_---0UgOhihj_1626764737) by smtp.aliyun-inc.com(127.0.0.1); Tue, 20 Jul 2021 15:05:37 +0800 Subject: Re: [PATCH] vsock/virtio: set vsock frontend ready in virtio_vsock_probe() To: Jason Wang , Xianting Tian , stefanha@redhat.com, sgarzare@redhat.com, davem@davemloft.net, kuba@kernel.org Cc: kvm@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20210720034255.1408-1-tianxianting.txt@linux.alibaba.com> <73d486dd-17d9-a3b3-c1e9-39a1138c0084@redhat.com> From: tianxianting Message-ID: Date: Tue, 20 Jul 2021 15:05:36 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.12.0 MIME-Version: 1.0 In-Reply-To: <73d486dd-17d9-a3b3-c1e9-39a1138c0084@redhat.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org thanks , I will sent V2 patch. 在 2021/7/20 下午2:28, Jason Wang 写道: > > 在 2021/7/20 上午11:42, Xianting Tian 写道: >> From: Xianting Tian >> >> Add the missed virtio_device_ready() to set vsock frontend ready. >> >> Signed-off-by: Xianting Tian >> --- >>   net/vmw_vsock/virtio_transport.c | 2 ++ >>   1 file changed, 2 insertions(+) >> >> diff --git a/net/vmw_vsock/virtio_transport.c >> b/net/vmw_vsock/virtio_transport.c >> index e0c2c992a..eb4c607c4 100644 >> --- a/net/vmw_vsock/virtio_transport.c >> +++ b/net/vmw_vsock/virtio_transport.c >> @@ -637,6 +637,8 @@ static int virtio_vsock_probe(struct >> virtio_device *vdev) >>       vdev->priv = vsock; >>       rcu_assign_pointer(the_virtio_vsock, vsock); >>   +    virtio_device_ready(vdev); >> + >>       mutex_unlock(&the_virtio_vsock_mutex); > > > It's better to do this after the mutex_lock(). > > Thanks > > >>         return 0;