Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp4447620pxv; Tue, 20 Jul 2021 04:07:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJynCwJ+XRREj/U/7VfySSqF0vAH2FRoUFl//1VZNdlQf8a1cT84ZCWFKbyt76x89CHzoxez X-Received: by 2002:a05:6e02:c8e:: with SMTP id b14mr1129837ile.236.1626779262061; Tue, 20 Jul 2021 04:07:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626779262; cv=none; d=google.com; s=arc-20160816; b=Ivo44zPchrRS1xcDTsJDnS8fgRN6BKkPYv8Ni3Kvs+3ETW1pTqV15PP4uA5LzTMzRT aw93m9LaVjojv3//TGhl0JqWhow2TyJljfWO3y0sOiCcbRU4FTbYSGp4dPj2AoEieOgQ SdgK8Dl3MdnsDe99nFjzYBx5jsW8xAJBmXjiW4CN7+zfZbmiRe62x+36MtO5lhwUrZpf YjKpQ9ym3WcZwSPFM8UwDiAdqXNGHYakiXZGl8oiTdbgZvIvgZpwQo43y6iJ2JYYIhdN 4v4PJYOv626Dyy8Ci4VSGyRJVo9E9YSFobbe65M3imbHBFX7II6sKIkGbd5Xgs+92fgT lpHQ== 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:references:cc:to:subject :from; bh=aOQLpCH2P2w+WaDoVKNilSVMpw6LJI/+CpGJXzbTV9A=; b=IJRYfCgMecLjUCvNDrlifVGSGEuZxuhxCCf+gmFDpLJuJfT8JYjlhD8lBz5jqNEuz2 zbNzhYB8rkGS+W/8F4nVn9GYV1nGkbJvPmt67FI1mfxfPCCvbP6OYntijJZcIFkW/SkX cMvMHkBolnvw50H2XkSaDMzjOQF0aXSMtpfLE3ZyLH+B3VYIlG9MhKNWBtwogqHUerrB awxbJqBosK6GpBsk483bohufEitelBGu7v20qYHZMwgSEE3llXYJomfhALHBVqop7CxC fte3brMC7ziMNeHvykiLIuMoQ+4W7DX+Z/YbeAzn5seBlgg/BtIG0lwoJcTKnk9n3jPt viSA== 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 g9si23946945ilb.126.2021.07.20.04.07.30; Tue, 20 Jul 2021 04:07:42 -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 S238446AbhGTKZN (ORCPT + 99 others); Tue, 20 Jul 2021 06:25:13 -0400 Received: from out30-57.freemail.mail.aliyun.com ([115.124.30.57]:52555 "EHLO out30-57.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236973AbhGTKZE (ORCPT ); Tue, 20 Jul 2021 06:25:04 -0400 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R141e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e01424;MF=xianting.tian@linux.alibaba.com;NM=1;PH=DS;RN=8;SR=0;TI=SMTPD_---0UgQE4aC_1626779139; Received: from B-LB6YLVDL-0141.local(mailfrom:xianting.tian@linux.alibaba.com fp:SMTPD_---0UgQE4aC_1626779139) by smtp.aliyun-inc.com(127.0.0.1); Tue, 20 Jul 2021 19:05:40 +0800 From: Xianting Tian Subject: Re: [PATCH v2] vsock/virtio: set vsock frontend ready in virtio_vsock_probe() To: Stefan Hajnoczi Cc: sgarzare@redhat.com, davem@davemloft.net, kuba@kernel.org, jasowang@redhat.com, kvm@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20210720071337.1995-1-xianting.tian@linux.alibaba.com> Message-ID: Date: Tue, 20 Jul 2021 19:05:39 +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: 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 在 2021/7/20 下午6:23, Stefan Hajnoczi 写道: > On Tue, Jul 20, 2021 at 03:13:37PM +0800, Xianting Tian wrote: >> 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(+) > Please include a changelog when you send v2, v3, etc patches. OK, thanks. >> diff --git a/net/vmw_vsock/virtio_transport.c b/net/vmw_vsock/virtio_transport.c >> index e0c2c992a..dc834b8fd 100644 >> --- a/net/vmw_vsock/virtio_transport.c >> +++ b/net/vmw_vsock/virtio_transport.c >> @@ -639,6 +639,8 @@ static int virtio_vsock_probe(struct virtio_device *vdev) >> >> mutex_unlock(&the_virtio_vsock_mutex); >> >> + virtio_device_ready(vdev); > Why is this patch necessary? Sorry, I didn't notice the check in virtio_dev_probe(), As Jason comment,  I alsoe think we need to be consistent: switch to use virtio_device_ready() for all the drivers. What's opinion about this? > The core virtio_dev_probe() code already calls virtio_device_ready for > us: > > static int virtio_dev_probe(struct device *_d) > { > ... > err = drv->probe(dev); > if (err) > goto err; > > /* If probe didn't do it, mark device DRIVER_OK ourselves. */ > if (!(dev->config->get_status(dev) & VIRTIO_CONFIG_S_DRIVER_OK)) > virtio_device_ready(dev);