Commit Graph

5111 Commits

Author SHA1 Message Date
Stephen Hemminger
5e48bbae26 dpdk: fix mlx5 build on SUSE
Current mlx5 requires libmnl, and SUSE has a bug which
installs the header file in incorrect location.

Workaround (from upstream) is to use pkg-config.

Change-Id: Iadfd2dc0df211876258c31da028af2e8934483b3
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2018-10-26 23:57:06 +00:00
Steven
557400d778 cj: cj dump crash
Thread 1 "vpp_main" received signal SIGSEGV, Segmentation fault.
0x00007ffff670da53 in cj_dump_one_record (r=0x7ffff50f0fec)
    at /home/sluong/vpp3/vpp/src/vlib/unix/cj.c:138
138		   (long long unsigned int) r->data[1]);

(gdb) p *cjm
$1 = {tail = 58645908, records = 0x7fffb64646ec, num_records = 512,
  enable = 1, vlib_main = 0x7ffff6953240 <vlib_global_main>}
(gdb) p /x cjm
$2 = 0x7ffff6953880
(gdb) p /x *cjm
$3 = {tail = 0x37edd94, records = 0x7fffb64646ec, num_records = 0x200,
  enable = 0x1, vlib_main = 0x7ffff6953240}
(gdb)

cjm->tail is a 64 bit counter, not the total number of records. Dumping from
0 to cjm->tail can be a very large number of records which go beyond the
limit. I believe we meant to dump from 0 to index. index has been set  by
this statement
  index = (cjm->tail + 1) & (cjm->num_records - 1);

Change-Id: Ie1a8ba757598de9757accc1488577c15aa49726b
Signed-off-by: Steven <sluong@cisco.com>
2018-10-26 19:55:12 +00:00
Mohsin Kazmi
f208b02624 vxlan-gbp: On demand udp ports registration
Change-Id: I3a47c71ad3e35df47d11fed6db95019a45f3015f
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2018-10-26 19:51:43 +00:00
Andrew Yourtchenko
40421a17c7 acl-plugin: fix the node multiarch function selection
Thanks to Damjan for rewriting my previous patch into
not-to-be-deprecated soon form!

Change-Id: I595a13c44ed07d4c6d60e2aef0f0bd807a76cbba
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2018-10-26 19:50:45 +00:00
Matthew Smith
2a1da5218a dpdk: ENA PMD patch for failure on port restart
Patch to fix a bug in the ENA PMD on starting a port that
had previously been started and stopped. There was a
failure to allocate descriptors on start because they had
been allocated during the initial start and not released
when the port was stopped.

Issue reported/tracked at
https://github.com/amzn/amzn-drivers/issues/86

Change-Id: Id9c8d598929f0561788b985011fe5dea8f4a21a5
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2018-10-26 19:48:54 +00:00
Paul Vinciguerra
8e7ba4ad12 Trivial: Fix Makefile typo
Change-Id: Ia108b0359cb2dc4ba2e773117ee7134274a98056
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2018-10-26 19:35:08 +00:00
Damjan Marion
539e637cce extras/scripts: update vfctl script
Change-Id: I49cb5863237e4f9d2ac94879577d5d011e3bfe97
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-26 19:30:18 +00:00
Scott Keeler
6c892301e2 docs: add useful debug CLI Review Updates
Change-Id: I4ebd977672090f2a7fc08bb139832df39614564a
Signed-off-by: Scott Keeler <skeeler@cisco.com>
2018-10-26 15:35:15 +00:00
Steven
eb11190532 vmxnet3: enable promiscuous mode
Some L2 traffic requires promiscuous mode enable on the interface

Change-Id: Icbb2792aaf0d9d1c51373e46ae5049ff0d986863
Signed-off-by: Steven <sluong@cisco.com>
2018-10-26 10:45:04 +00:00
Florin Coras
332287ef5d Revert "Keep RPC traffic off the shared-memory API queue"
This reverts commit 71615399e1.

There seems to be an issue with ARPs when running with multiple workers. 

