From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 6706DA0548; Mon, 30 Aug 2021 02:49:17 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id F0D5C4068A; Mon, 30 Aug 2021 02:49:16 +0200 (CEST) Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by mails.dpdk.org (Postfix) with ESMTP id B475F40142 for ; Mon, 30 Aug 2021 02:49:14 +0200 (CEST) X-IronPort-AV: E=McAfee;i="6200,9189,10091"; a="216342390" X-IronPort-AV: E=Sophos;i="5.84,362,1620716400"; d="scan'208";a="216342390" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Aug 2021 17:49:12 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.84,362,1620716400"; d="scan'208";a="426978657" Received: from fmsmsx604.amr.corp.intel.com ([10.18.126.84]) by orsmga006.jf.intel.com with ESMTP; 29 Aug 2021 17:49:11 -0700 Received: from shsmsx605.ccr.corp.intel.com (10.109.6.215) by fmsmsx604.amr.corp.intel.com (10.18.126.84) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.10; Sun, 29 Aug 2021 17:49:10 -0700 Received: from shsmsx601.ccr.corp.intel.com (10.109.6.141) by SHSMSX605.ccr.corp.intel.com (10.109.6.215) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.10; Mon, 30 Aug 2021 08:49:03 +0800 Received: from shsmsx601.ccr.corp.intel.com ([10.109.6.141]) by SHSMSX601.ccr.corp.intel.com ([10.109.6.141]) with mapi id 15.01.2242.010; Mon, 30 Aug 2021 08:49:03 +0800 From: "Zhang, Qi Z" To: Qiming Chen , "dev@dpdk.org" CC: "Xing, Beilei" Thread-Topic: [dpdk-dev] [PATCH v3] net/i40e: solve vf vlan strip Thread-Index: AQHXmoMlYxVZhqo7FkCppF1ZaFETcquFTPUAgAXvI1A= Date: Mon, 30 Aug 2021 00:49:03 +0000 Message-ID: <971158fdfa0640fcb1d8fb40a3de24e7@intel.com> References: <20210826140158.1232-1-chenqiming_huawei@163.com> <20210826140956.1291-1-chenqiming_huawei@163.com> In-Reply-To: <20210826140956.1291-1-chenqiming_huawei@163.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-reaction: no-action dlp-version: 11.5.1.3 dlp-product: dlpe-windows x-originating-ip: [10.239.127.36] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v3] net/i40e: solve vf vlan strip X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > -----Original Message----- > From: dev On Behalf Of Qiming Chen > Sent: Thursday, August 26, 2021 10:10 PM > To: dev@dpdk.org > Cc: Xing, Beilei ; Qiming Chen > > Subject: [dpdk-dev] [PATCH v3] net/i40e: solve vf vlan strip >=20 > Kernel PF+DPDK VF mode, after vf adds vlan, the test result shows that th= e vlan > received from vf has been stripped. >=20 > The patch solves the problem that the kernel i40e.ko driver strips the vl= an by > default after vf adds vlan. Determine whether to strip vlan through the > DEV_RX_OFFLOAD_VLAN_STRIP mask bit in rxmode.offload. >=20 > Environmental information: > 1) dpdk 19.11 > 2) Kernel PF i40e.ko: 2.7.12 > 3) Firmware: 6.01 0x800034a3 1.1747.0 >=20 > I did not use testpmd to test vlan filter, but write Demo for testing bas= ed on > the following deployment: > 1) x710 nic, use 2 PFs, each PF virtualizes 1 VF > 2) 2 pf connected with fiber optic cable > 3) 2 vf are hard to pass through to the VM > 4) In vm, dpdk takes over the vf port, > 5) One port is used as the sending port, and the other port is used as th= e > receiving port, e.g. xmit portid is 0, rx portid is 1 >=20 > Use the default configuration for port 0 as the sender, and configure por= t 1 as > the receiving port as follows: > 1) rte_eth_dev_set_vlan_offload(1, ETH_VLAN_FILTER_OFFLOAD) > 2) rte_eth_dev_vlan_filter(1, 100, 1) >=20 > Do the following tests: > Demo constructs a message with vlan 100 to be sent from port 0, and found > that the vlan header of the message received from port 1 was stripped. As i40evf will be removed in DPDK 21.11, so please submit a patch target to= LTS directly. Thanks Qi