Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp3118605ybn; Fri, 27 Sep 2019 01:07:41 -0700 (PDT) X-Google-Smtp-Source: APXvYqx9rab7w9RDkdzjQBs3hGVB7LYwwhmG0THgXX5KotMmBYLHZP3iuK+dvkLR0caJ57UrWMFm X-Received: by 2002:a17:906:90d4:: with SMTP id v20mr6851597ejw.189.1569571661641; Fri, 27 Sep 2019 01:07:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569571661; cv=none; d=google.com; s=arc-20160816; b=ATyIlc7o0uoo6EMGB5pI0EcNC0ofN9BNW8pU8NB5tgfuxYWIYU2QAjUpcThdsVoheo nzTVbhgRktkc4lTVHbK7boM4x+CLqa7TWIivuyYT6k6nq0dQTjBgU4gLlU+zk3Owmn4O qWmDn/IeN80zsvBRIfuVqoio8036QoDEQN2SbA71ke77HHiWzAcjYCZfYh3uYFuEwcQx t6DxpXUkrYTt+Jlxwu8fzDtR+m7yoNCu6OAXHth9SJpav8TqOBBfYRI4N4KeKCaUVhCP WJ7VrZ1tpI4CCM9j5p+xhuUNO9up1TgWBrtxTMKlA3E4dLOwrTFkLXAcUUNlu3QhbT1y si3g== 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-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=s6sJrG1qTIfN8z7bfABuBUijZ7IikpKobqOZt2zHrCc=; b=u0CiX4VtuUojBIXyJVf1rMm1kfj+ig0l4SxptUkUyGaDsvErsMov6QKldF+s/nHyjb fDiBl2CL2iK72nvjAbJrfX1EyrNQduLbW8GqJWqBaJO3XjdXrpG4Diir1kLYZ412IwqL MAf7OU142PBsdR0HbQoBE0pGS8j8pzrmuisEG3qsmxxHw7NDHUfClWjeoD7S4SjBFTTc JR9+QKvM1aEGT6L+wl8NWWITJl+tV4UjY7Eiskc7M70woMzXeuUmtEQoJM/sA/mvZGMq 0WVyBClCaVGdToRPMk+9B/NpW+dZDYTjLf4q/9bV4qN4Y+ckV9JQ19qY0+kFW1NXuoS4 cLxg== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id be13si1036441edb.362.2019.09.27.01.07.16; Fri, 27 Sep 2019 01:07:41 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726473AbfI0IHB (ORCPT + 99 others); Fri, 27 Sep 2019 04:07:01 -0400 Received: from mga07.intel.com ([134.134.136.100]:1691 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725804AbfI0IHB (ORCPT ); Fri, 27 Sep 2019 04:07:01 -0400 X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga105.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Sep 2019 01:07:00 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.64,554,1559545200"; d="scan'208";a="201940621" Received: from dpdk-virtio-tbie-2.sh.intel.com (HELO ___) ([10.67.104.73]) by orsmga002.jf.intel.com with ESMTP; 27 Sep 2019 01:06:58 -0700 Date: Fri, 27 Sep 2019 16:04:10 +0800 From: Tiwei Bie To: Jason Wang Cc: mst@redhat.com, alex.williamson@redhat.com, maxime.coquelin@redhat.com, linux-kernel@vger.kernel.org, kvm@vger.kernel.org, virtualization@lists.linux-foundation.org, netdev@vger.kernel.org, dan.daly@intel.com, cunming.liang@intel.com, zhihong.wang@intel.com, lingshan.zhu@intel.com Subject: Re: [PATCH] vhost: introduce mdev based hardware backend Message-ID: <20190927080410.GA22568@___> References: <20190926045427.4973-1-tiwei.bie@intel.com> <1b4b8891-8c14-1c85-1d6a-2eed1c90bcde@redhat.com> <20190927045438.GA17152@___> <49bb0777-3761-3737-8e5b-568957f9a935@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <49bb0777-3761-3737-8e5b-568957f9a935@redhat.com> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Sep 27, 2019 at 03:14:42PM +0800, Jason Wang wrote: > On 2019/9/27 下午12:54, Tiwei Bie wrote: > > > > + > > > > + /* > > > > + * In vhost-mdev, userspace should pass ring addresses > > > > + * in guest physical addresses when IOMMU is disabled or > > > > + * IOVAs when IOMMU is enabled. > > > > + */ > > > A question here, consider we're using noiommu mode. If guest physical > > > address is passed here, how can a device use that? > > > > > > I believe you meant "host physical address" here? And it also have the > > > implication that the HPA should be continuous (e.g using hugetlbfs). > > The comment is talking about the virtual IOMMU (i.e. iotlb in vhost). > > It should be rephrased to cover the noiommu case as well. Thanks for > > spotting this. > > > So the question still, if GPA is passed how can it be used by the > virtio-mdev device? Sorry if I didn't make it clear.. Of course, GPA can't be passed in noiommu mode. > > Thanks >