summaryrefslogtreecommitdiffstats
path: root/common/VIL/pipeline_loadb/pipeline_loadb.c
diff options
context:
space:
mode:
authorDeepak S <deepak.s@linux.intel.com>2017-07-20 11:22:20 +0000
committerGerrit Code Review <gerrit@opnfv.org>2017-07-20 11:22:20 +0000
commit51759157a499326cfe69ec0eecb00b1c5879bf50 (patch)
treebb2197d5344b52ec015323a4fd5e36d6ec6937e4 /common/VIL/pipeline_loadb/pipeline_loadb.c
parentcfe2f779d4365dba03659b64668cb301fae53c95 (diff)
parent0e51437be874b6831e95639f4c1ad6b0133c2a28 (diff)
Merge "[l2l3 stack] implements new arp state machine & arp buffering"
Diffstat (limited to 'common/VIL/pipeline_loadb/pipeline_loadb.c')
-rw-r--r--common/VIL/pipeline_loadb/pipeline_loadb.c28
1 files changed, 17 insertions, 11 deletions
diff --git a/common/VIL/pipeline_loadb/pipeline_loadb.c b/common/VIL/pipeline_loadb/pipeline_loadb.c
index fdcc17ae..cd49ca5b 100644
--- a/common/VIL/pipeline_loadb/pipeline_loadb.c
+++ b/common/VIL/pipeline_loadb/pipeline_loadb.c
@@ -318,7 +318,7 @@ cmd_arp_req_parsed(void *parsed_result,
key.filler2 = 0;
key.filler3 = 0;
- struct arp_entry_data *arp_data = retrieve_arp_entry(key);
+ struct arp_entry_data *arp_data = retrieve_arp_entry(key, STATIC_ARP);
if (arp_data) {
if (ARPICMP_DEBUG)
@@ -399,22 +399,24 @@ struct cmd_arp_ls_result {
cmdline_fixed_string_t p_string;
uint32_t p;
cmdline_fixed_string_t arp_string;
+ uint32_t ip_type;
};
static void
-cmd_arp_ls_parsed(__rte_unused void *parsed_result,
+cmd_arp_ls_parsed(void *parsed_result,
__rte_unused struct cmdline *cl, __rte_unused void *data)
{
- printf("\nARP table ...\n");
- printf("-------------\n");
- print_arp_table();
+ struct cmd_arp_ls_result *params = parsed_result;
- printf
- ("............................................................\n");
-
- printf("\nND IPv6 table:\n");
- printf("--------------\n");
- print_nd_table();
+ if (!params->ip_type) {
+ printf("\nARP table ...\n");
+ printf("-------------\n");
+ print_arp_table();
+ } else {
+ printf("\nND IPv6 table:\n");
+ printf("--------------\n");
+ print_nd_table();
+ }
}
static cmdline_parse_token_string_t cmd_arp_ls_p_string =
@@ -428,6 +430,9 @@ static cmdline_parse_token_string_t cmd_arp_ls_arp_string =
TOKEN_STRING_INITIALIZER(struct cmd_arp_ls_result, arp_string,
"arpls");
+static cmdline_parse_token_num_t cmd_arp_ls_ip_type =
+TOKEN_NUM_INITIALIZER(struct cmd_arp_ls_result, ip_type, UINT32);
+
static cmdline_parse_inst_t cmd_arp_ls = {
.f = cmd_arp_ls_parsed,
.data = NULL,
@@ -436,6 +441,7 @@ static cmdline_parse_inst_t cmd_arp_ls = {
(void *)&cmd_arp_ls_p_string,
(void *)&cmd_arp_ls_p,
(void *)&cmd_arp_ls_arp_string,
+ (void *)&cmd_arp_ls_ip_type,
NULL,
},
};