[PATCH v8 10/10] app/testpmd: add RSS hash algorithms display
Jie Hai
haijie1 at huawei.com
Thu Nov 2 08:33:40 CET 2023
On 2023/11/1 21:42, Ferruh Yigit wrote:
> On 11/1/2023 7:40 AM, Jie Hai wrote:
>> Add the command "show port X rss-hash algorithm" to display
>> the RSS hash algorithms of port X. An example is shown:
>>
>> testpmd> show port 0 rss-hash algorithm
>> RSS algorithm:
>> toeplitz
>>
>> Signed-off-by: Jie Hai <haijie1 at huawei.com>
>> Acked-by: Huisong Li <lihuisong at huawei.com>
>> ---
>> app/test-pmd/cmdline.c | 29 ++++++++++++++++++++++++-----
>> app/test-pmd/config.c | 29 ++++++++++-------------------
>> app/test-pmd/testpmd.h | 2 +-
>>
>
> Can you please update testpmd documentation,
> 'doc/guides/testpmd_app_ug/testpmd_funcs.rst', too?
>
> <...>
Thanks, will add.
>
>> diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
>> index b9fdb7e8f162..23fb4f8aa781 100644
>> --- a/app/test-pmd/config.c
>> +++ b/app/test-pmd/config.c
>> @@ -1504,24 +1504,7 @@ rss_config_display(struct rte_flow_action_rss *rss_conf)
>> printf(" %d", rss_conf->queue[i]);
>> printf("\n");
>>
>> - printf(" function: ");
>> - switch (rss_conf->func) {
>> - case RTE_ETH_HASH_FUNCTION_DEFAULT:
>> - printf("default\n");
>> - break;
>> - case RTE_ETH_HASH_FUNCTION_TOEPLITZ:
>> - printf("toeplitz\n");
>> - break;
>> - case RTE_ETH_HASH_FUNCTION_SIMPLE_XOR:
>> - printf("simple_xor\n");
>> - break;
>> - case RTE_ETH_HASH_FUNCTION_SYMMETRIC_TOEPLITZ:
>> - printf("symmetric_toeplitz\n");
>> - break;
>> - default:
>> - printf("Unknown function\n");
>> - return;
>> - }
>> + printf(" function: %s\n", rte_eth_dev_rss_algo_name(rss_conf->func));
>>
>
>
> Above modification can be moved to the patch that adds
> 'rte_eth_dev_rss_algo_name()'.
>
Thanks, will move.
> .
More information about the dev
mailing list