10698 Commits

Author SHA1 Message Date
Florin Coras
b39fac168b hsa: proxy listener support addition of fifo segments
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I59218f784140ef5ecb8468af6aebfe25fd7703a4
(cherry picked from commit b740fdc8ff7f58637524e999d5fe01b8b010810d)
2021-05-29 16:51:45 +00:00
Dave Wallace
f5d9237c56 svm: fix inadequate atomic load for chunk mgr
- Fixes intermittent LDP cut thru iperf3 test
  failure on AARCH64

Type: fix

Change-Id: Id21a078d642e03d974bacacd1f4d0faa42fb6652
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
(cherry picked from commit 5c520919e838bcb645ddd879641d54c620740989)
2021-05-28 16:08:32 +00:00
Florin Coras
88b2269a45 vppinfra: explicit blocking mode for sock connects
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I3a33230de13fef613dc9523cf24a9968d200c2e5
(cherry picked from commit 57e0af924b8b48cf39b1020bf11f10e3c227f22c)
2021-05-26 18:48:32 +00:00
Andrew Yourtchenko
e82d59f381 misc: Initial changes for stable/2106 branch
Change-Id: Ia484268463cc504902402cde2243f0cfdb02d101
Type: docs
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
v21.06-rc1
2021-05-26 13:05:36 +00:00
Neale Ranns
1372178e0e fib: During the mfib lookup set the unicast FIB index in the packet so that a uRPF check on a for-us packet is done in the correct VRF
Type: fix

Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: Iafa6efea0d96962aa9136dccefc148a961f74476
2021-05-26 10:22:02 +00:00
Ray Kinsella
457271d71c pg: revert exec file fixes
This reverts commit fd4fd0d1853ae7384e7a64c4cad17a3469720b95.

Type: fix
Change-Id: I6ef84f646372270ded486eacee81817067e49106
Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
2021-05-26 08:23:09 +00:00
Klement Sekera
2de7e96e6f nat: add thread index assertions
Add extra assertions to debug build.

Type: improvement
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: Ib20130365e8f9dbb556fcbb4321dd184c7eff603
2021-05-26 07:38:01 +00:00
Florin Coras
5fe9457fa2 api: socket client connect set to blocking
Binary api client must otherwise check the returned error and if it was
EAGAIN/EINPROGRESS poll for connect completion.

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I89845b1a59b9fa2ab0968029435ceb203bfa8f6c
2021-05-26 07:37:06 +00:00
Ray Kinsella
3fb978e261 vlib: revert exec cmd handle scripts with blank lines
This reverts commit 269e1569e1f7798bf7d7f539daf505b2f1997a08.

Type: fix

Change-Id: I40bd71ae3b5e9dc8345fb2460aae437de8a9a5ba
Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
2021-05-26 07:03:26 +00:00
Ray Kinsella
dbf90d499b perfmon: revert raw column support
Revert raw column from the perfmon plugin.

Type: refactor

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: If127f57ee2022cc1c0ea5177f1655a792f195f1d
2021-05-26 06:45:40 +00:00
Damjan Marion
a2d6d352c6 tests: move vapi C/C++ test files into src/
Type: improvement
Change-Id: Iaad004661db1e9076e6c27227878f1612fa7289f
Signed-off-by: Damjan Marion <damarion@cisco.com>
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2021-05-26 06:32:43 +00:00
Florin Coras
6621abf49a srtp: basic implementation based on libsrtp2
Type: feature

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ic5e99938a5f130e83de6d590d2f89252d055bceb
2021-05-25 21:18:54 +00:00
Neale Ranns
6bb77dec70 linux-cp: A V2 variant of pair create API that returns the host
interface created

Type: improvement

Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: I31a83cd50513078895078bae3ae11372d351ddcd
2021-05-25 14:34:57 +00:00
Matthew Smith
01930f568a nat: report correct EI per-user session limit
Type: fix

