summaryrefslogtreecommitdiffstats
path: root/vnet
AgeCommit message (Collapse)AuthorFilesLines
2016-12-06Refactor binary APIs for IP, VPP-549Dave Barach6-2/+1699
Change-Id: Ieff6b22e2432600a231f74e75716e000d488a78f Signed-off-by: Dave Barach <dave@barachs.net>
2016-12-06Add binary API for reading interface/vrf assignment (VPP-439)Juraj Sloboda2-2/+77
Change-Id: I9b7cb90127e464fea520bb1b0a3e93c05a0e9e8e Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
2016-12-06span: add tx functionality and support for multiple mirror portsPavel Kotucek9-112/+435
Change-Id: Ib6dd290085e6f9a434499af8d19f346220dc8428 Signed-off-by: Damjan Marion <damarion@cisco.com> Signed-off-by: Pavel Kotucek <pkotucek@cisco.com>
2016-12-06vhost: Improve data pathPierre Pfister2-425/+663
This patch significantly improves vhost Tx and Rx performance (20% Mpps improvement in PVP scenario). Most significant change consists in the split of virtio ring parsing and memory copies. Other minor changes mostly consist in getting rid of unnecessary variables. Change-Id: Ia94e12ab9a6c114e3f7fef376a9343823d051209 Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-12-06Fix length in LCAF headerFilip Tehlar3-5/+5
Change-Id: I56461c5d892ce223d1160fb57313ca1c51db9a23 Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2016-12-06MAP: Split MAP API out of vpe.api.Ole Troan4-13/+497
Change-Id: I91a612a00ea85a9ddd4233d9aa19a6a4332d9701 Signed-off-by: Ole Troan <ot@cisco.com>
2016-12-06vhost: Code cleaningPierre Pfister2-334/+237
After a bug was found, I decided to review old vhost code. This change cleans some of it by: - Use unix file private data rather than hash table - Use vnet interface lookups rather than hash table - Keep track of unix_fd index rather than fd value - Change some indent - Store interfaces in a clib pool rather than hand-made pool The overall change reduces the number of lines as well as the amount of state kept in vhost structures. Change-Id: I6b9b670b9c7e1fb85981bcf2099f7140b0251fe0 Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-12-06api: missing support for dumping of neighbours (VPP-333)Pavel Kotucek5-55/+109
added API to dump ipv4/ipv6 neighboors (added by ip_neighbor_add_del). Change-Id: I33209a3d06beba64d68465c0892a9f4c65657334 Signed-off-by: Pavel Kotucek <pkotucek@cisco.com>
2016-12-06Implement LISP control plane messagesFilip Tehlar8-64/+1395
* Map-register * Map-notify * RLOC probing Change-Id: I7f6295376b21cd67805446dfd1c1033acead2d4b Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2016-12-05All mcast and All class E have /4 not /8 subnet masksNeale Ranns1-4/+4
Change-Id: I29e54014f43f0b0ce087380b2318fe623d879204 Signed-off-by: Neale Ranns <nranns@cisco.com>
2016-12-05Move interface APIs to vnet/vnet/{interface.api,interface_api.c}Dave Barach2-6/+771
Change-Id: If3f0f73ad1c1d54ac69122052c977eb83a9e16eb Signed-off-by: Dave Barach <dave@barachs.net>
2016-12-05api: set interface MTU API (VPP-442)Matus Fabian2-1/+71
Change-Id: I67178f2703febb8ad3eb011606cb8a86fab5ee94 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2016-12-05Fix crash in debug mode when call ethernet_register_l3_redirect()jerryian1-0/+4
Change-Id: I1c2a13663ec75460cd28ea8593aa8de3f27e47b9 Signed-off-by: jerryian <gu.jian1@zte.com.cn>
2016-12-05Locally generated packet go through lookup/load-balance - locally-generated ↵Neale Ranns12-266/+218
is an attribute of the packet and checked where necessary Add a flag to the vnet_buffer to indicate a packet is locally originated. Then in the rewrite nodes we can check this flag and not perform the TTL decrement. The switch path cost is expected to be fractions of a clock - the flags will be hot in the cache. The cehcks are necessary to due the requirements that VPP must be able to emit an IP packet with TTL=255. Change-Id: Ieb9cf06e34df54fd5c950293de8b665016295c51 Signed-off-by: Neale Ranns <nranns@cisco.com>
2016-12-05Fix vpp crash when generating jumbo packetsJuraj Sloboda2-2/+4
Change-Id: Ie1832f2b5df9f9f7ba2f0f406116e11014d3ac21 Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
2016-12-05Fix ICMP echo reply punt pathAlexander Popovsky2-21/+48
Add ICMP echo reply punt logic in ip[46]-icmp-echo-reply (ping) nodes. ICMP echo reply packets corresponding to the locally (VPP) originated ICMP echo requests are still dropped as before. Rest of the (unknown) ICMP echo reply packets are pushed to the “error-punt” node. Also added ICMP echo packet (id/seq) trace information Change-Id: I998198430dedc9b4d771b6aff2a97f18598663f9 Signed-off-by: Alexander Popovsky <apopovsk@cisco.com>
2016-12-04Fix crash whith bonded ethernet / DPDK 16.11Alexander Popovsky2-4/+8
In DPDK 16.11 bonded PMD is still using old naming ‘rte_bond_pmd’. See: dpdk-16.11/drivers/net/bonding/rte_eth_bond_api.c Fixed crash when VPP is generating a name for ‘unknown’ non-PCI interface Change-Id: I59e15f009e1a11949a19abf5234d09425a81c6ce Signed-off-by: Alexander Popovsky <apopovsk@cisco.com>
2016-12-02Coverity errors in MPLS codeNeale Ranns1-3/+12
Change-Id: I3f98e3c30e29198cb8701bfb846ce194b7250ed7 Signed-off-by: Neale Ranns <nranns@cisco.com>
2016-12-02remove CLIB_DEBUG conditional in fib_protocol_tNeale Ranns1-4/+0
Change-Id: I179941fe615935e63c6f4eacf1193c6bfab6631d Signed-off-by: Neale Ranns <nranns@cisco.com>
2016-12-02api: L2 XConnect API (VPP-438)Matus Fabian4-3/+185
Change-Id: I0a86184391723675488a5eb517c375f67940f5b5 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2016-12-02interfaces: make no_flatten variant of inteface_ouptut fn defaultDamjan Marion14-26/+17
Flatten variant was used only by old native drivers. Change-Id: If206c6c8b4f10843d60f908c3acb4e8db83ce03d Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-12-02snat: fix 1:1 NAT with multiple workersMatus Fabian2-0/+88
Assign worker when static mapping is created. Change-Id: I204e486e2ba5d1ef8e357759c35ba92a25a9a097 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2016-12-02Augment Vxlan to support NSH-ProxyHongjun Ni4-10/+85
PatchSet 9: add range check for decap_next_index PatchSet 6: delete runtime range check Change-Id: I415e156d05d09d2ff34f6578924f0b243058f464 Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2016-12-02feature: add interface-output arcDamjan Marion4-2/+126
Change-Id: Ifea275a312e0f2474cdc3a336ac51ea83e403c74 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-12-02Fix dpdk_validate_rte-mbuf for chained buffersPierre Pfister1-4/+5
Change I4ad40f398f7b5cf introduced a bug with chained buffers. This patch should fix it. Change-Id: Ia409d5eb90fcd6d7ff3c7da0836edfd2eb25998b Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-12-02feature: introduce feature arc end nodesDamjan Marion3-23/+35
This change allows us to keep feature path disabled until 1st feature is enabled. Enabling 1st feature also means that end feature node is enabled helping feature arc tenants to reach the end. Change-Id: Idbd64e681bd2b42e7c67612074649e5ae51f46e6 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-12-02MPLS infrastructure improvmentsNeale Ranns46-2596/+2694
- deprecate MPLSoEth and MPLSoGRE; replace with generic MPLS tunnel. - deprecates CLI 'mpls encap ..'; replace with addition of MPLS out label to a route/tunnel. - support for MPLS 'routes', e.g. MPLS x-connects. - deprecates CLI 'mpls decap ..'; replace with 'mpls route .. ' Change-Id: Ibda46544912f880d0200f22bf9ff9b52828fcc2f Signed-off-by: Neale Ranns <nranns@cisco.com>
2016-12-02API: Packaging of JSON files.Ole Troan1-4/+4
Change-Id: If041b6faf1a091d4758b514f0a8cd800ee0e6a89 Signed-off-by: Ole Troan <ot@cisco.com> Signed-off-by: Ole Troan <otroan@ot-vpp.cisco.com> Signed-off-by: Ole Troan <ot@cisco.com>
2016-12-01Add a 64-byte interface "tag" for vhost and tap interfacesDave Barach4-1/+107
This patch should dispose of spurious objections around interface tag requirements, currently in use as excuses not to support the vpp ML2 plugin. Add "u8 tag[64];" to the sw_interface_details message sent by vpp to control-plane clients. Add u8 tag[64] to the create_vhost_user_if and tap_connect APIs. Added debug CLI to set/show/clear the interface tag on any vnet sw interface. Added the sw_interface_tag_add_del API to set/clear tags on any vnet sw interface. There can be no expectation of "tag atomicity" with respect to physical hardware. Vpp discovers devices before establishing a control-plane connection. This patch upload verifies using the csit oper-161128 branch Change-Id: If8520119e7a586c5ccf0fdda82484ac205622855 Signed-off-by: Dave Barach <dave@barachs.net>
2016-12-01Add vxlan-bypass feature to IP4 forwarding pathJohn Lo5-6/+447
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>
2016-12-01ARP un-unmbered called when no interfaces are unnumberedNeale Ranns1-3/+11
Change-Id: I4bb60d6382f0955dbf4848225a9fd6985b906fbc Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
2016-12-01doc: doxygen documentation for vhost-user CLI Commmands (VPP-279)Billy McFall2-3/+246
Change-Id: I1f3cf7c786b0a86b56a1cd7d9650e446515f1504 Signed-off-by: Billy McFall <bmcfall@redhat.com>
2016-11-30Enabling AES-GCM-128 with 16B ICV supportRadu Nicolau6-90/+250
Change-Id: Ib57b6f6b71ba14952ad77477a4df3ab33b36fef4 Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
2016-11-30VXLAN multicast dst (remote) address supportEyal Bari15-152/+260
Added support for multicast vxlan tunnels which are used for bridge domain flooding instead of flooding the all unicast tunnels in the bridge domain. features added: * conditional flooding to some of the BD members - based on existance of multicast tunnel member * added local multicast adjacency - multicast packets are handled as the same as unicast - based on src (unicast) address * refactored some of vxlan tunnel creation code - to unify ip4/6 handling Change-Id: I60cca4124265a8dd4f6b2d6ea8701e52e7c1baa4 Signed-off-by: Eyal Bari <ebari@cisco.com>
2016-11-30Start spliting vpe.api into logically related piecesDave Barach6-1/+251
To reduce rebase / manual merge pain, among other things Change-Id: I3186df0479066916a2ca69c48759178b45ef035c Signed-off-by: Dave Barach <dave@barachs.net> Signed-off-by: Ole Troan <ot@cisco.com>
2016-11-29Improve test for unlocking LISP src FIBFlorin Coras1-9/+18
Check that either src FIB is empty or only default is present. In some situations we may overwrite/delete default. Change-Id: I4a90804cc30ea8e3aa24e36a07f8096b8d3e46bc Signed-off-by: Florin Coras <fcoras@cisco.com>
2016-11-29span: fix wrong next1 feature index in dual loopPavel Kotucek1-3/+3
Change-Id: I84e822f46fd1a0b83865073e797ef3ac03280e72 Signed-off-by: Pavel Kotucek <pkotucek@cisco.com>
2016-11-28snat: thread safe (VPP-443)Matus Fabian1-0/+34
All traffic corresponding to a specific SANT user is handled by a CPU core. in2out: Non-translated packets worker lookup by src address and VRF hash in snat-in2out-worker-handoff node. out2in: Translated packets worker lookup by dst address and port number hash in snat-out2in-worker-handoff node. Change-Id: Ia092a605689539469841d382588f3f486a29a769 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2016-11-28dpdk: add ipsec cryptodev supportSergio Gonzalez Monroy23-158/+2623
DPDK Cryptodev support and related IPsec ESP nodes using DPDK Cryptodev APIs. When DPDK Cryptodev support is enabled, the node graph is modified by adding and replacing some of the nodes. The following nodes are replaced: * esp-encrypt -> dpdk-esp-encrypt * esp-decrypt -> dpdk-esp-decrypt The following nodes are added: * dpdk-crypto-input : polling input node * dpdk-esp-encrypt-post : internal node * dpdk-esp-decrypt-post : internal node Change-Id: I6dca9a890abaf4fb2a4fffce3fd08ac013e4d701 Signed-off-by: Zhang, Roy Fan <roy.fan.zhang@intel.com> Signed-off-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
2016-11-27Unlock LISP source FIB if only default leftFlorin Coras1-2/+12
If when removing a source route the LISP source FIB contains only the default, remove the whole source FIB. Defaults are added when FIBs are created so no forwarding entry depends on them. Change-Id: I0dd5dc31d128d834ac3b92c962c4c68577aa7429 Signed-off-by: Florin Coras <fcoras@cisco.com>
2016-11-25l2: quad loop l2input, l2learn and l2output nodesDamjan Marion3-217/+265
Change-Id: I79f76bc9791d228e2ac2867a1b857bb03d9a5279 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-11-25l2: fix latency issue casued by unnecesary read of previous cachelineDamjan Marion1-1/+1
In majority of cases ethernet header sits at the beggining of cacheline. Reading (dst_mac - 2) into 64 bit register is much more expensive than doing simple bitwise shift, specially if previous cacheline is not prefetched. Change-Id: I35e53eae735098fb917a87c307e60a87e76e460f Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-11-24vhost-user: add retry sequence in tx codeDamjan Marion1-176/+187
This change improves NDR rate with vhost-user interface for ~ 40%. Change-Id: Ibec0b7cd5a9c3a20c45f71e0081b9cb2db493cb8 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-11-24vhost: CLI delete interface by namePierre Pfister1-4/+11
Adds interface name parsing to 'delete vhost' command so an interface name can be provided. Change-Id: Iacd50545a63548c13b9bb3c36a98e08f6ad74429 Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-11-24vhost: Delete thread configuration when interface deletedPierre Pfister1-0/+2
It does not make sense to keep interface configuration when a vhost interface is deleted. This fix makes sure thread configuration is removed. Change-Id: I4b3b75d98c15b544c32928f79ef52b7622a86b75 Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-11-24l2: remove unused l3 packet type discovery in l2 pathDamjan Marion2-78/+1
This costs significant amount of cycles and it is not used by anybody. Change-Id: I42a0306aa7c254292621bdaa09b736421662d540 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-11-23dpdk: remove rte_mbuf modifications at many places in the codeDamjan Marion15-239/+7
It is sole responsibility of dpdk tx function to fill/update rte_mbuf prior to sending packet do PMD. Change-Id: I8ca1dba3e7bef41034d36e3525831849f7ac4ac0 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-11-23l2: quad loop l2fwd nodeDamjan Marion2-28/+158
Change-Id: I8510575ee1d6b7c5ccf551766e77e40ce55e644c Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-11-23dpdk: input node next and error optimizationsDamjan Marion3-126/+117
Change-Id: Iee90ed725e824a3beed2660d21d74dae48c76eb0 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-11-23Fix coverity warnings, VPP-486Dave Barach1-1/+1
Change-Id: Id88805f77642187f304f8baef1f6b447728e4b5b Signed-off-by: Dave Barach <dave@barachs.net>