Change-Id: Iaa68081512362945a9caf24dcb8d70fc7c5b75df
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-25 19:34:03 +00:00
Damjan Marion
c04e2b06ed pmalloc: don't lock 4K pages if we don't have access to pagemap
Without pagemap access only way to do DMA to physmem is by
using IOMMU. In such case VFIO will take care for preventing
paging of such memory so we don't need to lock here.

Change-Id: Ica9c20659fba3ea3c96202eb5f7d29c43b313fa9
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-25 15:21:59 +00:00
Andrew Yourtchenko
dc8d35036f acl-plugin: "show acl-plugin acl" ACE# is truncated to 4 digits in output
I was expecting "%4d" format string to exhibit the same behavior as
the one in C standard library, but rather than specifying _minimal_
width and expanding as necessary, it actually truncates the output.

Changing that to "%9d" should take care of pushing this surprising
difference in behavior into the domain of impossible.

Change-Id: Ia687137ca765bf9c1575af998ff11314010e81ad
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2018-10-25 15:17:09 +00:00
Paul Vinciguerra
82b2776e31 vnet/tcp/tcp.c: address a corner case.
Avoid possible null pointer dereference

Change-Id: If8023edb43aaf037234f4a7b5f191cb23b09c74d
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2018-10-25 15:11:00 +00:00
Paul Vinciguerra
0c0383df88 Trivial: Cleanup missing va_ends.
Change-Id: Ie7827b6a31968a355687d27325c0f30cab1bc890
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2018-10-25 14:30:49 +00:00
Damjan Marion
2bfb9e15d8 Run 'make test' verify job on ubuntu 18.04 instead of 16.04
Change-Id: If570bb8cc19b2eab5877a20c963e27e410ee7560
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-25 13:35:26 +00:00
Neale Ranns
8f68b3e63d Use correct name to register ABF plugin with ACLs
Change-Id: Ic69a68665dcff4e4d48803b634aa2cf234c3944b
Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-10-25 12:29:10 +00:00
Florin Coras
de9a849a18 session/tcp: improve cli
Change-Id: I91c9d040fc9b9b63f7109eeaac334c47fb1226cf
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-25 11:35:54 +00:00
Marco Varlese
fe7740e661 Address "is already installed" Jenkins issue
Change-Id: Iad2ddf63116a6f477c6106a3e045fe36f34bc062
Signed-off-by: Marco Varlese <marco.varlese@suse.com>
2018-10-25 11:35:16 +00:00
Damjan Marion
567e61d09c pmalloc: support for 4K pages
Change-Id: Iecceffe06a92660976ebb58cd3cbec4be8931db0
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-25 10:52:42 +00:00
Gregory Thiemonge
3935fc8527 ACL: Fix next_table_index classifiers consistancy
Fixed consistancy between the first classifier match and the
next_table_index classifier matches:
- CLASSIFY_ACTION_SET_METADATA was applied only for the first
  classifier, but it was not applied for the other classifiers
- Actions should be performed only for input ACLs
- Payload should point at the IP header for output ACLs

Change-Id: Ifbd7791756320ae3198520c41902f5e99e3d40b4
Signed-off-by: Gregory Thiemonge <gregory.thiemonge@enea.com>
2018-10-25 10:28:52 +00:00
Paul Vinciguerra
1bc560463b ipsec_gre.c: Remove redundant assignments.
Change-Id: I010528055b9d0597b087882146496eacc13b7daa
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2018-10-25 10:14:36 +00:00
Florin Coras
d67f112063 tcp/session: add tx pacer
Adds tx pacing infrastructure for transport protocols that want to use
it. Particularly useful for connections with non-negligible rtt and
constrained network throughput as it avoids large tx bursts that lead to
local interface tx or network drops.

By default the pacer is disabled. To enabled it for tcp, add tx-pacing
to tcp's startup conf. We are still slightly inefficient in the handling
of incoming packets in established state so the pacer slightly affect
maximum throughput in low lacency scenarios.

Change-Id: Id445b2ffcd64cce015f75b773f7d722faa0f7ca9
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-25 10:13:18 +00:00
Kingwel Xie
2fab01ee0f buffer trace is broken in ipsec-output. copy it from node->flags to frame->frame_flags
Change-Id: I56b573b5da04a27766bcbcafbd5438555424f2e7
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
2018-10-25 10:10:14 +00:00
Marco Varlese
8797168fe2 SCTP: DATA chunk padding fix and hardening
According to the RFC 4096 (section 3.3.1) the DATA chunk needs to be
padded to a boundary of 4 bytes with zeros. This patch addresses that
requirement.
At the same time, this patch takes care of adding some hardening for
corner-cases where the transmitted tag could be wrong.