When enabling the endpoint independent NAT44 plugin, user_sessions
determines the maximum number of translations that can be active for
a single inside address. If 0 is passed in, a default value is used
but 0 is still stored in the field that is used to populate reply
messages to nat44_ei_show_running_config,

At the time of enabling the plugin, if user_sessions is 0, update the
field which is used by nat44_ei_show_running_config to contain the
default per-user limit which gets used by the EI nodes.

Change-Id: I6b060d85bcd42d91db879b95a8b07c6844bcd2a5
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2021-05-25 13:12:01 +00:00
Mohammed Hawari
06274811e4 dpdk: disable DPDK iAVF interrupt support
Change-Id: I665d9d11fcdd9af33e38972a74e51ce3085f3e55
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Type: fix
2021-05-25 10:06:44 +00:00
Damjan Marion
3755ac1196 interface: show if tx queue is shared
Type: improvement
Change-Id: Idb48f835730db6c652c4b0e6ef310c7f36599a72
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-05-25 09:38:04 +00:00
Dave Wallace
623b8b0164 tests: skip hoststack iperf3 cut thru test on aarch64
- Temporary fix for intermittent unrelated test failure
  on AARCH64 CI verify/merge jobs.  To be reverted
  when the root cause is fixed.

Type: test

Change-Id: Ie28e5a7b9fa9a20469ac7e91766f4c226e44d244
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2021-05-24 11:36:37 -04:00
Florin Coras
af073546e1 tls: prealloc chunks for dtls dgram enq
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ib25598f72f6539c07de1acee1e6049ecd28f35cc
2021-05-22 16:45:00 +00:00
Florin Coras
0f27339eaa session: improve main thread connects rpc
Avoid grabbing the worker barrier if there's no work to be done.

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ice3de5df41cd1752aba3419ad2e2dd82f30e9bfb
2021-05-21 23:39:46 +00:00
Ole Troan
d640ae52f6 stats: catch stat segment overrun in retry loop
Raise IOError so that the blocking code retries not only on
optimistic locking failures but also on data segment illegal reads.

Type: fix
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: I6bb250e239486b60192004271c1690e790513318
2021-05-21 21:07:38 +00:00
Benoît Ganne
1a06e53341 af_xdp: use desc offset on rx
Instead of pre-programming the data offset on rx, use offset passed in
the descriptor. This is more robust and future-proof.

Type: fix

Change-Id: I2bd910d92b8b03d17be5be85a24108be711dc7b9
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-05-21 21:07:02 +00:00
Benoît Ganne
73b71225b1 af_xdp: refill rx rings when interface goes up
If interrupt mode is configured through startup.conf exec script, the
input function will not be polled and the rx ring will never be filled.
Always refill the ring when interface goes up so it is ready to receive
packets.

Type: fix

Change-Id: I4cf22c8ae00638679f2e8650303a6fe916c1319b
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-05-21 21:07:02 +00:00
Klement Sekera
efd4d70210 bfd: use vnet crypto
Type: improvement

Change-Id: I873a99c1258a97ed5ed195b9756e8302f865e7f0
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2021-05-21 21:06:34 +00:00
Benoît Ganne
a42c41be4e af_xdp: workaround kernel race between poll() and sendmsg()
Prior to Linux 5.6 there is a race condition between poll() and
sendmsg() in the kernel. This patch protects the syscalls with a lock
to prevent it, unless the NO_SYSCALL_LOCK flag is set at create time.
See
https://lore.kernel.org/bpf/BYAPR11MB365382C5DB1E5FCC53242609C1549@BYAPR11MB3653.namprd11.prod.outlook.com/

Type: fix

Change-Id: Ie7d4f5cb41f697b11a09b6046e54d190430d76df
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-05-21 19:50:14 +00:00
Ole Troan
92a8d761c4 nat: add maximum configured sessions to stat segment
Add /nat44-ed/max-cfg-sessions gauge.
Reflects the configured value for configured sessions (per thread).

