From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id BDBE72C5E for ; Fri, 30 Mar 2018 11:35:58 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga101.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 30 Mar 2018 02:35:57 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.48,381,1517904000"; d="scan'208";a="212588474" Received: from fmsmsx104.amr.corp.intel.com ([10.18.124.202]) by orsmga005.jf.intel.com with ESMTP; 30 Mar 2018 02:35:56 -0700 Received: from fmsmsx152.amr.corp.intel.com (10.18.125.5) by fmsmsx104.amr.corp.intel.com (10.18.124.202) with Microsoft SMTP Server (TLS) id 14.3.319.2; Fri, 30 Mar 2018 02:35:56 -0700 Received: from shsmsx101.ccr.corp.intel.com (10.239.4.153) by FMSMSX152.amr.corp.intel.com (10.18.125.5) with Microsoft SMTP Server (TLS) id 14.3.319.2; Fri, 30 Mar 2018 02:35:55 -0700 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.235]) by SHSMSX101.ccr.corp.intel.com ([169.254.1.166]) with mapi id 14.03.0319.002; Fri, 30 Mar 2018 17:35:53 +0800 From: "Wang, Zhihong" To: "Wodkowski, PawelX" , "dev@dpdk.org" CC: "Tan, Jianfeng" , "Bie, Tiwei" , "maxime.coquelin@redhat.com" , "yliu@fridaylinux.org" , "Liang, Cunming" , "Wang, Xiao W" , "Daly, Dan" Thread-Topic: [dpdk-dev] [PATCH v3 0/5] vhost: support selective datapath Thread-Index: AQHTv2rZ99NzPnmDfU2nUg1jXGK576PmqjmAgAHnvOA= Date: Fri, 30 Mar 2018 09:35:53 +0000 Message-ID: <8F6C2BD409508844A0EFC19955BE094151415EE3@SHSMSX103.ccr.corp.intel.com> References: <1517614137-62926-1-git-send-email-zhihong.wang@intel.com> <20180227101342.18521-1-zhihong.wang@intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v3 0/5] vhost: support selective datapath X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 30 Mar 2018 09:36:00 -0000 Pawel, > > 3. To make vhost aware of its own type, an engine id (eid) and a devic= e > > id (did) are added into the vhost data structure to identify the ac= tual > > device. APIs are introduced to let app configure them. When the def= ault > > software datapath is used, eid and did are set to -1. When alternat= ive > > datapath is used, eid and did are set by app to specify which devic= e to > > use. Each vhost-user socket can have only 1 connection in this case= . >=20 > Why only one connection is possible? We are already working on multiple > simultaneous connections in SPDK. So this will be some kind of step > backward. Nothing is changed for existing use cases. This design is only true when alternative vDPA backend (most likely HW) is used, because in this case resource locking per vhost port is required for provisioning consideration. >=20 > > > > Working process: > > =3D=3D=3D=3D > > > > 1. Register driver during DPDK initialization. > > > > 2. Register engine with driver name and address. > > > > 3. Get engine attributes. > > > > 4. For vhost device creation: > > > > a. Register vhost-user socket. > > > > b. Set eid and did of the vhost-user socket. > > > > c. Register vhost-user callbacks. > > > > d. Start to wait for connection. > > > > 4. When connection comes and virtio device data structure is negotiate= d, > > the device will be configured with all needed info. > > >=20 > Can you please provide new or modify existing example to show how to use > this new API? > It would be easier to find any possible gaps if we can see real use case. This patch has only the lib change, a driver is also in progress at: http://dpdk.org/ml/archives/dev/2018-March/093305.html You can learn how it works from an old RFC patch at: http://dpdk.org/ml/archives/dev/2017-December/085044.html A lot of details are changed, but the idea is the same. -Zhihong