aboutsummaryrefslogtreecommitdiffstats
path: root/vpp/vpp-api/custom_dump.c
diff options
context:
space:
mode:
authorJohn Lo <loj@cisco.com>2016-11-30 12:51:39 -0500
committerJohn Lo <loj@cisco.com>2016-12-01 19:34:12 +0000
commit37682e1237f83f0f84cdc4f9f92aa74d8fe3c139 (patch)
tree0ca723a11ab786245df26895365521b3f2fae11f /vpp/vpp-api/custom_dump.c
parent436d06b1c7d00e8c30ab055560724285a017290b (diff)
Add vxlan-bypass feature to IP4 forwarding path
Added vxlan-bypass feature which can be enabled on the underlay interface which receive VXLAN packets to accelerate VXLAN decap processing. The CLI to enable it is: set interface ip vxlan-bypass <interface> [del] With this feature enabled on an interface, there is an overhead for non-VXLAN packets at about 13 clocks per packet. The API is created to support vxlan-bypass for both VXLANoIPv4 and VXLANoIPv6. With this change, vxlan-bypass is only implemented for IPv4 forwarding path. Change-Id: Ica7239f642010b231eade7fd5009aa4b42c119d3 Signed-off-by: John Lo <loj@cisco.com>
Diffstat (limited to 'vpp/vpp-api/custom_dump.c')
-rw-r--r--vpp/vpp-api/custom_dump.c25
1 files changed, 23 insertions, 2 deletions
diff --git a/vpp/vpp-api/custom_dump.c b/vpp/vpp-api/custom_dump.c
index 2a9fd741e86..28d3341de8c 100644
--- a/vpp/vpp-api/custom_dump.c
+++ b/vpp/vpp-api/custom_dump.c
@@ -171,9 +171,29 @@ static void *vl_api_sw_interface_set_vpath_t_print
s = format (s, "sw_if_index %d ", ntohl (mp->sw_if_index));
if (mp->enable)
- s = format (s, "vPath enable ");
+ s = format (s, "enable ");
+ else
+ s = format (s, "disable ");
+
+ FINISH;
+}
+
+static void *vl_api_sw_interface_set_vxlan_bypass_t_print
+ (vl_api_sw_interface_set_vxlan_bypass_t * mp, void *handle)
+{
+ u8 *s;
+
+ s = format (0, "SCRIPT: sw_interface_set_vxlan_bypass ");
+
+ s = format (s, "sw_if_index %d ", ntohl (mp->sw_if_index));
+
+ if (mp->is_ipv6)
+ s = format (s, "ip6");
+
+ if (mp->enable)
+ s = format (s, "enable ");
else
- s = format (s, "vPath disable ");
+ s = format (s, "disable ");
FINISH;
}
@@ -2929,6 +2949,7 @@ _(SW_INTERFACE_ADD_DEL_ADDRESS, sw_interface_add_del_address) \
_(SW_INTERFACE_SET_TABLE, sw_interface_set_table) \
_(SW_INTERFACE_SET_MPLS_ENABLE, sw_interface_set_mpls_enable) \
_(SW_INTERFACE_SET_VPATH, sw_interface_set_vpath) \
+_(SW_INTERFACE_SET_VXLAN_BYPASS, sw_interface_set_vxlan_bypass) \
_(TAP_CONNECT, tap_connect) \
_(TAP_MODIFY, tap_modify) \
_(TAP_DELETE, tap_delete) \