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 8C20EA0543; Wed, 5 Oct 2022 17:31:24 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4325C40694; Wed, 5 Oct 2022 17:31:24 +0200 (CEST) Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by mails.dpdk.org (Postfix) with ESMTP id DCF7340143 for ; Wed, 5 Oct 2022 17:31:22 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1664983883; x=1696519883; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=r0qTihxgaBXGqk9MzgDTiCzC98QezjLn6KF096JwFGE=; b=Hf+Yjqj+qS2ZFNDV66uY/xs2jO+boVTI+0vvMkagvUQolByDJHVoXtW3 aMniJG3bftn8J5eZy3zuDdptuQ0TSWnt2H50mluFQc9YCcGVscjUkVQen NOYb5reJvyGRHSHln+aVSHOAg0kH492+x9gpdh6bFCamoxLOYlesdrmJ+ uyMz5O8vHdXN/aWYbmLvQgji4iheLkPsOm+DPAeYW46Pa/s1UI9FQgSoT pBmKxQs5Oso4TUprxxcFLHG0wQpGeFS+Xc4emw1VzQhJyctnJkfPj+ZsE 1xZtq7YuusEU6X9J/PwkuQnrl9LljOzJHxs4yUkgqayAkiEk1H/91uRhz Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10491"; a="304170576" X-IronPort-AV: E=Sophos;i="5.95,161,1661842800"; d="scan'208";a="304170576" Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Oct 2022 08:31:21 -0700 X-IronPort-AV: E=McAfee;i="6500,9779,10491"; a="869434537" X-IronPort-AV: E=Sophos;i="5.95,161,1661842800"; d="scan'208";a="869434537" Received: from unknown (HELO localhost.localdomain) ([10.239.252.55]) by fmsmga006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Oct 2022 08:31:17 -0700 From: Yuan Wang To: dev@dpdk.org Cc: thomas@monjalon.net, andrew.rybchenko@oktetlabs.ru, ferruh.yigit@xilinx.com, mdr@ashroe.eu, xiaoyun.li@intel.com, aman.deep.singh@intel.com, yuying.zhang@intel.com, qi.z.zhang@intel.com, qiming.yang@intel.com, jerinjacobk@gmail.com, viacheslavo@nvidia.com, stephen@networkplumber.org, xuan.ding@intel.com, hpothula@marvell.com, yaqi.tang@intel.com, Yuan Wang Subject: [PATCH v8 0/4] support protocol based buffer split Date: Thu, 6 Oct 2022 07:18:32 +0800 Message-Id: <20221005231836.215112-1-yuanx.wang@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220812181552.2908067-1-yuanx.wang@intel.com> References: <20220812181552.2908067-1-yuanx.wang@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 Protocol type based buffer split consists of splitting a received packet into several separate segments based on the packet content. It is useful in some scenarios, such as GPU acceleration. The splitting will help to enable true zero copy and hence improve the performance significantly. This patchset aims to support protocol header split based on current buffer split. When Rx queue is configured with RTE_ETH_RX_OFFLOAD_BUFFER_SPLIT offload and corresponding protocol, packets received will be directly split into different mempools. Change log: v8: Restrict length == 0 and proto_hdr == 0 in another buffer split. Add check for proto_hdr == 0 in last segment. Use heap instead of stack for array to avoid vulnerabilities. Define the proto_hdr for two segments and multi-segments, respectively. Separate variable definition and code. Refine the doc and commit log. v7: ice: Fix CI issue. v6: ice: Fix proto_hdr mappings to NIC configuration. v5: Define proto_hdr to use mask instead of single protocol type. Define PMD to return protocol header mask. Refine the doc and commit log. Remove deprecated RTE_FUNC_PTR_OR_ERR_RET. v4: Change proto_hdr to a bit mask of RTE_PTYPE_*. Add the description on how to put the unsplit packages. Use proto_hdr to determine whether to use protocol based split. v3: Fix mail thread. v2: Add mbuf dump to the driver's buffer split path. Add buffer split to the driver feature list. Remove unsupported header protocols from the driver. Yuan Wang (4): ethdev: introduce protocol header API ethdev: introduce protocol hdr based buffer split app/testpmd: add rxhdrs commands and parameters net/ice: support buffer split in Rx path app/test-pmd/cmdline.c | 152 +++++++++++++- app/test-pmd/config.c | 95 +++++++++ app/test-pmd/parameters.c | 16 +- app/test-pmd/testpmd.c | 11 +- app/test-pmd/testpmd.h | 6 + doc/guides/rel_notes/release_22_11.rst | 13 ++ drivers/net/ice/ice_ethdev.c | 97 ++++++++- drivers/net/ice/ice_rxtx.c | 266 ++++++++++++++++++++++--- drivers/net/ice/ice_rxtx.h | 16 ++ drivers/net/ice/ice_rxtx_vec_common.h | 3 + lib/ethdev/ethdev_driver.h | 15 ++ lib/ethdev/rte_ethdev.c | 122 +++++++++++- lib/ethdev/rte_ethdev.h | 64 +++++- lib/ethdev/version.map | 1 + 14 files changed, 826 insertions(+), 51 deletions(-) -- 2.25.1