summaryrefslogtreecommitdiffstats
path: root/src/vnet
AgeCommit message (Collapse)AuthorFilesLines
2017-05-26MPLS lookup DPO does not pop the label (nor does it handle replicate)Neale Ranns4-84/+145
Change-Id: I7de6b96631d1645d0eadd38525860d84d78e316d Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-26ARP/ND use path_remove to complement path_addNeale Ranns4-16/+67
don't add duplicate extensions. Change-Id: Icf72d6e1b004d0dda532bec2b51f6b74544925bb Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-26LISP: do not try to delete paths when fwd entry is negativeFilip Tehlar1-4/+7
Change-Id: I50a0cbc7d8ecc94ad494df4720bb4199673e9793 Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2017-05-25MPLS hash function improvementsNeale Ranns3-7/+64
Change-Id: I28e98f445c01493562b6196a4f5b532a51f178af Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-25MPLS interface output feature not explicitly enabledNeale Ranns1-2/+0
Change-Id: I54cb5113ec8e37f5da321041d7925393cae31aa5 Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-25af_packet: fix coverity errorRay Kinsella1-2/+19
Fix coverity error associated with fd. Change-Id: I0648aebaf356308bc03cc7217922479bfc4e22f7 Signed-off-by: Ray Kinsella <ray.kinsella@intel.com>
2017-05-24Add p2p flag to IPsec tunnel interface hw classMatthew Smith1-0/+1
Change-Id: I4ac05ee5974f5e7ab3685d325446a6e77048a948 Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2017-05-24MPLS tunnels; path-list lock leak and debug CLI imrpovementsNeale Ranns1-7/+16
Change-Id: Ifb51b49d4dac1f07027b12398314a52b5cce343e Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-24IPv6 Performance bugsNeale Ranns6-70/+62
- 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>
2017-05-24Missing VLIB node for IPv6 disposition from mcast MPLS LSPNeale Ranns1-1/+23
Change-Id: Ibc0e1910a4926fdfbf74571efb5fd5810bfa09da Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-24MPLS trace fixesNeale Ranns2-1/+7
Change-Id: I141a14e1098e562bdb3c3ac576754f4f19dbcb04 Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-24Leak locks and tables in the ClassifierNeale Ranns4-7/+51
Change-Id: Iae04c57bba87ab3665388eadd0805f75171636a5 Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-24ipfix: make IPFIX work for all skip_n_vectors values (VPP-204)Juraj Sloboda1-22/+23
Change-Id: Id2ffcd048b93d8efc8f825744cf2aeef5c436d53 Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
2017-05-23Labelled attached paths via an MPLS tunnelNeale Ranns5-40/+69
Change-Id: Ic86617c9c3217122043656ce2ea70bb106df5b2d Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-23ARP/ND entries for the same address on different interfaces (VPP-848)Neale Ranns18-735/+1194
there are, intentionally, no validation checks in the ARP/ND code to prevent an ARP/ND entry from being installed for an address that is not local to the interface's sub-net. This is ok, since the adjacency/FIB code is designed to handle this case using the 'refinement' criteria - i.e. only installing a FIB entry for the address if the address 'refines' (i.e. is more specific than) the interface's sub-net. However, the refinement criteria currently operates on the FIB entry's prefix (which is a /32, so on the address) and not on the next-hop in the path. So, enter multiple ARP entries for the same address on different links, and this refinement criteria uses only the last added path, and so will remove the FIB entry should the ARP entries be added in the 'wrong' order. This fix updates the refinement criteria to work on each path of the FIB entry. The entry is installed if one of the paths refines the covers and only paths refining the cover contribute forwarding. Per-path refinement checks are stored in path-extensions. The patch is rather large as path-extension, which were previously used only for out-going MPLS labels, have been generalized. Change-Id: I00be359148cb948c32c52109e832a70537a7920a Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-22vhost: migrate to use device infra for worker thread assignment, rx-mode.Steven4-484/+336
and add adaptive mode support to receive queue - Migrate vhost to use device infra which does the interface/queue to worker thread assignment. - Retire vhost thread CLI and corresponding code which assigns interface/queue to worker thread. set interface placement should be used instead to customize the interface/queue to worker thread assignment. - Retire vhost interrupt/polling option when creating vhost-user interface. Instead, set interface rx-mode should be used. - Add code in vnet_device_input_unassign_thread to change the node state to interrupt if the last polling interface has left the worker thread for the device of the corresponding interface/queue. - Add adaptive mode support. The node state is set to interrupt initially. When the scheduler detects a burst of traffic, it switches the input node to polling. Then we inform the device that we don't need interrupt notification. When the traffic subsides, the scheduler switches the input node back to interrupt. Then we immediately tell the driver that we want interrupt notification again. - Remove some duplicate code in vlib/main.c Change-Id: Id19bb1b9e50e6521c6464f470f5825c26924d3a8 Signed-off-by: Steven <sluong@cisco.com>
2017-05-22LISP-GPE: add dump call for VNIs in useFilip Tehlar5-1/+74
Change-Id: I394af7c1ac9fd0177ff5d298e4008245df54b436 Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2017-05-20API: Cleaning up message naming that does not follow the conventionsOle Troan2-52/+41
is_address_reachable - Disabled so deleted cli_request - Renamed to cli vnet_summary_stats_reply - Renamed to vnet_get_summary_stats_reply bridge_domain_sw_if_details - Deleted, incorporated in main message l2_fib_table_entry - Renamed to l2_fib_table_details Change-Id: I93b7e8769a3ba7b4989b3c270270f575f386464f Signed-off-by: Ole Troan <ot@cisco.com> Signed-off-by: Marek Gradzki <mgradzki@cisco.com> Signed-off-by: Ole Troan <ot@cisco.com>
2017-05-20Improve session debuggingFlorin Coras7-85/+171
Also improves builtin client code. Change-Id: I8bca1aa632028f95c373726efb0abf2ee0eff414 Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-20vhost: buffers leak and interface disable upon vring descriptor out of mmapSteven1-16/+9
When processing a vring descriptor which is outside of mmap, we disable the interface and spit a message to shut/no shut the interface. This is not practical as application using vhost cannot constantly checking the logs and do the recovery. The proposed fix is to log an error, like other errors that we encounter. The other bug is buffer leak in the function rewind. At the end of the while loop when b_current != b_head, we still have to give back 1 more buffer or add 1 to rx_buffers_len. Change-Id: I68c0b24f070e644cd8878f42272a7b518f14393f Signed-off-by: Steven <sluong@cisco.com>
2017-05-20VPP-849: improve vnet classifier memory allocator performanceDave Barach2-274/+450
Port the linear-scan bucket fix from bihash_template.c. Change-Id: Id8b2d1fe402401f098270ce6121c2f44f2f24c49 Signed-off-by: Dave Barach <dave@barachs.net>
2017-05-20af_packet: set mac address supportRay Kinsella1-1/+47
Added support to the interfaces mac address. Resolved an fd leak when the interface is a bridge. Change-Id: I6608c51b11a50bd0ae4aabe0dc5788c4301b5a1e Signed-off-by: Ray Kinsella <ray.kinsella@intel.com>
2017-05-19mfib CLI bugs (VPP-852)Neale Ranns3-8/+16
Change-Id: I1b71010e20742eee02693d672e24c85897e37759 Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-19Enforce Bridge Domain ID range to match 24-bit VNI rangeJohn Lo5-9/+29
Enforce bridge domain ID range to allow a maximum value of 16M which matches the range of 24-bit VNI used for virtual overlay network ID. Fix "show bridge-domain" output to allow full 16M BD ID range to be displayed using 8-digit spaces. Change-Id: I80d9c76ea7c001bcccd3c19df1f3e55d2970f01c Signed-off-by: John Lo <loj@cisco.com>
2017-05-18Remove nop code from session_manager_add_first_segment().Dave Wallace1-2/+0
Change-Id: I071e8d78ed9312ebf8e572bf01ece447ce1a1835 Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2017-05-18Improve sack bytes accounting and testingFlorin Coras5-37/+140
Change-Id: Iabeda0d0615b0f6fe20dd00611cb4c594d90b7eb Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-17VPP-719: Accept ARP replies from VRRP hw addrMatthew Smith1-7/+27
Check whether an ARP src hw addr starts with 00:00:5e:00:01 before rejecting due to a mismatch between ARP src hw addr and ethernet frame src addr. Change-Id: Ia3ecd5d6dba34876aca8d90bc622a0a1397e48fb Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2017-05-17vhost: bad packet assembled from descriptor chainingSteven1-1/+2
When the descriptor is chained via multiple parts, vhost is supposed to reassemble the different parts to form a packet prior to passing the packet to the next input node. However, bad packet was seen, having bad ethertype, source, and destination mac addresses. The problem was due to the destination pointer not being incremented as each chain is processed. THe result was the first chain is copied to the beginning of the buffer, the next chain is copied, then the last chain is also copied to the beginning of the buffer. As a result, the ethertype, source and destination mac, etc, are being overwritten by the very last chain of the descriptor. Change-Id: I78f9a91de68c85574047912576dcc311d7597e21 Signed-off-by: Steven <sluong@cisco.com>
2017-05-17Use counters on ipsec tunnel interfacesMatthew Smith3-6/+107
Increment byte & packet counters when packets are sent or received on an IPsec tunnel interface. Set counters to zero when the interface is deleted. Change-Id: Ie9584aa82778875dd4d0c931005f7720b4d5c76d Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2017-05-17Add ethernet type to support NSH over ethernetHongjun Ni1-1/+1
Change-Id: I876599d6183fab989949e8ccad5c0a3ef81991be Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2017-05-17VPP-846: tcp perf / scale / hardeningDave Barach6-48/+106
Fix builtin server event queue handling Change-Id: I21b49c37188746cadb2fd9423291c5dc1335798c Signed-off-by: Dave Barach <dbarach@cisco.com>
2017-05-17ARP learning fixes (VPP-843)Neale Ranns3-82/+68
learn ARP peers if, 1) it's a reply to a local address, 2) we are sending a response to a request. send proxy ARP responses only in the interface the request was sent. Change-Id: I22b949c65122824233076492b7dd537daca07bc2 Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-16Fixes to tcp active opens and receptionDave Barach2-1/+10
- Properly initialize connection index - Add new session to main hash table - Drop packets that are completely in the past with respect to the rcv wnd (e.g., retransmits due to premature timer pops) Change-Id: Ic0873018ff0a4c59e0913863dc7f0c0f822d5c34 Signed-off-by: Dave Barach <dbarach@cisco.com> Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-16ping command does not work when there is woker thread (VPP-844)flyingeagle231-0/+1
Change-Id: Ic896b237a7d141243e1b7d6d4fbb2a120f44363e Signed-off-by: flyingeagle23 <wang.hui56@zte.com.cn>
2017-05-15Add sw_if_index of tunnel interface to API reply for ipsec_tunnel_if_add_delMatthew Smith4-15/+36
Change-Id: If5158f6fa7344dee94548c93dace779430e0647f Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2017-05-15Add GTP-U plugin. VPP-694Hongjun Ni2-0/+4
Basic GTP-U feature Change-Id: I31226f890a92c5303ac06e112ed7820cae52d9bd Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2017-05-15af_packet: support changing the mtu sizeRay Kinsella1-1/+23
Added support to the af_packet device to change the MTU size. Change-Id: I9c9e1e17323721f3efccf70a10b753e12eef94d5 Signed-off-by: Ray Kinsella <ray.kinsella@intel.com>
2017-05-15Fix builtin tcp clientDave Barach4-38/+78
Change-Id: I83a1b02a73fd159f14cca04fed3993f571475a00 Signed-off-by: Dave Barach <dbarach@cisco.com>
2017-05-15L2BD/API:fix bd dump to ignore unknown bd_idEyal Bari1-19/+20
Change-Id: I417dfeba902ca8c3a080773942d4d2ce4335a9c1 Signed-off-by: Eyal Bari <ebari@cisco.com>
2017-05-15Fix vnet_interface_counters API definitionAloys Augustin1-7/+28
The api specification had u8 as data type, which caused the python binding to fail. Fixes VPP-642 Change-Id: I9ba97959740d44c8f4a12db9356d0d1bcd709a73 Signed-off-by: Aloys Augustin <aloys.augustin@polytechnique.org> Signed-off-by: Ole Troan <ot@cisco.com>
2017-05-15Fix FIB recursion loops via cover (VPP-842)Neale Ranns3-38/+81
Change-Id: Ia91c3e8cb27b9e4c1cccefc0a4857dd9995450ab Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-11Validate ip6 interface fib tables early onFlorin Coras1-0/+5
This should avoid random crashes due to reception of packets (multicast in particular) before ip6 addresses are configured on the interfaces. Change-Id: Ibcf1a5a2ae2fa75f8b57da1b2f09f32c081210d7 Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-11Handle RST of TCP connections in SYN-RCVD state, VPP-822Florin Coras1-8/+23
Change-Id: Ieb0c1e690d6ae082cfedb276252a31fab480e561 Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-10vnet: introduce error state for sw interfacesDamjan Marion3-1/+13
Interfaces with error state are not allowed to go admin up Change-Id: I09fc09a5b28130aead219dccbc2e0f30ea7414cf Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-10completelly deprecate os_get_cpu_number, replace new occurencesDamjan Marion2-5/+5
Change-Id: I82c663bc0866c6c68ba354104b0bb059387f4b9d Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-10Multi-thread enablement for the debug cli http serverDave Barach3-2/+35
Change-Id: Iec1f739fe24c722d0db6c10cc81b5e8333067ea1 Signed-off-by: Dave Barach <dbarach@cisco.com>
2017-05-10Add crc32c inline function, allows compilation on 32-bit systemsDamjan Marion1-1/+1
32-bit code still can use crc32c instructions, but it operates on 32 registers Change-Id: I9bb6b0b59635d6ea6a753584676ebcf59c8f6584 Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-10device: Add callback for set interface rx-modeSteven3-27/+72
- When the interface rx-mode is changed via CLI, the corresponding device may want to know about it and to reset the driver. This patch is to add the callback. - In the function vnet_hw_interface_set_rx_mode, it appears it is missing a line hw->rx_mode_by_queue[queue_id] = mode because the function is checking if the new mode is the same as hw->rx_mode_by_queue which is initialized to POLLING. So if the function is called to change the mode to interrupt, it just returns without doing anything. This is the check that I am talking about in the same function. if (hw->rx_mode_by_queue[queue_id] == mode) return 0; Change-Id: Iaca2651c43e0ae3fda6fd8dc128e247b0851cc65 Signed-off-by: Steven <sluong@cisco.com>
2017-05-10Improve TCP option handling, VPP-757Florin Coras3-15/+54
Change-Id: Ica634536387d1196366ec96c52770287fcab0768 Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-10Builtin debug cli http serverDave Barach3-5/+646
Visit http://<vpp-ip>/show/interface or similar. Change-Id: I076b4661cf19d1b94bb01efdadb5849446be915e Signed-off-by: Dave Barach <dave@barachs.net>