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 250B2A0540; Thu, 7 Jul 2022 11:07:41 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 69B2641147; Thu, 7 Jul 2022 11:07:39 +0200 (CEST) Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) by mails.dpdk.org (Postfix) with ESMTP id D9BD6406B4 for ; Thu, 7 Jul 2022 11:07:37 +0200 (CEST) Received: from compute2.internal (compute2.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 9F40A5C00B6; Thu, 7 Jul 2022 05:07:36 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Thu, 07 Jul 2022 05:07:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= cc:cc:content-transfer-encoding:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm3; t=1657184856; x= 1657271256; bh=HfjvZ+JM9o2EIzkYZlkretIckA0f/7+pNawIl4yDv6w=; b=M PHBB5NFEg4isVLES5xKwr0uyTuPPpO4ScMX+tKrJGU47wU/81XWZXGVtUpvDoet5 mk+iSMMhrr/BEq5qXkU9/jpDirZY7tn4wSKKWeIcq8ZQLmAa41uAlwCGwmMWxQgu WWISg3dRMn728htgiqToSdcK72/tG9lu6/qpThkuw1LTxoMoLjRz0YJcNQ90+Asq b2C7HGn6KTnKeLpJ986WsGea8WtgoNmbCg3ZlZ1or1EWFDOYnBPIYDPLSlg8krWQ LKmUSoVrZlGvgdI4TnVYGjqPCgTvZTdOeTDJun3A5sG6JrOQQlI6uZ7bW0usP27C YTqrCpUtTcl6SxGk3mUOA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1657184856; x= 1657271256; bh=HfjvZ+JM9o2EIzkYZlkretIckA0f/7+pNawIl4yDv6w=; b=a BU4AAjQkkftXkkcpnRnA9kC6bclTgqUZhhqPiMJlQjejssdkIjXy1REGNzWyL5FY kVZdW3zQz1wwtR8WY1tg/viXsd3xGza9Mpo3nAmv7tVl2auEsRnEvCfES9Rq2zGB SNIX+fcpUWJuCfYdtuKo6fxdCbb8NvlGVKTMxOT34jhqhYGB0R6FGIs2hnI/UAq5 oNGcMRfzi7Rfr8kf72J29c3FXauzCpAqsae/tLMm41ywdyCio5uhmzteDsYEbb6g nGlg/7+bnKwcyFTRsHs3NT5Ag+psx1TNHp+Bo1ETHh0PD3VSJ6ZDF2v05RScBQNJ LFLSAXtrvAgqr2+gbbmCA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrudeihedgudduucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvvefufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhm rghsucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenuc ggtffrrghtthgvrhhnpedtjeeiieefhedtfffgvdelteeufeefheeujefgueetfedttdei kefgkeduhedtgfenucevlhhushhtvghrufhiiigvpedunecurfgrrhgrmhepmhgrihhlfh hrohhmpehthhhomhgrshesmhhonhhjrghlohhnrdhnvght X-ME-Proxy: Feedback-ID: i47234305:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 7 Jul 2022 05:07:34 -0400 (EDT) From: Thomas Monjalon To: wenxuanx.wu@intel.com Cc: andrew.rybchenko@oktetlabs.ru, xiaoyun.li@intel.com, ferruh.yigit@xilinx.com, aman.deep.singh@intel.com, dev@dpdk.org, yuying.zhang@intel.com, qi.z.zhang@intel.com, jerinjacobk@gmail.com, stephen@networkplumber.org, Wenxuan Wu , Xuan Ding , Yuan Wang , Ray Kinsella Subject: Re: [PATCH v9 2/4] ethdev: introduce protocol hdr based buffer split Date: Thu, 07 Jul 2022 11:07:32 +0200 Message-ID: <3814226.y1PWrYsiD0@thomas> In-Reply-To: <20220613102550.241759-3-wenxuanx.wu@intel.com> References: <20220303060136.36427-1-xuan.ding@intel.com> <20220613102550.241759-1-wenxuanx.wu@intel.com> <20220613102550.241759-3-wenxuanx.wu@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" 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 13/06/2022 12:25, wenxuanx.wu@intel.com: > --- a/lib/ethdev/rte_ethdev.h > +++ b/lib/ethdev/rte_ethdev.h > @@ -1176,6 +1176,9 @@ struct rte_eth_txmode { > * specified in the first array element, the second buffer, from the > * pool in the second element, and so on. > * > + * - The proto_hdrs in the elements define the split position of > + * received packets. > + * > * - The offsets from the segment description elements specify > * the data offset from the buffer beginning except the first mbuf. > * The first segment offset is added with RTE_PKTMBUF_HEADROOM. > @@ -1197,12 +1200,21 @@ struct rte_eth_txmode { > * - pool from the last valid element > * - the buffer size from this pool > * - zero offset > + * > + * - Length based buffer split: > + * - mp, length, offset should be configured. > + * - The proto_hdr field should not be configured. > + * > + * - Protocol header based buffer split: > + * - mp, offset, proto_hdr should be configured. > + * - The length field should not be configured. > */ > struct rte_eth_rxseg_split { > struct rte_mempool *mp; /**< Memory pool to allocate segment from. */ > uint16_t length; /**< Segment data length, configures split point. */ > uint16_t offset; /**< Data offset from beginning of mbuf data buffer. */ > - uint32_t reserved; /**< Reserved field. */ > + /**< Supported ptypes mask of a specific pmd, configures split point. */ The doxygen syntax is wrong: remove the "<" which is for post-comment. > + uint32_t proto_hdr; > }; How do we know it is a length or buffer split? Is it based on checking some 0 value?