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 67AF045644; Thu, 18 Jul 2024 13:48:32 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3D8B3402D5; Thu, 18 Jul 2024 13:48:32 +0200 (CEST) Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by mails.dpdk.org (Postfix) with ESMTP id 244C0402A8 for ; Thu, 18 Jul 2024 13:48:30 +0200 (CEST) Received: from mail.maildlp.com (unknown [172.19.163.174]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4WPrdw6JH0znb3c; Thu, 18 Jul 2024 19:47:48 +0800 (CST) Received: from kwepemf500004.china.huawei.com (unknown [7.202.181.242]) by mail.maildlp.com (Postfix) with ESMTPS id 9898F14041A; Thu, 18 Jul 2024 19:48:28 +0800 (CST) Received: from localhost.huawei.com (10.90.30.45) by kwepemf500004.china.huawei.com (7.202.181.242) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.11; Thu, 18 Jul 2024 19:48:27 +0800 From: Jie Hai To: , , , , , Thomas Monjalon , Allain Legacy CC: , , Subject: [PATCH v2 1/3] ethdev: add description for KEEP CRC offload Date: Thu, 18 Jul 2024 19:48:03 +0800 Message-ID: <20240718114806.577298-2-haijie1@huawei.com> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20240718114806.577298-1-haijie1@huawei.com> References: <20240206011030.2007689-1-haijie1@huawei.com> <20240718114806.577298-1-haijie1@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.90.30.45] X-ClientProxiedBy: dggems704-chm.china.huawei.com (10.3.19.181) To kwepemf500004.china.huawei.com (7.202.181.242) 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 From: Dengdui Huang The data execeed the pkt_len in mbuf is inavailable for user. When KEEP CRC offload is enabled, CRC field length should be included pkt_len in mbuf. However, almost of drivers supported KEEP CRC feature didn't add the CRC data length to pkt_len. So it is very necessary to add a coments for this. Fixes: 70815c9ecadd ("ethdev: add new offload flag to keep CRC") Cc: stable@dpdk.org Signed-off-by: Dengdui Huang --- lib/ethdev/rte_ethdev.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/ethdev/rte_ethdev.h b/lib/ethdev/rte_ethdev.h index 548fada1c7..3d44673161 100644 --- a/lib/ethdev/rte_ethdev.h +++ b/lib/ethdev/rte_ethdev.h @@ -1550,6 +1550,12 @@ struct rte_eth_conf { */ #define RTE_ETH_RX_OFFLOAD_TIMESTAMP RTE_BIT64(14) #define RTE_ETH_RX_OFFLOAD_SECURITY RTE_BIT64(15) +/* + * Keep CRC data in packet. + * + * Note: If this offload is enabled, the pkt_len in mbuf should contain + * the CRC data length. + */ #define RTE_ETH_RX_OFFLOAD_KEEP_CRC RTE_BIT64(16) #define RTE_ETH_RX_OFFLOAD_SCTP_CKSUM RTE_BIT64(17) #define RTE_ETH_RX_OFFLOAD_OUTER_UDP_CKSUM RTE_BIT64(18) -- 2.33.0