From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ophir Munk Subject: Re: [PATCH v2] ethdev: document RSS default key and types Date: Tue, 13 Nov 2018 18:04:38 +0000 Message-ID: References: <1541582611-1609-1-git-send-email-ophirmu@mellanox.com> <20181107093109.GG4638@6wind.com> <20181107140604.GL4638@6wind.com> <20181107164118.GM4638@6wind.com> <20181113171519.GF17131@6wind.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Cc: Yongseok Koh , Andrew Rybchenko , Ferruh Yigit , "dev@dpdk.org" , Thomas Monjalon , Asaf Penso , Shahaf Shuler , Olga Shern To: Adrien Mazarguil , Ori Kam Return-path: Received: from EUR03-DB5-obe.outbound.protection.outlook.com (mail-eopbgr40073.outbound.protection.outlook.com [40.107.4.73]) by dpdk.org (Postfix) with ESMTP id 69CDF34F3 for ; Tue, 13 Nov 2018 19:04:41 +0100 (CET) In-Reply-To: <20181113171519.GF17131@6wind.com> Content-Language: en-US List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > -----Original Message----- > From: Adrien Mazarguil [mailto:adrien.mazarguil@6wind.com] > Sent: Tuesday, November 13, 2018 7:15 PM > To: Ori Kam > Cc: Ophir Munk ; Yongseok Koh > ; Andrew Rybchenko > ; Ferruh Yigit ; > dev@dpdk.org; Thomas Monjalon ; Asaf Penso > ; Shahaf Shuler ; Olga > Shern > Subject: Re: [dpdk-dev] [PATCH v2] ethdev: document RSS default key and > types >=20 > Again a bit late to the party, please see below. >=20 > On Sun, Nov 11, 2018 at 09:35:22AM +0000, Ori Kam wrote: > > > -----Original Message----- > > > From: dev On Behalf Of Ophir Munk > > > Sent: Friday, November 9, 2018 10:14 AM > > > To: Yongseok Koh ; Adrien Mazarguil > > > ; Andrew Rybchenko > > > > > > Cc: Ferruh Yigit ; dev@dpdk.org; Thomas > > > Monjalon ; Asaf Penso ; > > > Shahaf Shuler ; Olga Shern > > > > > > Subject: Re: [dpdk-dev] [PATCH v2] ethdev: document RSS default key > > > and types > > > > > > > -----Original Message----- > > > > From: Yongseok Koh > > > > Sent: Friday, November 09, 2018 1:07 AM > > > > To: Ophir Munk ; Adrien Mazarguil > > > > ; Andrew Rybchenko > > > > > > > > Cc: Ferruh Yigit ; dev@dpdk.org; Thomas > > > > Monjalon ; Asaf Penso > ; > > > > Shahaf Shuler ; Olga Shern > > > > > > > > Subject: Re: [dpdk-dev] [PATCH v2] ethdev: document RSS default > > > > key and types > > > > > > > > > > > > > - if (src.rss->key_len) { > > > > + if (src.rss->key && src.rss->key_len) { > > > > > > > > but looks like we should conclude this thread first? > > > > Or, does the fix make any sense regardless of having key_len=3D0 or > > > > key=3Dnull for default key? > > > > Having more sanity check is no harm usually... > > > > > > > > > > > > Thanks, > > > > Yongseok > > > > > > > > > > The setfault is the result of commit a4391f8bae ("app/testpmd: set > > > default RSS key as null"). > > > Reverting this commit should fix the segfault but it also means > > > there is no way to set default key (key=3DNULL) with testpmd. > > > Need to check if this is only a testpmd limitation and not all > > > applications limitation. > > > > > > We should decide how an application can set default RSS without > > > knowing anything about keys. > > > > > > > I agree with Adrian that the main criteria should be the length. > > Maybe the set default RSS in testpmd should get new parameter. >=20 > Since [1] was reverted and we seem to agree that a zero key_len should > trigger a PMD-specific default key, this can already be requested with > testpmd by overriding key_len, e.g.: >=20 > flow create 1 pattern eth / end actions rss key_len 0 / end >=20 Not all agree that zero key_len should trigger default key :) The suggestion is to require applications to set both key=3DNULL and key_le= n=3D=3D0. Individual PMDs will have the option to base default RSS on key_len, key or= both. > Using an empty string as the key would yield the same result but cannot b= e > expressed on the command line yet. Note that specifying a key automatical= ly > overrides key_len, so key_len must be forced to 0 last to get PMD default= s: >=20 > flow create 1 pattern eth / end actions rss key foo key_len 0 / end >=20 > Here key_len is set to testpmd's default size when parsing "rss", updated= to > 3 when parsing "key foo" and updated once again when parsing "key_len 0". >=20 > Lastly, while it would make sense for testpmd to use 0 as the default val= ue, > doing so yields inconsistent balancing results between vendors/devices as > they all come with a different key. Same reason as initializing the RSS t= ypes > field to the global rss_hf instead of 0. >=20 > [1] "app/testpmd: revert setting default RSS" >=20 > https://emea01.safelinks.protection.outlook.com/?url=3Dhttps%3A%2F%2Fmai > ls.dpdk.org%2Farchives%2Fdev%2F2018- > November%2F118786.html&data=3D02%7C01%7Cophirmu%40mellanox.c > om%7Ce765a4cb2c8b4bb1547808d6498ba2a5%7Ca652971c7d2e4d9ba6a4d > 149256f461b%7C0%7C0%7C636777261426945159&sdata=3Dk1NXLzaQeK > fp3yptZQsJd6w0NA%2FUVRb8rctLdkDPIv8%3D&reserved=3D0 >=20 > -- > Adrien Mazarguil > 6WIND