Skip to content

Commit

Permalink
app/testpmd: hide --bitrate-stats in help if disabled
Browse files Browse the repository at this point in the history
[ upstream commit e96491cb91fd048a79e848d713d65d45f0dde915 ]

Like other #ifdef options, bitrate-stats should not be printed
in help if not configured.

Also reordered latencystats help string to group it with bitrate-stats.

Fixes: e25e6c7 ("app/testpmd: add --bitrate-stats option")

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Ferruh Yigit <ferruh.yigit@amd.com>
  • Loading branch information
shemminger authored and kevintraynor committed Mar 5, 2024
1 parent e690cae commit 2597a7d
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions app/test-pmd/parameters.c
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,6 @@ usage(char* progname)
"the packet will be enqueued into the rx drop-queue. "
"If the drop-queue doesn't exist, the packet is dropped. "
"By default drop-queue=127.\n");
#ifdef RTE_LIB_LATENCYSTATS
printf(" --latencystats=N: enable latency and jitter statistics "
"monitoring on forwarding lcore id N.\n");
#endif
printf(" --disable-crc-strip: disable CRC stripping by hardware.\n");
printf(" --enable-scatter: enable scattered Rx.\n");
printf(" --enable-lro: enable large receive offload.\n");
Expand Down Expand Up @@ -176,8 +172,14 @@ usage(char* progname)
printf(" --disable-device-start: do not automatically start port\n");
printf(" --no-lsc-interrupt: disable link status change interrupt.\n");
printf(" --no-rmv-interrupt: disable device removal interrupt.\n");
#ifdef RTE_LIB_BITRATESTATS
printf(" --bitrate-stats=N: set the logical core N to perform "
"bit-rate calculation.\n");
#endif
#ifdef RTE_LIB_LATENCYSTATS
printf(" --latencystats=N: enable latency and jitter statistics "
"monitoring on forwarding lcore id N.\n");
#endif
printf(" --print-event <unknown|intr_lsc|queue_state|intr_reset|vf_mbox|macsec|intr_rmv|flow_aged|all>: "
"enable print of designated event or all of them.\n");
printf(" --mask-event <unknown|intr_lsc|queue_state|intr_reset|vf_mbox|macsec|intr_rmv|flow_aged|all>: "
Expand Down

0 comments on commit 2597a7d

Please sign in to comment.