From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by dpdk.org (Postfix) with ESMTP id B7A3B8E83 for ; Thu, 14 Jan 2016 09:28:31 +0100 (CET) Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga103.jf.intel.com with ESMTP; 14 Jan 2016 00:28:21 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.22,293,1449561600"; d="scan'208";a="29145693" Received: from fmsmsx104.amr.corp.intel.com ([10.18.124.202]) by fmsmga004.fm.intel.com with ESMTP; 14 Jan 2016 00:28:20 -0800 Received: from fmsmsx122.amr.corp.intel.com (10.18.125.37) by fmsmsx104.amr.corp.intel.com (10.18.124.202) with Microsoft SMTP Server (TLS) id 14.3.248.2; Thu, 14 Jan 2016 00:28:19 -0800 Received: from shsmsx152.ccr.corp.intel.com (10.239.6.52) by fmsmsx122.amr.corp.intel.com (10.18.125.37) with Microsoft SMTP Server (TLS) id 14.3.248.2; Thu, 14 Jan 2016 00:28:19 -0800 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.215]) by SHSMSX152.ccr.corp.intel.com ([169.254.6.209]) with mapi id 14.03.0248.002; Thu, 14 Jan 2016 16:28:17 +0800 From: "Xie, Huawei" To: Yuanhan Liu Thread-Topic: [PATCH v2 7/7] virtio: add 1.0 support Thread-Index: AdFOn8qVIMp9mFhvQbG10T5nROu3pg== Date: Thu, 14 Jan 2016 08:28:17 +0000 Message-ID: References: <1449719650-3482-1-git-send-email-yuanhan.liu@linux.intel.com> <1452581944-24838-1-git-send-email-yuanhan.liu@linux.intel.com> <1452581944-24838-8-git-send-email-yuanhan.liu@linux.intel.com> <20160114075040.GM19531@yliu-dev.sh.intel.com> <20160114075859.GN19531@yliu-dev.sh.intel.com> <20160114082221.GO19531@yliu-dev.sh.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.4.80] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "dev@dpdk.org" , "Michael S. Tsirkin" Subject: Re: [dpdk-dev] [PATCH v2 7/7] virtio: add 1.0 support X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Jan 2016 08:28:32 -0000 On 1/14/2016 4:21 PM, Yuanhan Liu wrote:=0A= > On Thu, Jan 14, 2016 at 08:08:28AM +0000, Xie, Huawei wrote:=0A= >> On 1/14/2016 3:58 PM, Yuanhan Liu wrote:=0A= >>> On Thu, Jan 14, 2016 at 07:51:08AM +0000, Xie, Huawei wrote:=0A= >>>> On 1/14/2016 3:49 PM, Yuanhan Liu wrote:=0A= >>>>> On Thu, Jan 14, 2016 at 07:47:17AM +0000, Xie, Huawei wrote:=0A= >>>>>> On 1/12/2016 2:58 PM, Yuanhan Liu wrote:=0A= >>>>>>> Modern (v1.0) virtio pci device defines several pci capabilities.= =0A= >>>>>> [snip]=0A= >>>>>>> +static void=0A= >>>>>>> +modern_notify_queue(struct virtio_hw *hw __rte_unused, struct virt= queue *vq)=0A= >>>>>>> +{=0A= >>>>>>> + modern_write16(1, vq->notify_addr);=0A= >>>>>>> +}=0A= >>>>>> Does virtio 1.0 only supports MMIO? MMIO has long VMEXIT latency tha= n=0A= >>>>>> PORT IO.=0A= >>>>> Virtio 1.0 supports three transport layer, including MMIO and PCI. An= d=0A= >>>>> we use PCI only in our pmd driver.=0A= >>>> I don't mean that MMIO but use memory mapped IO for configuration.=0A= >>> Then, yes.=0A= >> 00:03.0 Ethernet controller: Red Hat, Inc Virtio network device=0A= >> Subsystem: Red Hat, Inc Device 0001=0A= >> Physical Slot: 3=0A= >> Flags: bus master, fast devsel, latency 0, IRQ 10=0A= >> I/O ports at c100 [size=3D32]=0A= >> Memory at febd1000 (32-bit, non-prefetchable) [size=3D4K]=0A= >> Memory at fe000000 (64-bit, prefetchable) [size=3D8M]=0A= >> Expansion ROM at feb40000 [disabled] [size=3D256K]=0A= >> Capabilities: [98] MSI-X: Enable+ Count=3D3 Masked-=0A= >> Capabilities: [84] Vendor Specific Information: Len=3D14 =0A= >> Capabilities: [70] Vendor Specific Information: Len=3D14 =0A= >> Capabilities: [60] Vendor Specific Information: Len=3D10 =0A= >> Capabilities: [50] Vendor Specific Information: Len=3D10 =0A= >> Capabilities: [40] Vendor Specific Information: Len=3D10 =0A= >> Kernel driver in use: igb_uio=0A= >> Kernel modules: virtio_pci=0A= >>=0A= >> c100 is still there.=0A= > Yes,=0A= >=0A= >> For the notification, try PORT IO if possible.=0A= > But it doesn't seem right to me to mix legacy registers in modern pci dev= ice.=0A= =0A= On TLB and cache miss, this could cause plenty of cycles. Considering=0A= that our current focus is dpdkvhost which doesn't need notification, let=0A= us revisit this later.=0A= =0A= >=0A= > --yliu=0A= >=0A= =0A=