[v5] app/testpmd: add help messages for multi-process

Message ID 20220307010435.56784-1-humin29@huawei.com (mailing list archive)
State Superseded, archived
Delegated to: Ferruh Yigit
Headers
Series [v5] app/testpmd: add help messages for multi-process |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK
ci/intel-Testing success Testing PASS
ci/iol-broadcom-Functional success Functional Testing PASS
ci/iol-mellanox-Performance success Performance Testing PASS
ci/github-robot: build success github build: passed
ci/iol-broadcom-Performance success Performance Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-aarch64-unit-testing success Testing PASS
ci/iol-x86_64-unit-testing success Testing PASS
ci/iol-abi-testing success Testing PASS
ci/iol-x86_64-compile-testing success Testing PASS
ci/iol-aarch64-compile-testing success Testing PASS

Commit Message

humin (Q) March 7, 2022, 1:04 a.m. UTC
  From: Huisong Li <lihuisong@huawei.com>

This patch adds help messages for multi-process.
--num-procs=N: set the total number of multi-process instances
--proc-id=id:  set the id of the current process from multi-process
instances(0 <= id < num-procs)

Fixes: a550baf24af9 ("app/testpmd: support multi-process")
Cc: stable@dpdk.org

Signed-off-by: Huisong Li <lihuisong@huawei.com>
Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
---
v6:
* fix comments.
v5:
* delete space
v4:
* update description for parameters.
v3,v2:
* adjust the position of parameters.
---
 app/test-pmd/parameters.c | 3 +++
 1 file changed, 3 insertions(+)
  

Comments

humin (Q) April 25, 2022, 6:51 a.m. UTC | #1
Hi, Ferruh,
	what do you think of this patch?

