From patchwork Tue Apr 20 08:38:17 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Liu, Lingyu" X-Patchwork-Id: 91804 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 4C01CA0524; Tue, 20 Apr 2021 04:03:46 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6EA4F41587; Tue, 20 Apr 2021 04:03:45 +0200 (CEST) Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by mails.dpdk.org (Postfix) with ESMTP id 9BD0241586 for ; Tue, 20 Apr 2021 04:03:43 +0200 (CEST) IronPort-SDR: 0rWubXyy2456ZHYvkYaWZAZnSAbI9Tc2vLImK1V2W/Z4eA6q/ayIRsYeaEfbpCBKfqQeegUlKV 6eKNDfJO9yuQ== X-IronPort-AV: E=McAfee;i="6200,9189,9959"; a="216012638" X-IronPort-AV: E=Sophos;i="5.82,235,1613462400"; d="scan'208";a="216012638" Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Apr 2021 19:03:43 -0700 IronPort-SDR: GMFqyVJaGxMwzI9zkZYqI4VaSHWc516920E1OQp5d3XAukquAstR6UCX4zNAoL9Jp0NTcmQNwD 2/85NbR5Ojow== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.82,235,1613462400"; d="scan'208";a="602317193" Received: from dpdk-liulingy-1.sh.intel.com ([10.67.118.243]) by orsmga005.jf.intel.com with ESMTP; 19 Apr 2021 19:03:40 -0700 From: Lingyu Liu To: dev@dpdk.org, qi.z.zhang@intel.com, olivier.matz@6wind.com, thomas@monjalon.net, david.marchand@redhat.com Cc: Lingyu Liu Date: Tue, 20 Apr 2021 08:38:17 +0000 Message-Id: <20210420083817.10741-3-lingyu.liu@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210420083817.10741-1-lingyu.liu@intel.com> References: <20210417092531.6001-1-lingyu.liu@intel.com> <20210420083817.10741-1-lingyu.liu@intel.com> MIME-Version: 1.0 Subject: [dpdk-dev] [PATCH V3 2/2] net/iavf: update PTYPE mapping for eCPRI 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" 1.Map IPV4/IPV6 UDP eCPRI to L4_UDP_TUNNEL_ECPRI ptype. 2.Add L2_ETHER_ECPRI ptype and map ETHER eCPRI to L2_ETHER_ECPRI ptype. Signed-off-by: Lingyu Liu --- drivers/net/iavf/iavf_rxtx.c | 52 ++++++++++++++++++++++-------------- 1 file changed, 32 insertions(+), 20 deletions(-) diff --git a/drivers/net/iavf/iavf_rxtx.c b/drivers/net/iavf/iavf_rxtx.c index 3f3cf6306c..30a8497c45 100644 --- a/drivers/net/iavf/iavf_rxtx.c +++ b/drivers/net/iavf/iavf_rxtx.c @@ -3349,49 +3349,61 @@ iavf_get_default_ptype_table(void) RTE_PTYPE_INNER_L3_IPV6_EXT_UNKNOWN | RTE_PTYPE_INNER_L4_ICMP, + /* Ether --> ECPRI */ + [362] = RTE_PTYPE_L2_ETHER_ECPRI, + [363] = RTE_PTYPE_L2_ETHER_ECPRI, + [364] = RTE_PTYPE_L2_ETHER_ECPRI, + [365] = RTE_PTYPE_L2_ETHER_ECPRI, + [366] = RTE_PTYPE_L2_ETHER_ECPRI, + [367] = RTE_PTYPE_L2_ETHER_ECPRI, + [368] = RTE_PTYPE_L2_ETHER_ECPRI, + [369] = RTE_PTYPE_L2_ETHER_ECPRI, + [370] = RTE_PTYPE_L2_ETHER_ECPRI, + [371] = RTE_PTYPE_L2_ETHER_ECPRI, + /* IPv4 --> UDP ECPRI */ [372] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV4_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [373] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV4_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [374] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV4_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [375] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV4_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [376] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV4_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [377] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV4_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [378] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV4_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [379] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV4_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [380] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV4_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [381] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV4_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, /* IPV6 --> UDP ECPRI */ [382] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV6_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [383] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV6_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [384] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV6_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [385] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV6_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [386] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV6_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [387] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV6_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [388] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV6_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [389] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV6_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [390] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV6_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, [391] = RTE_PTYPE_L2_ETHER | RTE_PTYPE_L3_IPV6_EXT_UNKNOWN | - RTE_PTYPE_L4_UDP, + RTE_PTYPE_TUNNEL_ECPRI | RTE_PTYPE_L4_UDP, /* All others reserved */ };