From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by dpdk.org (Postfix) with ESMTP id 4A9B5200 for ; Mon, 28 May 2018 04:00:49 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 May 2018 19:00:47 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,450,1520924400"; d="scan'208";a="43290555" Received: from dpdk51.sh.intel.com ([10.67.110.184]) by fmsmga008.fm.intel.com with ESMTP; 27 May 2018 19:00:46 -0700 From: Qi Zhang To: beilei.xing@intel.com Cc: dev@dpdk.org, helin.zhang@intel.com, liang-min.wang@intel.com, Qi Zhang Date: Mon, 28 May 2018 10:01:08 +0800 Message-Id: <20180528020110.37713-1-qi.z.zhang@intel.com> X-Mailer: git-send-email 2.13.6 Subject: [dpdk-dev] [PATCH 0/2] improve i40e VF VLAN performance 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, 28 May 2018 02:00:50 -0000 (target for v18.08) Add vlan to vlan prune table cost additinal firmware cycle that cause significent performance downgrade (40~50%). While remove this will cause vlan anti spoof does not work on VF. The dicision is to take performance as high priority, since 40~50% performance drop is unbearable for most cases, so code part for adding vlan to vlan prune table will be stripped out, while for vlan anti-spoof, we take an alternative way as below: Due to hardware limitation, there is no perfect solution to enable VF vlan antispoof, to enable it means lost something else. So the solution is to introduce devarg "support-vf-vlan-antispoof" that turn on the feature to meet customer's specific requirement while no impact on normal case when it is turned off. Below impact is expected when support-vf-vlan-antispoof is turned on: 1. Multi-driver is not supported since some global register is changed in DPDK driver during init which is no expected by kernel driver. 2. Unicast / Multicase promiscuous mode can not be configured separately. So, function rte_pmd_i40e_set_vf_unicast_promics and rte_pmd_i40e_set_vf_multicast_promisc will fail and new funciton rte_pmd_i40e_set_vf_promics is introduced as a coarse-grain API. 3. VLAN anti-spoof and Mac anti-spoof are always enable/disable together. (rte_eth_set_vf_mac_anti_spoof and rte_eth_set_vf_vlan_anti_spoof do the same thing now.) 4. When VLAN/MAC anti-spoof is turned on, vlan tag will be added to vlan promisc table, so in the rx path, mac address match will be ignored, only vlan will be matched. Qi Zhang (2): net/i40e: improve VF VLAN performance net/i40e: enable VF VLAN antispoof doc/guides/nics/i40e.rst | 28 ++++ drivers/net/i40e/i40e_ethdev.c | 122 +++++++++----- drivers/net/i40e/i40e_ethdev.h | 2 +- drivers/net/i40e/i40e_pf.c | 30 +++- drivers/net/i40e/rte_pmd_i40e.c | 263 ++++++++++++++++-------------- drivers/net/i40e/rte_pmd_i40e.h | 22 +++ drivers/net/i40e/rte_pmd_i40e_version.map | 8 +- 7 files changed, 302 insertions(+), 173 deletions(-) -- 2.13.6