summaryrefslogtreecommitdiffstats
path: root/vnet
AgeCommit message (Collapse)AuthorFilesLines
2016-12-09Coding standards cleanup for vnet/vnet/ip, VPP-255Dave Barach52-7808/+9133
Change-Id: I12892fa571cc50e0541d6463a8b68e1b618edd9f Signed-off-by: Dave Barach <dave@barachs.net>
2016-12-09VPP-547: Fix for co-existence of HbH and RH header in Segment routing:Shwetha4-107/+457
1. sr-rewrite - SR insertion in v6 : SR RH is inserted immediately after v6 header but if hbh header is present as per RFC2460 it should immediately follow v6 header. This is fixed. 2. sr-local : v6 packet destined to a sr segment is received if hbh is present it is not handed over to sr-local for processing. fixed ip6-local handling to skip hbh as there is no register handler for hbh for now. 3. sr-replicate - update in dual of sr_rewrite to handle replicate, fixes in sr-replicate to handle presence of hbh header Change-Id: I034523a42d2fedf97134761f956ab534babb8b36 Signed-off-by: Shwetha <shwethab@cisco.com>
2016-12-09DPDK HQoS: enable vpp control plane thread connection to hqos threadJasvinder Singh2-4/+10
The vpp control plane thread generates different types of packets such as ARP, DHCP client, IPv6 RA, etc. which need to go through HQoS thread associated with the output interfaces. Therefore, this patch enables vpp main thread connection with the HQoS thread through dedicated SWQ. Change-Id: Idcb759546d4bcd9b40beedaec4f12b29baae3e40 Signed-off-by: Jasvinder Singh <jasvinder.singh@intel.com>
2016-12-09BFD: fix timing in the main loopKlement Sekera3-28/+59
Properly wakeup the main process loop only when necessary to avoid missed events. Improve BFD unit test reliability and speed. Add timestamps to logs and replace Queue with more efficient deque. Change-Id: I01255a02057d3146917b43b669ccdc74f31ef0c8 Signed-off-by: Klement Sekera <ksekera@cisco.com>
2016-12-09Add extra validation for VXLAN packets and tunnelsJohn Lo3-90/+244
- On VXLAN packet decap, validate its DIP against VXLAN tunnel. - Add extra logic to validate and handle creation of multicast VXLAN tunnels. Change-Id: I6abdddd7be4cd9f1bcfc88d9970ba681fdd72f7c Signed-off-by: John Lo <loj@cisco.com>
2016-12-09VPP-470: Introduce VxLAN-GPE as transport for iOAM.Vengada Govindan6-61/+137
See Jira ticket for more details - New plugins created to (a) Add VxLAN-GPE as transport (b) Provide export infra for VxLAN-GPE. Change-Id: Ife50c7434f53d17a4783062310f73d063d53494c Signed-off-by: Vengada Govindan <venggovi@cisco.com>
2016-12-08BFD: improve ip header handling, fix assertKlement Sekera4-13/+37
Instead of storing a pointer, store an offset within vlib_buffer marking the start of the ip header (similar to storing start of ethernet header). Handle negative timeout in the bfd process main loop. Change-Id: I05a1ff3ac41da5bdc3b2ac6f9e03b3241994688b Signed-off-by: Klement Sekera <ksekera@cisco.com>
2016-12-08Fix bug in code for setting dpdk interface descriptors (VPP-552)Juraj Sloboda1-1/+1
Change-Id: I6401b745eeb402ec980e86dc179b774d341c4764 Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
2016-12-08dpdk: don't drop packets if l4 checksum is flagged as badDamjan Marion2-10/+2
Sometimes NICs are flagging checksum 0 as bad, which is not always true. Change-Id: Ibb0147c94f436966e6afa472025bdf92c41f201e Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-12-08vhost: fix coverity warningPierre Pfister1-1/+1
Change-Id: Ifb9f8d2528142ad9f11a2b6d5ac10ff9639dd5d6 Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2016-12-07BFD: basic asynchronous session up/downKlement Sekera15-5/+2218
This is a work-in-progress basic BFD session handling. Only asynchronous mode is supported at the moment. Setting the session flags doesn't work. Change-Id: Idba27f721b5c35be5a66a6d202a63d23ff7ecf6f Signed-off-by: Klement Sekera <ksekera@cisco.com>
2016-12-07l2fib: add mac aging supportDamjan Marion6-18/+250
Change-Id: Ib617ae0f76320d596cc6c4b384da76c91d701a24 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-12-07Prevent re-entrant walks on an adjacency.Neale Ranns6-57/+140
The re-entrant walks were caused when the walk from an IP adj updated a fib_netry with an MPLS adj which in turn triggers a walk of the IP adj. Re-entrant walks do unnecessary work. also fixed a walk merge issue where the encountered walk should only be checked for equivalence woth the most recent alk, not any in the list. Otherwise an UO,DOWN,UP beceoms (2*)UP,DOWN Change-Id: Ib8b27f055dc6c1366d33740276d1c26cd314220a Signed-off-by: Neale Ranns <nranns@cisco.com>
2016-12-07LISP mapping timersFilip Tehlar3-1/+63
Change-Id: I4cd600189e936b07b628371df2f7fe2e2dc3e63d Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2016-12-07Refactor tap binary APIs, VPP-550Dave Barach4-2/+388
Change-Id: I1599b3659411b5f4451c364cc5ada63cfa8e0a6b Signed-off-by: Dave Barach <dave@barachs.net>
2016-12-07Make table chain deletion optional in classifier API (VPP-206)Juraj Sloboda2-9/+19
Change-Id: If30c0f6d5de34943bc399b3412c2d10847538c3c Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
2016-12-06SPAN API: Fix various errors making SPAN break make tests.Ole Troan3-4/+5
- s/l2/span in span_api.c in foreach macro - Not installing .json from Makefile.am Change-Id: I2469fe01138d62e044b8262cdb5a6e3b009bb43e Signed-off-by: Ole Troan <ot@cisco.com>
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>