Type: improvement
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: I618c8aa0daab0981399cfe9273d191fa1990ef60
Signed-off-by: Ole Troan <ot@cisco.com>
2021-05-21 16:49:30 +00:00
Dave Wallace
84b543d8b1 doxygen: fix doxygen tags
- Missing tags mess up doxygen TOC heirarchy

Type: docs

Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: I012d55c0ae90aecc665b56903f4212ddc0643943
2021-05-21 15:33:04 +00:00
Dave Wallace
4ee17d859e tests: add role to VCLAppWorker
- Improve readability of log output with respect
  to worker role

Type: test

Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: I1a5787421b31483fa1a2558951568417dfc111d9
2021-05-21 15:21:01 +00:00
Matthew Smith
e2353a7f6c linux-cp: Add delegate to adjacencies
Type: improvement

When an adjacency is created, add the linux-cp delegate on the new
adjacency so we can later deal with modifications & deletions in our
cache of adjacency data.

Add a pool of hash keys and associate the pool index for a particular
key with the adj_delegate_t. If the rewrite on an adjacency is changed,
this will allow us to delete the old hash table entry and it will not
become orphaned.

Signed-off-by: Matthew Smith <mgsmith@netgate.com>
Change-Id: I072b960c02cf377d66f7d18b8c0e9e05824a0ca3
2021-05-21 11:51:38 +00:00
Florin Coras
debb352df9 quic: add extended vcl test
Only works with release binaries.

Type: test

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Iede88713e1dbc4d1c6ae62651ff9150f88953f4d
2021-05-21 06:57:03 +00:00
Florin Coras
0131477153 quic: fix timer update
Use ctx timer wheel not current thread since connects are done on main
but the ctx is allocated on first worker.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ibed371bed12970d0d1ae4572f36df0bb1fb70b0f
2021-05-21 06:57:03 +00:00
Florin Coras
22a55e6790 quic: init crypto context on streams
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I901980f1f8ae8eb51c3972537ccac80f620868d0
2021-05-21 06:57:03 +00:00
Florin Coras
0978ae8670 quic: make sure aead crypto context matches quicly
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I8003198c15cd511750dc7eaae025025c733c059c
2021-05-21 06:56:52 +00:00
Neale Ranns
5606c82c72 ipsec: Default the IPSec interface MTU to 9000
Type: fix

The same value is used for other tunnel types.

Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: I6593001918993d65f127cc9f716c95e932239842
2021-05-21 06:24:50 +00:00
Tianyu Li
40c11e604c memif: fix gcc-10 build error on arm platform
In function ‘memcpy’,
 inlined from ‘memif_device_input_zc_inline’
 at src/plugins/memif/node.c:850:7,
 string_fortified.h:34:10: error:
   writing 16 bytes into a region of size 0 [-Werror=stringop-overflow=]
 34 |   return __builtin___memcpy_chk (__dest, __src, __len, __bos0 (__dest));
    |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/plugins/memif/node.c: In function ‘memif_input_node_fn_neoversen1’:
src/plugins/memif/memif.h:175:16: note:
  at offset 0 to object ‘desc’ with size 0 declared here
  175 |   memif_desc_t desc[0];
      |                ^~~~

Using C99 way empty brackets for flexible array members

Type: fix
Signed-off-by: Tianyu Li <tianyu.li@arm.com>
Change-Id: I7a6ad89f95e1b5e3f9aac36546a2559dbda9bd6c
2021-05-21 06:23:20 +00:00
Tianyu Li
94c7236ec3 memif: fix input node buffer prefetch
Prefetch should be the next group of buffers instead of current buffers

Type: fix
Signed-off-by: Tianyu Li <tianyu.li@arm.com>
Change-Id: If13967e27f74c10856ae48892420d7ade6f0c92c
2021-05-20 20:31:21 +00:00
Dave Wallace
ae8d332699 tests: don't buffer worker stdin/stdout
- Required to get VCLAppWorker stdin / stdout data
  into log.txt when a test fails.

Type: test

