From patchwork Fri Jun 23 16:58:23 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Artemii Morozov X-Patchwork-Id: 128974 X-Patchwork-Delegate: ferruh.yigit@amd.com 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 3A89342D32; Fri, 23 Jun 2023 18:58:36 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id AED0242B7E; Fri, 23 Jun 2023 18:58:32 +0200 (CEST) Received: from agw.arknetworks.am (agw.arknetworks.am [79.141.165.80]) by mails.dpdk.org (Postfix) with ESMTP id C3C0142B71 for ; Fri, 23 Jun 2023 18:58:31 +0200 (CEST) Received: from localhost.localdomain (unknown [37.252.88.53]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by agw.arknetworks.am (Postfix) with ESMTPSA id C0933E12F6; Fri, 23 Jun 2023 20:58:29 +0400 (+04) From: Artemii Morozov To: dev@dpdk.org Cc: Ivan Malov , Viacheslav Galaktionov , Andy Moreton , Andrew Rybchenko , Ferruh Yigit Subject: [PATCH 1/2] common/sfc_efx/base: add MAE IP fragmentation match bits Date: Fri, 23 Jun 2023 20:58:23 +0400 Message-Id: <20230623165824.51908-2-artemii.morozov@arknetworks.am> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230623165824.51908-1-artemii.morozov@arknetworks.am> References: <20230623165824.51908-1-artemii.morozov@arknetworks.am> MIME-Version: 1.0 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 Introduce necessary infrastructure for these bits to be set and validated. Using a combination of these bits IP fragmentation can be configured. Signed-off-by: Artemii Morozov Reviewed-by: Ivan Malov Reviewed-by: Andy Moreton --- drivers/common/sfc_efx/base/efx.h | 4 ++++ drivers/common/sfc_efx/base/efx_mae.c | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/drivers/common/sfc_efx/base/efx.h b/drivers/common/sfc_efx/base/efx.h index 77f855bfb0..efefea717f 100644 --- a/drivers/common/sfc_efx/base/efx.h +++ b/drivers/common/sfc_efx/base/efx.h @@ -4317,6 +4317,10 @@ typedef enum efx_mae_field_id_e { */ EFX_MAE_FIELD_RECIRC_ID, EFX_MAE_FIELD_CT_MARK, + + /* Single bits which can be set by efx_mae_match_spec_bit_set(). */ + EFX_MAE_FIELD_IS_IP_FRAG, + EFX_MAE_FIELD_IP_FIRST_FRAG, EFX_MAE_FIELD_NIDS } efx_mae_field_id_t; diff --git a/drivers/common/sfc_efx/base/efx_mae.c b/drivers/common/sfc_efx/base/efx_mae.c index 9ff887e04b..d36cdc71be 100644 --- a/drivers/common/sfc_efx/base/efx_mae.c +++ b/drivers/common/sfc_efx/base/efx_mae.c @@ -483,6 +483,8 @@ typedef enum efx_mae_field_cap_id_e { EFX_MAE_FIELD_ID_ENC_HAS_IVLAN = MAE_FIELD_ENC_HAS_IVLAN, EFX_MAE_FIELD_ID_RECIRC_ID = MAE_FIELD_RECIRC_ID, EFX_MAE_FIELD_ID_CT_MARK = MAE_FIELD_CT_MARK, + EFX_MAE_FIELD_ID_IS_IP_FRAG = MAE_FIELD_IS_IP_FRAG, + EFX_MAE_FIELD_ID_IP_FIRST_FRAG = MAE_FIELD_IP_FIRST_FRAG, EFX_MAE_FIELD_CAP_NIDS } efx_mae_field_cap_id_t; @@ -668,6 +670,8 @@ static const efx_mae_mv_bit_desc_t __efx_mae_action_rule_mv_bit_desc_set[] = { EFX_MAE_MV_BIT_DESC(HAS_IVLAN), EFX_MAE_MV_BIT_DESC(ENC_HAS_OVLAN), EFX_MAE_MV_BIT_DESC(ENC_HAS_IVLAN), + EFX_MAE_MV_BIT_DESC(IS_IP_FRAG), + EFX_MAE_MV_BIT_DESC(IP_FIRST_FRAG), #undef EFX_MAE_MV_BIT_DESC };