Change-Id: I3b653926e9933d0d3d46bc5f37eaceefd932e874
Signed-off-by: Marco Varlese <marco.varlese@suse.com>
2018-10-25 01:05:09 +00:00
Dave Barach
5f1fd46573 Add x86_64 perfmon tables
The license issue is resolved, so we can package the .json
files. Added to the vpp-dev package in .tar.xz form, which saves a lot
of space.

Updated the perfmon error log entry: tell folks where to find the
compressed tarball, and how to extract it.

Change-Id: I3ed351fbf154cc3ba22d5f9c666acff77a2a14cf
Signed-off-by: Dave Barach <dave@barachs.net>
2018-10-25 01:04:44 +00:00
Damjan Marion
380c1676e2 dpdk: fix hugepage pre-alloc
Change-Id: I88577615bfd3cddca834a7b881979ab32bfd5574
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-24 22:41:06 +00:00
Andrew Yourtchenko
a6386d4ec4 acl-plugin: introduce a format function for l4 session key
Abstracting out the internal format function
for L4 session key type makes the other
acl plugin format/print functions more maintainable.

Change-Id: Ica1302263a42981555462b5338d18d9a9f9c8342
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2018-10-24 21:21:19 +02:00
Paul Vinciguerra
a0f0c96404 Trivial: vpp/vnet/main.c fix resource leak
Change-Id: Ia6cadec8117d2cc35c9329910bb403bcd1b048ce
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2018-10-24 10:39:15 -07:00
Mohsin Kazmi
3d3b9550db vlib: Fix pci io bar read/write fd leak
Few devices provide PCI bar region(s) through I/O.
If any such device driver opens I/O "fd" to read and write,
needs to close it, when pci device is going to be deleted.

Change-Id: Iba104e56f76c6bf9ccd27bf2223bad39b1301763
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2018-10-24 15:21:57 +00:00
Dave Barach
71615399e1 Keep RPC traffic off the shared-memory API queue
Change-Id: Ib5c346641463768cf33eaf8cb5fab5b63171398d
Signed-off-by: Dave Barach <dave@barachs.net>
2018-10-24 15:21:31 +00:00
Scott Keeler
70f28fc4b8 docs: add useful debug CLI
Change-Id: I5ef9ecd741f1623ae1b7a23fa0a4fa6db7e243a3
Signed-off-by: Scott Keeler <skeeler@cisco.com>
2018-10-24 15:21:20 +00:00
Dave Barach
8a6928938c DOC ONLY: fix doc bugs
multiarch support: change autotools -> cmake
getting a patch reviewed: improve patch conflict resolution section

Change-Id: I2f07e1d3f21dd8cefb4d4bb3b451965d9314211a
Signed-off-by: Dave Barach <dave@barachs.net>
2018-10-24 15:20:41 +00:00
Damjan Marion
9787f5f90a vppinfra: autodetect default hugepage size
Change-Id: I5ff713ad0b254c74c5622e3b9425cca365b5ee97
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-24 13:26:41 +00:00
Stephen Hemminger
a35fc46c0a dpdk: disable unused rxtx callbacks in ethdev
Save a few cycles on every rx and tx burst call by not compiling
in support for DPDK Rx and Tx callbacks. This feature is optional
and unused by current VPP code.

