summaryrefslogtreecommitdiffstats
path: root/vnet/vnet/vxlan/encap.c
AgeCommit message (Collapse)AuthorFilesLines
2016-12-28Reorganize source tree to use single autotools instanceDamjan Marion1-553/+0
Change-Id: I7b51f88292e057c6443b12224486f2d0c9f8ae23 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-11-10VXLAN tunnel encap forwarding optimization with FIB 2.0John Lo1-254/+243
Optimize VXLAN encap node so that vxlan4-encap node is used for IP4 and vxlan6-encap node is used for IP6 underlay. Also stack the VXLAN encap nodes to the appropriate FIB IP4 or IP6 load-balance node instead of ip4/ip6-lookup node to save IP lookup operation. For VXLAN decap node, check VXLAN header FLAGS field for each packet and remove the code to support decap-next for IP4 or IP6. These decap- next values were intended for experimentation purposes and not needed any more since VXLAN-GPE tunnel is supported. The decap-next field is still kept in API for backward compatibility and its value has no effect. Decap next for both vxlan4-decap and vxlan6-decap nodes is always l2-input node. Change-Id: I8ac95774946549ec403ab691f999df0c006b460f Signed-off-by: John Lo <loj@cisco.com>
2016-06-07VPP-110: vxlan encap node should never touch a deleted tunnelJohn Lo1-28/+1
Remove usage of dummy encap string for output from BD to a tunnel which has been deleted. Instead, use a node l2-outpt-del-tunnel so that if there are stale entries in the L2FIB for any deleted tunnel sw_if_index, l2-output will send packets using this entry to the l2-output-tunnel-del node which just setup the proper drop reason before sending packets to the error-drop node to drop the packet. Change-Id: I590982ee25e924ab74e2855c55c58baf29a9fad4 Signed-off-by: John Lo <loj@cisco.com>
2016-05-19Add support for multiple microarchitectures in single binaryDamjan Marion1-0/+3
* compiler -march= parameter is changed from native to corei7 so code is always genereted with instructions which are available on the Nehalem microarchitecture (up to SSE4.2) * compiler -mtune= parameter is added so code is optimized for corei7-avx which equals to Sandy Bridge microarchitecture * set of macros is added which allows run-time detection of available cpu instructions (e.g. clib_cpu_supports_avx()) * set of macros is added which allows us to clone graph node funcitons where cloned function is optmized for different microarchitecture Those macros are using following attributes: __attribute__((flatten)) __attribute__((target("arch=core-avx2))) I.e. If applied to foo_node_fn() macro will generate cloned functions foo_node_fn_avx2() and foo_node_fn_avx512() (future) It will also generate function void * foo_node_fn_multiarch_select() which detects available instruction set and returns pointer to the best matching function clone. Change-Id: I2dce0ac92a5ede95fcb56f47f3d1f3c4c040bac0 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-04-28VXLAN over IPv6.Chris Luke1-73/+209
Refactors the VXLAN node to work with both IPv4 and IPv6 transports. There is a discussion thread for this change at https://lists.fd.io/pipermail/vpp-dev/2016-March/000279.html Note that this changes the binary configuration API to support both address families; each address uses the same memory for either address type and a flag to indicate which is in use. This also includes changes to the Java API to support both address families. The CLI and VAT syntax remains unchanged; the code detects whether an IPv4 or an IPv6 address was given. Configuration examples: IPv4 CLI: create vxlan tunnel src 192.168.1.1 dst 192.168.1.2 vni 10 encap-vrf-id 0 decap-next l2 IPv6 CLI: create vxlan tunnel src 2620:124:9000::1 dst 2620:124:9000::2 vni 16 encap-vrf-id 0 decap-next l2 IPv4 VAT: vxlan_add_del_tunnel src 192.168.1.1 dst 192.168.1.2 vni 10 encap-vrf-id 0 decap-next l2 IPv6 VAT: vxlan_add_del_tunnel src 2620:124:9000::1 dst 2620:124:9000::2 vni 16 encap-vrf-id 0 decap-next l2 TODO: The encap path is not as optimal as it could be. Change-Id: I87be8bf0501e0c9cd7e401be4542bb599f1b6e47 Signed-off-by: Chris Luke <chrisy@flirble.org>
2016-04-08Add Rx and Tx statistics within nsh-vxlan-gpe nodeHongjun Ni1-1/+1
PatchSet2: Modify the code according to review comments. PatchSet3: modify sw_if_index1 in encap.c. Change-Id: Ic4d3ee19a0ba0fa10568e570a79a3cb85cfbc9ab Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2016-01-19Enhance and fix packet trace for IP forwarding as follows:John Lo1-0/+3
1. Add fib index to IP6 forwarding trace. 2. Display adjacency index in IP forwarding trace. 3. Fix adjacency display for L3 to L2 forwarding such as BVI and VXLAN tunnel decap. 4. Setup VXLAN tunnel fib index properly for packet trace. Change-Id: I261fea5abf51e2550d24cdcee53887be2fdd08de Signed-off-by: John Lo <loj@cisco.com>
2015-12-08Initial commit of vpp code.v1.0.0Ed Warnicke1-0/+449
Change-Id: Ib246f1fbfce93274020ee93ce461e3d8bd8b9f17 Signed-off-by: Ed Warnicke <eaw@cisco.com>