From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 25322C47E48 for ; Thu, 15 Jul 2021 05:01:57 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 052E66128B for ; Thu, 15 Jul 2021 05:01:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238920AbhGOFEJ (ORCPT ); Thu, 15 Jul 2021 01:04:09 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:31307 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237053AbhGOFEI (ORCPT ); Thu, 15 Jul 2021 01:04:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1626325275; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=WtjoUKLcgmL3bnw/gxqCJv6EYfcYaY0E3bn8JDpe3PI=; b=HGBLkOX+IZpd9PDeczkUWAdzxkUB6jF+BaMjpI7N1m38DiQuOUKRwW869N/rf4muIE+R7N 9KBfNt4KWhZWBDpNk6+kT1JzHD6SZAzlLmJfX1/HrHyGMdmNNnF5OIw4cQPu7VkM/IlxX6 ZxmEcM+pWRmcoghNunOq3wxIMhDCZpE= Received: from mail-pf1-f197.google.com (mail-pf1-f197.google.com [209.85.210.197]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-195-2nzxOsY-PVCFIK1j0Yx7NQ-1; Thu, 15 Jul 2021 01:01:14 -0400 X-MC-Unique: 2nzxOsY-PVCFIK1j0Yx7NQ-1 Received: by mail-pf1-f197.google.com with SMTP id k11-20020aa792cb0000b02903305e16bd1dso3371912pfa.2 for ; Wed, 14 Jul 2021 22:01:13 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=WtjoUKLcgmL3bnw/gxqCJv6EYfcYaY0E3bn8JDpe3PI=; b=HMiUIgYykOewmFE1FoT/bJ2GsC/W+A9ZMAgWeDVBHSjpS6/9T8smMDCa94nTWxpWr2 kyj0q6nrIQ+6XdOL3fIamVxoSVoO1vXkO9/JyaxZpANmj4hX03UfEQ87epxpqSlSKol9 IbMtWAqcApOPzsWu/6EtQUQjknRYdgMcWNQ98o5QKA/xcqoyQQdw6AwX+QuWmRW5Lhnt gHO2GMNLpKJ7iCpsxxAwsRYxhnO51upKCmufD+3cv7g9kMcCQBIsTITStirsyx6YHxRy H1KY1nGQ+9cvCViU5EqIgZ0zLPdUB39NU+ihUwoKsXoDcXqm6QAy7DqWGk+m2FzqQOMc WoKQ== X-Gm-Message-State: AOAM530RnUqccqXEqX97GQaRJbhQ7YBVhaWGdcgLgxAJf/Y3AR7FoM3J QXlwX4sZoGyUu/22zLQPhnLbQ4sOMl/NApZNHBcEtKvbxVfQ8saTVQXSWBdOgxJvhmrRUpNLolu ylBCvdwrjB8ok X-Received: by 2002:a63:1e5c:: with SMTP id p28mr2391179pgm.3.1626325272857; Wed, 14 Jul 2021 22:01:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwkpF4TSDI5DZm/B2bv9bWVuNXDKhmhRtseurS2rxggrCDnmBokVeS6bdawuICnE0MaFRu/xw== X-Received: by 2002:a63:1e5c:: with SMTP id p28mr2391148pgm.3.1626325272634; Wed, 14 Jul 2021 22:01:12 -0700 (PDT) Received: from wangxiaodeMacBook-Air.local ([209.132.188.80]) by smtp.gmail.com with ESMTPSA id o20sm5070990pgv.80.2021.07.14.22.01.01 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 14 Jul 2021 22:01:12 -0700 (PDT) Subject: Re: [PATCH v9 16/17] vduse: Introduce VDUSE - vDPA Device in Userspace To: Yongji Xie Cc: "Michael S. Tsirkin" , Stefan Hajnoczi , Stefano Garzarella , Parav Pandit , Christoph Hellwig , Christian Brauner , Randy Dunlap , Matthew Wilcox , Al Viro , Jens Axboe , bcrl@kvack.org, Jonathan Corbet , =?UTF-8?Q?Mika_Penttil=c3=a4?= , Dan Carpenter , joro@8bytes.org, Greg KH , He Zhe , Liu Xiaodong , songmuchun@bytedance.com, virtualization , netdev@vger.kernel.org, kvm , linux-fsdevel@vger.kernel.org, iommu@lists.linux-foundation.org, linux-kernel References: <20210713084656.232-1-xieyongji@bytedance.com> <20210713084656.232-17-xieyongji@bytedance.com> <26116714-f485-eeab-4939-71c4c10c30de@redhat.com> From: Jason Wang Message-ID: <5d756360-b540-2faf-6e52-e7e6e863ca0b@redhat.com> Date: Thu, 15 Jul 2021 13:00:56 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org 在 2021/7/15 下午12:03, Yongji Xie 写道: >> Which ioctl can be used for this? >> > I mean we can introduce a new ioctl for that in the future. Ok, I see. > >>>> I wonder if it's better to do something similar to ccw: >>>> >>>> 1) requires the userspace to update the status bit in the response >>>> 2) update the dev->status to the status in the response if no timeout >>>> >>>> Then userspace could then set NEEDS_RESET if necessary. >>>> >>> But NEEDS_RESET does not only happen in this case. >> Yes, so you need an ioctl for userspace to update the device status >> (NEEDS_RESET) probably. >> > Yes, but I'd like to do that after the initial version is merged since > NEEDS_RESET is not supported now. Right. Thanks >