aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/ip
diff options
context:
space:
mode:
authorOle Trøan <otroan@employees.org>2018-02-15 21:56:06 +0000
committerOle Trøan <otroan@employees.org>2018-02-15 22:12:03 +0000
commit438f63094465d35c278155484fe85153e438873e (patch)
tree06e0ec613a6b2393ef2021f12ea7545fade9fec2 /src/vnet/ip
parent909c26bda66313b86168dda31003f76410c1d746 (diff)
Revert "Allow interface types to override glean adjacency behaivour"
This reverts commit 8b30e471df4d42214619e1d6c50cc8298426b45f. Change-Id: I99edb236eb0a7f8ba3fba333c3481a710ebcb59c Signed-off-by: Ole Troan <ot@cisco.com>
Diffstat (limited to 'src/vnet/ip')
-rw-r--r--src/vnet/ip/ip6_neighbor.c6
-rw-r--r--src/vnet/ip/lookup.c41
2 files changed, 42 insertions, 5 deletions
diff --git a/src/vnet/ip/ip6_neighbor.c b/src/vnet/ip/ip6_neighbor.c
index 61d29835062..82b402ff263 100644
--- a/src/vnet/ip/ip6_neighbor.c
+++ b/src/vnet/ip/ip6_neighbor.c
@@ -566,10 +566,8 @@ ip6_ethernet_update_adjacency (vnet_main_t * vnm, u32 sw_if_index, u32 ai)
switch (adj->lookup_next_index)
{
- case IP_LOOKUP_NEXT_GLEAN:
- adj_glean_update_rewrite (ai);
- break;
case IP_LOOKUP_NEXT_ARP:
+ case IP_LOOKUP_NEXT_GLEAN:
if (NULL != nbr)
{
adj_nbr_walk_nh6 (sw_if_index, &nbr->key.ip6_address,
@@ -4270,8 +4268,6 @@ ethernet_ndp_change_mac (u32 sw_if_index)
}
}));
/* *INDENT-ON* */
-
- adj_glean_update_rewrite (adj_glean_get (FIB_PROTOCOL_IP6, sw_if_index));
}
void
diff --git a/src/vnet/ip/lookup.c b/src/vnet/ip/lookup.c
index 256000a2242..f2880bf8cd9 100644
--- a/src/vnet/ip/lookup.c
+++ b/src/vnet/ip/lookup.c
@@ -255,6 +255,47 @@ format_ip_flow_hash_config (u8 * s, va_list * args)
}
u8 *
+format_ip_lookup_next (u8 * s, va_list * args)
+{
+ /* int promotion of ip_lookup_next_t */
+ ip_lookup_next_t n = va_arg (*args, int);
+ char *t = 0;
+
+ switch (n)
+ {
+ default:
+ s = format (s, "unknown %d", n);
+ return s;
+
+ case IP_LOOKUP_NEXT_DROP:
+ t = "drop";
+ break;
+ case IP_LOOKUP_NEXT_PUNT:
+ t = "punt";
+ break;
+ case IP_LOOKUP_NEXT_ARP:
+ t = "arp";
+ break;
+ case IP_LOOKUP_NEXT_MIDCHAIN:
+ t = "midchain";
+ break;
+ case IP_LOOKUP_NEXT_GLEAN:
+ t = "glean";
+ break;
+ case IP_LOOKUP_NEXT_MCAST:
+ t = "mcast";
+ break;
+ case IP_LOOKUP_NEXT_REWRITE:
+ break;
+ }
+
+ if (t)
+ vec_add (s, t, strlen (t));
+
+ return s;
+}
+
+u8 *
format_ip_adjacency_packet_data (u8 * s, va_list * args)
{
u32 adj_index = va_arg (*args, u32);