summaryrefslogtreecommitdiff
path: root/examples/ip_pipeline/cli.c
diff options
context:
space:
mode:
authorJasvinder Singh <jasvinder.singh@intel.com>2018-03-29 19:32:01 +0100
committerCristian Dumitrescu <cristian.dumitrescu@intel.com>2018-04-05 19:00:20 +0200
commitd0d306c7f2a1fba9816eb148da74ade7ff0a3c46 (patch)
tree2d5faa464978dadcbbd6f064b276064418c3b56c /examples/ip_pipeline/cli.c
parent2b82ef4861c06b67285d14578d5970c88c0387dd (diff)
downloaddpdk-d0d306c7f2a1fba9816eb148da74ade7ff0a3c46.zip
dpdk-d0d306c7f2a1fba9816eb148da74ade7ff0a3c46.tar.gz
dpdk-d0d306c7f2a1fba9816eb148da74ade7ff0a3c46.tar.xz
examples/ip_pipeline: add TTL stats command
Add command to read the ttl stats. Signed-off-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com> Signed-off-by: Jasvinder Singh <jasvinder.singh@intel.com>
Diffstat (limited to 'examples/ip_pipeline/cli.c')
-rw-r--r--examples/ip_pipeline/cli.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/examples/ip_pipeline/cli.c b/examples/ip_pipeline/cli.c
index 9e42695..5a32632 100644
--- a/examples/ip_pipeline/cli.c
+++ b/examples/ip_pipeline/cli.c
@@ -4178,6 +4178,18 @@ cmd_pipeline_table_dscp(char **tokens,
}
/**
+ * pipeline <pipeline_name> table <table_id> rule read ttl [clear]
+ */
+static void
+cmd_pipeline_table_rule_ttl_read(char **tokens,
+ uint32_t n_tokens __rte_unused,
+ char *out,
+ size_t out_size)
+{
+ snprintf(out, out_size, MSG_CMD_UNIMPLEM, tokens[0]);
+}
+
+/**
* thread <thread_id> pipeline <pipeline_name> enable
*/
static void
@@ -4524,6 +4536,16 @@ cli_process(char *in, char *out, size_t out_size)
out, out_size);
return;
}
+
+ if ((n_tokens >= 7) &&
+ (strcmp(tokens[2], "table") == 0) &&
+ (strcmp(tokens[4], "rule") == 0) &&
+ (strcmp(tokens[5], "read") == 0) &&
+ (strcmp(tokens[6], "ttl") == 0)) {
+ cmd_pipeline_table_rule_ttl_read(tokens, n_tokens,
+ out, out_size);
+ return;
+ }
}
if (strcmp(tokens[0], "thread") == 0) {