Change-Id: I1916bc8822e2bd405c1ac3909e85467a01023862
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2018-10-24 12:13:18 +00:00
Neale Ranns
7d645f771c L2-fwd trace show the lookup result
Change-Id: I09cf6ee7b4874d71f293f8f1a426d3a5e9651749
Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-10-24 11:16:45 +00:00
Neale Ranns
a1179589be L2-input/output: use feature enum type in flag update function
Change-Id: I1f58f441c65fbca101bee2e864bfa6ae2306b475
Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-10-24 02:31:51 -07:00
Dave Barach
5a951bfe32 VPP-1474: fix coverity warning
Change-Id: I20f2fb14e00f3e7e96774959a4bf1a159ab9030f
Signed-off-by: Dave Barach <dave@barachs.net>
2018-10-23 23:41:01 +00:00
Damjan Marion
8e8d3c8c11 physmem coverity issues
Change-Id: Ie9ff9b751190632dfc4576e5cbb1987a4142af5e
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-23 22:14:04 +00:00
Paul Vinciguerra
6cfd414e4c perfmon.c: Register additional cpuids.
Added/tested additional cpuids from our testbed.

Change-Id: Ifd3ea9e8e8231a8901966903bf5eceb635b82482
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2018-10-23 21:49:58 +00:00
Dave Barach
8a9566ebe0 dns, dhcp: on-demand udp port registration
Change-Id: I8bf411adc6c5f4caa349d161174b544d2de3ad1d
Signed-off-by: Dave Barach <dave@barachs.net>
2018-10-23 21:48:22 +00:00
Florin Coras
bf4d5ce584 tcp: fast retransmit improvements
Patch is too large to be ported to 18.10 just days before release.

- handle fast retransmits outside of established node and limit the
retransmit burst size to avoid tx losses and worsening congestion.
- in the absance of a tx pacer, use slow start after fast retransmit
exists
- add fast retransmit heuristic that re-retries sending the first
segment if everything else fails
- fine tuning

Change-Id: I84a2ab8fbba8b97f1d2b26584dc11a1e2c33c8d2
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-23 19:35:51 +00:00
Damjan Marion
f87eb9b372 vlib: alloc buffers on local numa, not on numa 1
Change-Id: Icb8172238f735fd0825e474e16a006f1435e175c
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-23 19:35:39 +00:00
Florin Coras
81c0585ba9 lisp: register cp port only if enabled
Change-Id: I7030951215f0cf7d00c037892ac92d9c304cb5a1
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-23 18:59:33 +00:00
Mohsin Kazmi
95276ca5ca vlib: Add support for pci io read/write
Change-Id: I9d96e7782a12c2e19eacbb75edb1fb450cf33bed
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2018-10-23 18:51:43 +00:00
Damjan Marion
901d16cced vlib: reduce default buffer memory size to be below RLIMIT_MEMLOCK
Change-Id: If36be24fa08e21c7718a1dced506a7f254dfb5cf
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-23 19:50:23 +02:00
Damjan Marion
68b4da67de Numa-aware, growable physical memory allocator (pmalloc)
Change-Id: Ic4c46bc733afae8bf0d8146623ed15633928de30
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-23 14:21:10 +00:00
Kingwel Xie
fc3b8b8ad0 pg: udp length & checsum issue
if udp length is specified, then use this length to calculate udp checksum
otherwise, use length from vlib_buffer

Change-Id: I5304a60d5d429993d0524b864b65ec503775412d
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
2018-10-23 13:20:48 +00:00
Stephen Hemminger
0a554c773b dpdk: support 18.11 changes to CRC flags
In DPDK 18.11 the device flags for keeping/stripping CRC flags has
changed. The old strip flag is gone, and replaced by a CRC keep
flag.

Change-Id: Iaa162854862a2a0855b418ee8029383fc116d3a2
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2018-10-23 13:08:16 +00:00
Matthew Smith
1dfdb289a1 dpdk: add esp6 decrypt nodes, func declarations
The function dpdk_ipsec_process() attempts to initialize some
globals that store node indexes after looking up the node
dpdk-esp6-decrypt. No such node was declared, so a segv
occurs after dereferencing the result of the lookup.

Add a node function that invokes dpdk_esp_decrypt_inline()
with is_ip6 set to 1. Add a declaration of node dpdk-esp6-decrypt
that uses the node function.

Change-Id: I31ce23a458c2d4181bf40cbc2118c4ef3b9baf97
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2018-10-23 13:07:58 +00:00
Dave Barach
b7b929931a c11 safe string handling support
Change-Id: Ied34720ca5a6e6e717eea4e86003e854031b6eab
Signed-off-by: Dave Barach <dave@barachs.net>
2018-10-23 13:06:46 +00:00