summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorChristian E. Hopps <chopps@chopps.org>2019-09-27 14:05:09 -0400
committerChristian Hopps <chopps@labn.net>2020-09-06 08:50:38 -0400
commitdce44e4e2302042890dc8b579d4ff6f99509ae7a (patch)
treee82745be1aca02f8e16da9a9f121e865238f6e98 /src
parent4b2946a884c1ffbce022c8121c6889ff39f242e1 (diff)
marvell: add cli options to configure rxq and txq sizes
Add the ability to configure the pp2 rx and tx queue sizes in the CLI. Type: improvement Signed-off-by: Christian E. Hopps <chopps@chopps.org> Change-Id: I6a824f92e22fa47fec3d84525cc2d82524ddf639
Diffstat (limited to 'src')
-rw-r--r--src/plugins/marvell/pp2/cli.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/plugins/marvell/pp2/cli.c b/src/plugins/marvell/pp2/cli.c
index 345b237e45a..28ef35b2b24 100644
--- a/src/plugins/marvell/pp2/cli.c
+++ b/src/plugins/marvell/pp2/cli.c
@@ -31,6 +31,7 @@ mrvl_pp2_create_command_fn (vlib_main_t * vm, unformat_input_t * input,
{
unformat_input_t _line_input, *line_input = &_line_input;
mrvl_pp2_create_if_args_t args = { 0 };
+ uint val;
/* Get a line of input. */
if (!unformat_user (input, unformat_line_input, line_input))
@@ -40,6 +41,10 @@ mrvl_pp2_create_command_fn (vlib_main_t * vm, unformat_input_t * input,
{
if (unformat (line_input, "name %s", &args.name))
;
+ else if (unformat (line_input, "rx-queue-size %u", &val))
+ args.rx_q_sz = val;
+ else if (unformat (line_input, "tx-queue-size %u", &val))
+ args.tx_q_sz = val;
else
return clib_error_return (0, "unknown input `%U'",
format_unformat_error, input);
@@ -57,7 +62,7 @@ mrvl_pp2_create_command_fn (vlib_main_t * vm, unformat_input_t * input,
/* *INDENT-OFF* */
VLIB_CLI_COMMAND (mrvl_pp2_create_command, static) = {
.path = "create interface marvell pp2",
- .short_help = "create interface marvell pp2 [name <ifname>]",
+ .short_help = "create interface marvell pp2 [name <ifname>] [rx-queue-size slots] [tx-queue-size slots]",
.function = mrvl_pp2_create_command_fn,
};
/* *INDENT-ON* */