From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) by dpdk.org (Postfix) with ESMTP id 19F774F90 for ; Mon, 5 Nov 2018 22:47:42 +0100 (CET) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id A3E072271B; Mon, 5 Nov 2018 16:47:41 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Mon, 05 Nov 2018 16:47:41 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=mesmtp; bh=CCjk35cP3ShvxFOhrWaWQ4bi5ODo/by6jaatDAwl3QY=; b=AMg2B8fUisV+ Fsrm6tVNDmUBK3gOA+1RZgg0GqfgriJBmZKoXnVYs5hTloo2TyHO3YRwctjENvt0 f//JxJQA4WBDNv4zN7dOFXl8KqglbloJWeVc97LHAtdQLFaAn6sq5h351kwfKTkG z76zsOfbl6E5nP8qiurJGbTzPA87bb0= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=CCjk35cP3ShvxFOhrWaWQ4bi5ODo/by6jaatDAwl3 QY=; b=zCzUVb4vimfsSabS45oeWI0+aqquDUv+t7+jDIWteZOUEdWcdSTR+xBun S6DZca3UIvO/UmtVll2OZBOmcZ8+766wFJTk1O7Y3qpJ0gbeYrjfJY0hqKGIggY/ 2hVWwYtslyrRjoagtnhJR3Nv3bM/7Q0Gx/mVm/9AEhhoZRrx0eLznZ/OiSUFkeS5 /RSUAE4pyvyKRMHPtnZD51HrHcBYg2qah/m5/yCnJWokNAjAprCiIPXgoi8cnGL4 ZW8XC6cpRgcyVEmQ9QoKYHlnFDKMOcElSljYLb0AMECrWU6jTBDqZXAyha+B6ndf V2kahaUQLUuC4G9k9u7+srEJOhSYg== X-ME-Sender: X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 218BEE4A43; Mon, 5 Nov 2018 16:47:40 -0500 (EST) From: Thomas Monjalon To: Ophir Munk Cc: dev@dpdk.org, Ferruh Yigit , Andrew Rybchenko , Asaf Penso , Shahaf Shuler , Olga Shern , Yongseok Koh Date: Mon, 05 Nov 2018 22:47:38 +0100 Message-ID: <2255663.byWF4y053J@xps> In-Reply-To: <1541259953-4273-1-git-send-email-ophirmu@mellanox.com> References: <1541259953-4273-1-git-send-email-ophirmu@mellanox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH v1] ethdev: document RSS default key and types X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Nov 2018 21:47:42 -0000 This patch is in next-net but may be improved before reaching mainline. The comments may be shorter and avoid being split in 2 parts. The second part of the doxygen comments, starting with /**, will apply wrongly to the next field. 03/11/2018 16:46, Ophir Munk: > struct rte_flow_action_rss include fields 'key' and 'types'. > Field 'key' is a pointer to bytes array (uint8_t *) which contains the > specific RSS hash key. > If an application is only interested in default RSS operation it > should not care about the specific hash key. The application can set > the hash key to NULL such that any PMD uses its default RSS key. > > Field 'types' is a uint64_t bits flag used to specify a specific RSS > hash type such as ETH_RSS_IP (see ETH_RSS_*). > If an application does not care about the specific RSS type it can set > this field to 0 such that any PMD uses its default type. > > Signed-off-by: Ophir Munk > --- > v1: Initial version > > --- a/lib/librte_ethdev/rte_flow.h > +++ b/lib/librte_ethdev/rte_flow.h > @@ -1782,13 +1782,29 @@ struct rte_flow_action_rss { > * through. > */ > uint32_t level; > - uint64_t types; /**< Specific RSS hash types (see ETH_RSS_*). */ > + uint64_t types; /**< Specific RSS hash types (see ETH_RSS_*) or 0 */ > + /** > + * Applications should supply specific RSS hash types (e.g. > + * ETH_RSS_IP). If the application does not care about the specific RSS > + * types it can set them to 0 and let any PMD use its default types. > + */ > uint32_t key_len; /**< Hash key length in bytes. */ > uint32_t queue_num; /**< Number of entries in @p queue. */ > - const uint8_t *key; /**< Hash key. */ > + const uint8_t *key; /**< Hash key (can be NULL). */ > + /** > + * The key is a pointer to hash bytes array. > + * > + * Applications should supply a specific RSS hash key. > + * If an application is only interested in default RSS operation it > + * should not care about the specific hash key. By setting the hash > + * key to NULL - any PMD will use its default RSS key. > + */ > const uint16_t *queue; /**< Queue indices to use. */ > }; > > + > + > + > /** > * RTE_FLOW_ACTION_TYPE_VF > *