aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/ip/ip6_forward.c
diff options
context:
space:
mode:
authorNeale Ranns <nranns@cisco.com>2017-05-22 09:20:20 -0400
committerDamjan Marion <dmarion.lists@gmail.com>2017-05-24 19:48:43 +0000
commit630198f04916deb35c5b7774823ae1a5dd168a6c (patch)
tree093682c49f0a3a7e114d52abb77a5f85bdb7a7b0 /src/vnet/ip/ip6_forward.c
parent31426c6fee43caf18602a2a7e2ce32c3dda75a29 (diff)
IPv6 Performance bugs
- inline the FIB lookup function; this requires access to the bihash, so for files that use more than one type this casues problems. those files that include ip6_fib.h unnecessarily have been updated - better use of the feature arcs. ip6-lookup and interface-output are now sentinels (end-node-index in the cm speak) rather than enabled features. Change-Id: I9d1375fee63f7dbb2d327da6124d8e60b63367ec Signed-off-by: Neale Ranns <nranns@cisco.com>
Diffstat (limited to 'src/vnet/ip/ip6_forward.c')
-rw-r--r--src/vnet/ip/ip6_forward.c32
1 files changed, 14 insertions, 18 deletions
diff --git a/src/vnet/ip/ip6_forward.c b/src/vnet/ip/ip6_forward.c
index 25714e48d5a..28c84d1c2ee 100644
--- a/src/vnet/ip/ip6_forward.c
+++ b/src/vnet/ip/ip6_forward.c
@@ -444,12 +444,11 @@ ip6_sw_interface_enable_disable (u32 sw_if_index, u32 is_enable)
return;
}
- vnet_feature_enable_disable ("ip6-unicast", "ip6-lookup", sw_if_index,
- is_enable, 0, 0);
-
- vnet_feature_enable_disable ("ip6-multicast", "ip6-mfib-forward-lookup",
- sw_if_index, is_enable, 0, 0);
+ vnet_feature_enable_disable ("ip6-unicast", "ip6-drop", sw_if_index,
+ !is_enable, 0, 0);
+ vnet_feature_enable_disable ("ip6-multicast", "ip6-drop", sw_if_index,
+ !is_enable, 0, 0);
}
/* get first interface address */
@@ -624,17 +623,17 @@ VNET_FEATURE_INIT (ip6_vxlan_bypass, static) =
.runs_before = VNET_FEATURES ("ip6-lookup"),
};
-VNET_FEATURE_INIT (ip6_lookup, static) =
+VNET_FEATURE_INIT (ip6_drop, static) =
{
.arc_name = "ip6-unicast",
- .node_name = "ip6-lookup",
- .runs_before = VNET_FEATURES ("ip6-drop"),
+ .node_name = "ip6-drop",
+ .runs_before = VNET_FEATURES ("ip6-lookup"),
};
-VNET_FEATURE_INIT (ip6_drop, static) =
+VNET_FEATURE_INIT (ip6_lookup, static) =
{
.arc_name = "ip6-unicast",
- .node_name = "ip6-drop",
+ .node_name = "ip6-lookup",
.runs_before = 0, /*last feature*/
};
@@ -652,15 +651,15 @@ VNET_FEATURE_INIT (ip6_vpath_mc, static) = {
.runs_before = VNET_FEATURES ("ip6-mfib-forward-lookup"),
};
-VNET_FEATURE_INIT (ip6_mc_lookup, static) = {
+VNET_FEATURE_INIT (ip6_drop_mc, static) = {
.arc_name = "ip6-multicast",
- .node_name = "ip6-mfib-forward-lookup",
- .runs_before = VNET_FEATURES ("ip6-drop"),
+ .node_name = "ip6-drop",
+ .runs_before = VNET_FEATURES ("ip6-mfib-forward-lookup"),
};
-VNET_FEATURE_INIT (ip6_drop_mc, static) = {
+VNET_FEATURE_INIT (ip6_mc_lookup, static) = {
.arc_name = "ip6-multicast",
- .node_name = "ip6-drop",
+ .node_name = "ip6-mfib-forward-lookup",
.runs_before = 0, /* last feature */
};
@@ -699,9 +698,6 @@ ip6_sw_interface_add_del (vnet_main_t * vnm, u32 sw_if_index, u32 is_add)
vnet_feature_enable_disable ("ip6-multicast", "ip6-drop", sw_if_index,
is_add, 0, 0);
- vnet_feature_enable_disable ("ip6-output", "interface-output", sw_if_index,
- is_add, 0, 0);
-
return /* no error */ 0;
}