From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id 1E7DC200 for ; Mon, 4 Dec 2017 09:45:50 +0100 (CET) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 04 Dec 2017 00:45:48 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.45,358,1508828400"; d="scan'208";a="10205496" Received: from fmsmsx107.amr.corp.intel.com ([10.18.124.205]) by fmsmga001.fm.intel.com with ESMTP; 04 Dec 2017 00:45:27 -0800 Received: from fmsmsx123.amr.corp.intel.com (10.18.125.38) by fmsmsx107.amr.corp.intel.com (10.18.124.205) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 4 Dec 2017 00:45:27 -0800 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by fmsmsx123.amr.corp.intel.com (10.18.125.38) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 4 Dec 2017 00:45:27 -0800 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.159]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.218]) with mapi id 14.03.0319.002; Mon, 4 Dec 2017 16:45:25 +0800 From: "Xing, Beilei" To: "Wu, Jingjing" , "dev@dpdk.org" CC: "Wu, Jingjing" , "Lu, Wenzhuo" Thread-Topic: [dpdk-dev] [PATCH v2 03/14] net/avf: enable queue and device Thread-Index: AQHTZO9tNAsYhjJQCk2zAAbJsXPDrqMy7X/Q Date: Mon, 4 Dec 2017 08:45:25 +0000 Message-ID: <94479800C636CB44BD422CB454846E0132077B00@SHSMSX101.ccr.corp.intel.com> References: <1508488012-82704-1-git-send-email-jingjing.wu@intel.com> <1511505206-97333-1-git-send-email-jingjing.wu@intel.com> <1511505206-97333-4-git-send-email-jingjing.wu@intel.com> In-Reply-To: <1511505206-97333-4-git-send-email-jingjing.wu@intel.com> 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 v2 03/14] net/avf: enable queue and device 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: Mon, 04 Dec 2017 08:45:51 -0000 > -----Original Message----- > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Jingjing Wu > Sent: Friday, November 24, 2017 2:33 PM > To: dev@dpdk.org > Cc: Wu, Jingjing ; Lu, Wenzhuo > > Subject: [dpdk-dev] [PATCH v2 03/14] net/avf: enable queue and device >=20 > enable device and queue setup ops like: >=20 > - dev_configure > - dev_start > - dev_stop > - dev_close > - dev_infos_get > - rx_queue_start > - rx_queue_stop > - tx_queue_start > - tx_queue_stop > - rx_queue_setup > - rx_queue_release > - tx_queue_setup > - tx_queue_release >=20 > Signed-off-by: Jingjing Wu > --- > drivers/net/avf/Makefile | 1 + > drivers/net/avf/avf.h | 18 ++ > drivers/net/avf/avf_ethdev.c | 356 ++++++++++++++++++++++++ > drivers/net/avf/avf_rxtx.c | 644 > +++++++++++++++++++++++++++++++++++++++++++ > drivers/net/avf/avf_rxtx.h | 202 ++++++++++++++ > drivers/net/avf/avf_vchnl.c | 355 ++++++++++++++++++++++++ > 6 files changed, 1576 insertions(+) > create mode 100644 drivers/net/avf/avf_rxtx.c > create mode 100644 drivers/net/avf/avf_rxtx.h >=20 > static const struct eth_dev_ops avf_eth_dev_ops =3D { > + .dev_configure =3D avf_dev_configure, > + .dev_start =3D avf_dev_start, > + .dev_stop =3D avf_dev_stop, > + .dev_close =3D avf_dev_close, > + .dev_infos_get =3D avf_dev_info_get, > + .rx_queue_start =3D avf_dev_rx_queue_start, > + .rx_queue_stop =3D avf_dev_rx_queue_stop, > + .tx_queue_start =3D avf_dev_tx_queue_start, > + .tx_queue_stop =3D avf_dev_tx_queue_stop, > + .rx_queue_setup =3D avf_dev_rx_queue_setup, > + .rx_queue_release =3D avf_dev_rx_queue_release, > + .tx_queue_setup =3D avf_dev_tx_queue_setup, > + .tx_queue_release =3D avf_dev_tx_queue_release, > }; >=20 > static int > +avf_dev_configure(struct rte_eth_dev *dev) > +{ > + struct avf_adapter *ad =3D > + AVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private); > + struct rte_eth_conf *dev_conf =3D &dev->data->dev_conf; > + > + /* Vlan stripping setting */ > + if (dev_conf->rxmode.offloads & DEV_RX_OFFLOAD_VLAN_STRIP) > + avf_enable_vlan_strip(ad); > + else > + avf_disable_vlan_strip(ad); Better to check PF capability first before setting VLAN offload. > + return 0; > +} > + > +