Change-Id: I4db467986940f701750aec6d842a4d9aee22b4e6
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2021-05-20 18:50:42 +00:00
Dave Wallace
ab755a3cf0 bash: add set-quicly-ws function
- Set up vpp workspace to build/test/debug with
  quicly source code downloaded from github.

Type: improvement

Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: I63a3f3b19f3b753fca1d57f8b22dad7c4e968846
2021-05-20 17:32:15 +00:00
Damjan Marion
e6f89fba6c build: add .clang-tidy
Initial version

Type: make
Change-Id: Id26827e7812f794da3f17b91f78d2550e4800083
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-05-20 15:25:58 +02:00
Matthew Smith
a0455ffdbe gre: Walk IPv6 adjacencies during restack
Type: fix

If a GRE tunnel is created and the peer is not resolved yet and an
IPv6 route is added which points to the tunnel, packets matching the
route will be dropped. When the tunnel peer is resolved, adjacencies
on the tunnel interface should be restacked and packets matching the
route can be encapsulated and sent..

There is a loop that is intended to do this for both IPv4 and IPv6.
The call to walk adjacencies is invoked in a "return" statement though.
So the loop is exited and the function returns before IPv6 adjacencies
are walked.

Remove the return so the loop finishes.

Change-Id: Ia4f695681713020209ea490ae4142857cea49c41
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2021-05-20 10:16:21 +00:00
Florin Coras
733a26e787 hsa: test server incremental stats
Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ie8ec924ebaf006f1df84a1013050114831144a79
2021-05-20 10:04:14 +00:00
Florin Coras
e3c6a54995 tls svm: prealloc tcp fifo chunks before ssl write
Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I7c47b55ec6f0c83f2d13e0e737d0559a32f7c837
2021-05-20 10:03:57 +00:00
Florin Coras
05bc33c15d session: fix transport half-open cleanup call
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I47d241a8f2f9e9d0761d14dcddd3327c3b28932c
2021-05-20 10:03:46 +00:00
Florin Coras
72afc4feb7 tls: fix signed unsigned comparison
On error, the signed value is cast to unsigned.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I0f94422f47e40d7c358118b2df8ab96cf4116dd0
2021-05-19 18:33:29 -07:00
Dave Wallace
785458895d bash: fix vpp-make-test -g option
- Don't pollute shell with local variables
  which also fixes a bug with -g option
- If WS_ROOT is not set and vpp-make-test is
  invoked in the vpp root dir, then export
  WS_ROOT env var

Type: fix

Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: I608b666f7d3020863933a8072fb34e65c7f1c988
2021-05-19 22:52:26 +00:00
Dave Wallace
d064c5976d quic: fix memory leak & crash on connection delete
- quicly conn struct leaked on connection delete
- Occasionally connection delete is called twice
  before connection is closed which caused a crash.

Type: fix

Change-Id: Ifaaaeda55f71d58c97fa4d6652bda60a3efd4b69
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2021-05-19 17:22:13 -04:00
Florin Coras
46b8b1a4c0 session: cleanup event llist usage
Type: refactor

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I750c856ac81d951e8c0e62c710e0f35a0c80d6f9
2021-05-19 19:34:12 +00:00
Damjan Marion
6e9964e6c0 memif: remove dead code
Type: fix
Change-Id: I6fce8c1f91fc5080271c1832bf40a9fb6bbcb7e3
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-05-19 19:06:07 +00:00
Damjan Marion
2e212c2c72 avf: improve elogs
Change-Id: I6221e1a5924223865b3caf53590d3668965b564c
Type: fix
Fixes: b4ff07a
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-05-19 19:05:56 +00:00
Florin Coras
fa3bd30377 vppinfra: add more llist macros
Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ife79871c6530d2cd485928fee465baf2c8957e11
2021-05-19 17:01:16 +00:00
Florin Coras
b32af35fb9 session: fix session queue node access on disable
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ie4e3623e7e00456437fac5fb8f9c9083f1aa2a2e
2021-05-19 14:53:18 +00:00