在 2022/3/7 9:04, Min Hu (Connor) 写道:
> From: Huisong Li <lihuisong@huawei.com>
> 
> This patch adds help messages for multi-process.
> --num-procs=N: set the total number of multi-process instances
> --proc-id=id:  set the id of the current process from multi-process
> instances(0 <= id < num-procs)
> 
> Fixes: a550baf24af9 ("app/testpmd: support multi-process")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Huisong Li <lihuisong@huawei.com>
> Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
> ---
> v6:
> * fix comments.
> v5:
> * delete space
> v4:
> * update description for parameters.
> v3,v2:
> * adjust the position of parameters.
> ---
>   app/test-pmd/parameters.c | 3 +++
>   1 file changed, 3 insertions(+)
> 
> diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c
> index daf6a31b2b..2834e9e180 100644
> --- a/app/test-pmd/parameters.c
> +++ b/app/test-pmd/parameters.c
> @@ -61,6 +61,9 @@ usage(char* progname)
>   	       "extended statistics to show. Used with --stats-period "
>   	       "specified or interactive commands that show Rx/Tx statistics "
>   	       "(i.e. 'show port stats').\n");
> +	printf("  --num-procs=N: set the total number of multi-process instances\n");
> +	printf("  --proc-id=id:  set the id of the current process from multi-process instances\n"
> +	       "(0 <= id < num-procs).\n");
>   	printf("  --nb-cores=N: set the number of forwarding cores "
>   	       "(1 <= N <= %d).\n", nb_lcores);
>   	printf("  --nb-ports=N: set the number of forwarding ports "
>
  
humin (Q) June 2, 2022, 2:24 a.m. UTC | #2
Hi, all,
    any comments?

在 2022/3/7 9:04, Min Hu (Connor) 写道:
> From: Huisong Li <lihuisong@huawei.com>
> 
> This patch adds help messages for multi-process.
> --num-procs=N: set the total number of multi-process instances
> --proc-id=id:  set the id of the current process from multi-process
> instances(0 <= id < num-procs)
> 
> Fixes: a550baf24af9 ("app/testpmd: support multi-process")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Huisong Li <lihuisong@huawei.com>
> Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
> ---
> v6:
> * fix comments.
> v5:
> * delete space
> v4:
> * update description for parameters.
> v3,v2:
> * adjust the position of parameters.
> ---
>   app/test-pmd/parameters.c | 3 +++
>   1 file changed, 3 insertions(+)
> 
> diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c
> index daf6a31b2b..2834e9e180 100644
> --- a/app/test-pmd/parameters.c
> +++ b/app/test-pmd/parameters.c
> @@ -61,6 +61,9 @@ usage(char* progname)
>   	       "extended statistics to show. Used with --stats-period "
>   	       "specified or interactive commands that show Rx/Tx statistics "
>   	       "(i.e. 'show port stats').\n");
> +	printf("  --num-procs=N: set the total number of multi-process instances\n");
> +	printf("  --proc-id=id:  set the id of the current process from multi-process instances\n"
> +	       "(0 <= id < num-procs).\n");
>   	printf("  --nb-cores=N: set the number of forwarding cores "
>   	       "(1 <= N <= %d).\n", nb_lcores);
>   	printf("  --nb-ports=N: set the number of forwarding ports "
>
  
Ferruh Yigit June 2, 2022, 11:08 p.m. UTC | #3
On 6/2/2022 3:24 AM, Min Hu (Connor) wrote:
> Hi, all,
>     any comments?
> 
> 在 2022/3/7 9:04, Min Hu (Connor) 写道:
>> From: Huisong Li <lihuisong@huawei.com>
>>
>> This patch adds help messages for multi-process.
>> --num-procs=N: set the total number of multi-process instances
>> --proc-id=id:  set the id of the current process from multi-process
>> instances(0 <= id < num-procs)
>>
>> Fixes: a550baf24af9 ("app/testpmd: support multi-process")
>> Cc: stable@dpdk.org
>>
>> Signed-off-by: Huisong Li <lihuisong@huawei.com>
>> Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
>> ---
>> v6:
>> * fix comments.
>> v5:
>> * delete space
>> v4:
>> * update description for parameters.
>> v3,v2:
>> * adjust the position of parameters.
>> ---
>>   app/test-pmd/parameters.c | 3 +++
>>   1 file changed, 3 insertions(+)
>>
>> diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c
>> index daf6a31b2b..2834e9e180 100644
>> --- a/app/test-pmd/parameters.c
>> +++ b/app/test-pmd/parameters.c
>> @@ -61,6 +61,9 @@ usage(char* progname)
>>              "extended statistics to show. Used with --stats-period "
>>              "specified or interactive commands that show Rx/Tx 
>> statistics "
>>              "(i.e. 'show port stats').\n");
>> +    printf("  --num-procs=N: set the total number of multi-process 
>> instances\n");
>> +    printf("  --proc-id=id:  set the id of the current process from 
>> multi-process instances\n"
>> +           "(0 <= id < num-procs).\n");
>>       printf("  --nb-cores=N: set the number of forwarding cores "
>>              "(1 <= N <= %d).\n", nb_lcores);
>>       printf("  --nb-ports=N: set the number of forwarding ports "
>>

Hi Connor,

output is as following [1], is "(0 <= id < num-procs)." part break into 
next line intentionally? This breaks the output.

I assume the line is broken in source code to fit into line length, but 
it doesn't have to break the line in output, what do you think?


[1]
...
   --num-procs=N: set the total number of multi-process instances
   --proc-id=id:  set the id of the current process from multi-process ..
(0 <= id < num-procs).
   --nb-cores=N: set the number of forwarding cores (1 <= N <= 55).
...
  
Dongdong Liu June 9, 2022, 8:07 a.m. UTC | #4
Hi Ferruh

Many thanks for your review.
On 2022/6/3 7:08, Ferruh Yigit wrote:
> On 6/2/2022 3:24 AM, Min Hu (Connor) wrote:
>> Hi, all,
>>     any comments?
>>
>> 在 2022/3/7 9:04, Min Hu (Connor) 写道:
>>> From: Huisong Li <lihuisong@huawei.com>
>>>
>>> This patch adds help messages for multi-process.
>>> --num-procs=N: set the total number of multi-process instances
>>> --proc-id=id:  set the id of the current process from multi-process
>>> instances(0 <= id < num-procs)
>>>
>>> Fixes: a550baf24af9 ("app/testpmd: support multi-process")
>>> Cc: stable@dpdk.org
>>>
>>> Signed-off-by: Huisong Li <lihuisong@huawei.com>
>>> Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
>>> ---
>>> v6:
>>> * fix comments.
>>> v5:
>>> * delete space
>>> v4:
>>> * update description for parameters.
>>> v3,v2:
>>> * adjust the position of parameters.
>>> ---
>>>   app/test-pmd/parameters.c | 3 +++
>>>   1 file changed, 3 insertions(+)
>>>
>>> diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c
>>> index daf6a31b2b..2834e9e180 100644
>>> --- a/app/test-pmd/parameters.c
>>> +++ b/app/test-pmd/parameters.c
>>> @@ -61,6 +61,9 @@ usage(char* progname)
>>>              "extended statistics to show. Used with --stats-period "
>>>              "specified or interactive commands that show Rx/Tx
>>> statistics "
>>>              "(i.e. 'show port stats').\n");
>>> +    printf("  --num-procs=N: set the total number of multi-process
>>> instances\n");
>>> +    printf("  --proc-id=id:  set the id of the current process from
>>> multi-process instances\n"
>>> +           "(0 <= id < num-procs).\n");
>>>       printf("  --nb-cores=N: set the number of forwarding cores "
>>>              "(1 <= N <= %d).\n", nb_lcores);
>>>       printf("  --nb-ports=N: set the number of forwarding ports "
>>>
>
> Hi Connor,
>
> output is as following [1], is "(0 <= id < num-procs)." part break into
> next line intentionally? This breaks the output.
>
> I assume the line is broken in source code to fit into line length, but
> it doesn't have to break the line in output, what do you think?
Thanks for pointing this, will fix.

Thanks,
Dongdong
>
>
> [1]
> ...
>   --num-procs=N: set the total number of multi-process instances
>   --proc-id=id:  set the id of the current process from multi-process ..
> (0 <= id < num-procs).
>   --nb-cores=N: set the number of forwarding cores (1 <= N <= 55).
> ...
> .
>
  

Patch

diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c
index daf6a31b2b..2834e9e180 100644
--- a/app/test-pmd/parameters.c
+++ b/app/test-pmd/parameters.c
@@ -61,6 +61,9 @@  usage(char* progname)
 	       "extended statistics to show. Used with --stats-period "
 	       "specified or interactive commands that show Rx/Tx statistics "
 	       "(i.e. 'show port stats').\n");
+	printf("  --num-procs=N: set the total number of multi-process instances\n");
+	printf("  --proc-id=id:  set the id of the current process from multi-process instances\n"
+	       "(0 <= id < num-procs).\n");
 	printf("  --nb-cores=N: set the number of forwarding cores "
 	       "(1 <= N <= %d).\n", nb_lcores);
 	printf("  --nb-ports=N: set the number of forwarding ports "