10741 Commits

Author SHA1 Message Date
Benoît Ganne
f89bbbe300 vlib: refactor trajectory trace debug feature
trajectory trace has been broken for a while because we used to save the
buffer trajectory in a vector pointed to in opaque2. This does not work
well when opaque2 is copied (eg. because of a clone) as 2 buffers end up
sharing the same vector.
This dedicates a full cacheline in the buffer metadata instead when
trajectory is compiled in. No dynamic allocation, no sharing, no tears.

Type: refactor

Change-Id: I6a028ca1b48d38f393a36979e5e452c2dd48ad3f
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-05-01 11:42:37 +00:00
Damjan Marion
c8983241b9 build: add option to turn off some march variants
Type: make
Change-Id: I53f7995c7e7a7ff829c662d71f37d88780bdd140
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-05-01 00:54:42 +00:00
Damjan Marion
3648d93b98 build: declare some CMake variables as advanced
Type: make
Change-Id: I780c1c81a50cb92bc89c05856efd8ef88479c0ab
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-30 20:30:16 +02:00
Damjan Marion
88b2e3682b misc: experimental configure script
Type: make
Change-Id: Iaeb9d22eec9a7a763b63899814a44e78c8050f1f
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-30 17:02:32 +00:00
Florin Coras
10796899cf quic: report number of packets sent on custom tx
A transport's custom_tx function must report the number of segments that
it enqueued.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ie088c4215e6f17df639159820b8adf46b96fbb46
2021-04-30 14:39:55 +00:00
Florin Coras
01fcd757a1 hsa: vcl test client incremental stats
Add option to print per second tx stats

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I7f226a6521da13ab29de65a441f73d4e56fb57cf
2021-04-30 14:39:39 +00:00
Damjan Marion
1bb67abf3c build: switch release build to -O3
Type: make
Change-Id: Ia39c2f847e7b4907fdd3fcac75897b8b4c545a65
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-30 11:15:47 +02:00
Florin Coras
600d7a85fb session: accept notifies for sessions in created state
Makes sure we don't notify apps of sessions that are closing or multiple
times for the same session.

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I07145e5e00bbe8eb1df2946059459e9fe05cfeb7
2021-04-29 18:52:17 +00:00
liuyacan
87d48ad8f6 session: cleanup CREATED sessions when listener goes down
We should cleanup sessions in CREATED state when listener goes
down, otherwise they may use unpredictable sessions as listeners
later.

Type: fix

Signed-off-by: liuyacan <liuyacan@corp.netease.com>
Change-Id: Ifbd0a0fb46275bd9d89e5aee19a70c1d01d15764
2021-04-29 17:52:53 +00:00
Benoît Ganne
5c481ff732 crypto: fix chained buffer integrity support
Type: fix

Change-Id: I984a3e577a4209e41d046eaf3a8eef8986dc6147
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-04-29 15:48:25 +00:00
Florin Coras
edda5926e0 hsa: vcl test perf improvements
- poll session events in server
- init session buffers based on config
- cleanup some of the data structures

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I81c19e6546c8292db07b63c66e4da03ef7f55e22
2021-04-29 00:07:12 -07:00
Florin Coras
ccdb8b8b15 vcl: fix epoll wait with indefinite timeout
Also avoid syscalls if timeout is 0.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I9193d731c51a1432a52c89d5e54e6406e5100c96
2021-04-28 18:10:10 -07:00
Damjan Marion
3295ddf6b6 vppinfra: AArch64 NEON implementation of clib_compare_u16_x64()
Type: improvement
Change-Id: I1382813211ea20c6204d7a3b6e6d470aa51aed69
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-28 19:00:37 +00:00
Klement Sekera
ea6236b376 tests: add worker count to class description
While running test:

==============================================================================
NAT44ED Test Case
==============================================================================

==>

==============================================================================
NAT44ED Test Case [main thread only]
==============================================================================

==============================================================================
NAT44ED Test Case [1 worker thread]
==============================================================================

==============================================================================
NAT44ED Test Case [4 worker threads]
==============================================================================

Type: improvement
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: I61904b411ff1b58700564698079dc4c07cea5c5e
2021-04-28 18:35:46 +00:00
Damjan Marion
edca8c6e75 vppinfra: don't fail if config.h is missing, fallback to defaults instead
Type: improvement
Change-Id: Idc82d40a16cbc8a401a8fb359bc63083f47361b9
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-28 17:23:22 +00:00
Ole Troan
df6d986f81 papi: change default to use socket transport instead of shared memory transport
In preparation for removing Python shared memory support, change the default to use sockets.
This may affect users of PAPI. E.g. if running against instances of VPP where
the API socket is in a different location or disabled.

Type: improvement
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: I96308ed70b9ff314c9b487722174f5e4b14efdd2
Signed-off-by: Ole Troan <ot@cisco.com>
2021-04-28 16:03:45 +00:00
mdr78
fd4fd0d185 pg: exec file fixes
A number of the pg commands were being passed the whole exec file,
instead of just a line from the file.

Type: fix

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I2f96e7648b9b7d501088eddff7e4a761973e71f4
2021-04-28 14:58:00 +00:00
Florin Coras
8d58dc40a0 hsa: fix quic vcl test
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I9a4bf384be65ba8b868d1172c7b6e00ae959601e
2021-04-28 14:57:57 +00:00
Florin Coras
05c45b77d1 hsa: support sigint in vcl test client
Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ie0d5fe97a727465f8851fc2110219483a5bf3f27
2021-04-28 13:11:51 +00:00
Arthur de Kerhor
a80ff1384c ip: extend the punt cli to accept reason filter for sockets registration
Type: improvement
Signed-off-by: Arthur de Kerhor <arthurdekerhor@gmail.com>
Change-Id: I769db1213b0936abbf304bc6cf9dbcfbbebf06aa
2021-04-28 07:39:42 +00:00
Matthew Smith
e3f078fcfc nat: fix byte order on ipfix message fields
Type: fix

The code for quota exceeded events is a u32 and was being copied
into ipfix packets in host byte order. Same for the limit field.

Swap the order before copying into packet buffer.

This change was applied once before but had to be reverted. This was
because between the time the change was uploaded/reviewed and the
time it was merged, a different patch was merged which activated a
NAT ipfix unit test that had formerly only been run as part of the
extended tests. The test was expecting the values to be in host byte
order so it failed with this patch applied. This time around, that
test has also been updated to expect network byte order.

Change-Id: If5413b1f806d664f6786e56ba13c3eee573c26d2
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2021-04-28 06:30:36 +00:00
Neale Ranns
f2b6b9e29b gre: Remove the debugging logging from the mGRE tests
Type: test

Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: I5c540b3a2f26689973daec80372c5a935a455a12
2021-04-27 23:57:00 +00:00
Damjan Marion
ac8f936fdc build: Makefile cleanup
Type: make
Change-Id: I751b0a25161c6eb8614ca19f7c77a4de82401f3d
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-27 23:42:02 +00:00
Damjan Marion
1bc46cd6e3 misc: fix dead stores
Type: fix
Change-Id: I08969e1c4a78f8ac92ec066a3b67e64dc931bc16
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-27 23:41:51 +00:00
Damjan Marion
ef0bac7099 vlib: improve enqueue_to_next buffer indices extraction
Type: improvement

Change-Id: Ib7b2fa7d821f6d2708f6dc378a0f36f68c843f57
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-27 23:40:27 +00:00
Florin Coras
d77d379ea6 hsa: custom proto vfts for vcl tests
Define custom connect, listen, accept, close handlers for transport
protos under test.

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ifa260d05917256c590f29078f465ce47c576cbc3
2021-04-27 22:35:39 +00:00
Florin Coras
5c97dbfdb2 session: fix mq ext config cleanup
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I18eb1a71ac22017f75f835a23a57b023b46524ce
2021-04-27 20:28:47 +00:00
Damjan Marion
23c3488b9b misc: add StatementMacros to .clang-format
Type: make
Change-Id: I79d8d0aa8b8349df0b3c1f338861350e8df31ca6
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-27 14:29:23 +00:00
Damjan Marion
83b2f5e34b vppinfra: silence coverity warnings related to clib_memcpy_u32()
Type: fix
Change-Id: I17e7b3fca390c0b0150c4606f7c93771ee9bdbdc
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-27 14:28:48 +00:00
Steven Luong
efe6eddcf8 misc: update arp and ip6-nd files location
arp and ip6-nd are not plugins [yet]. Change the files location to
reflect its current correct locations.

Type: fix

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: Ibcde8867cc50abbf2061d1e80390c528393ec4df
2021-04-27 09:27:17 +00:00
Ryo Nishikawa
4ec02990a7 vppinfra: Fix a bug related to path_search
Type: fix
Signed-off-by: Ryo Nishikawa <nishikawa0320@gmail.com>
Change-Id: Iabf7e088245395ea3fff62a22266a31de3fc305e
2021-04-27 09:26:11 +00:00
Matthew Smith
98d8362741 vrrp: increase stack size of process node
Type: fix

The process node which wakes up when a timer expires and transitions
a backup node to master state may call a function to add a MAC address
to an interface. This works fine for some devices, but with DPDK 20.11
on i40e interfaces, the i40e PMD functions which enact the change cause
the stack to be exhausted. Increase the stack size for the node.

Change-Id: I824603e162f4f6d680486706210986572f0d9845
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2021-04-27 09:25:29 +00:00
Vladimir Lavor
3ff1598846 misc: auto-generate go bindings
Type: feature

Added target 'make go-api-files' creating compatible go bindings
using JSON API definition and GoVPP binary API generator.

Signed-off-by: Vladimir Lavor <vlavor@cisco.com>
Change-Id: I5bae113b85eaf5ebda8e292d34c9826075ef19b5
2021-04-27 09:24:48 +00:00
mdr78
8e1384f7bf perfmon: top down level 1 support
Adding perfmon node TMAM support on ICX.

Type: improvement

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I48a9a9ff6a72efc28eaf0cb11ef39fb62cebb126
2021-04-27 09:22:35 +00:00
Florin Coras
3f923d2d46 hsa: use only one conn type for vcl tests
Type: refactor

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I31d0f8e32f7bb508c6f57913d5a829ceaad91f7d
2021-04-27 09:20:30 +00:00
Damjan Marion
137869dbfb vapi: silence warnings
Type: fix
Change-Id: I91d7bfbfaafc7b780f91dec7c9e5ce07241e6394
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-26 23:26:03 +02:00
Florin Coras
7992bdcece hsa: use tcp for vcl test control channel
Also, only exchange config over control session.

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I001df635896762bc5330cebb7d5744e3e754482d
2021-04-26 15:01:11 +00:00
Damjan Marion
856d062ce6 vppinfra: clib_memcpy_u32() utilizing SIMD mask loads/stores
Type: improvement
Change-Id: I55c4688bd1feffae139ce12a66d15885373e5cd7
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-26 13:47:40 +00:00
Ray Kinsella
c99ab12cbb pg: fix packet coalescing cli
Small fix to the packet coalescing cli.

Type: fix

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I1edbf6e43937aa0345185f06437095e0558dba31
2021-04-26 12:23:31 +00:00
Paul Vinciguerra
da1b76aa89 vppapigen: remove flag day code
The flag day for the crc algorithm change has long passed and
should not be carried into the next release.

Type: refactor

Change-Id: I1b1027139a778907926e48a8a553b908a79db08f
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2021-04-26 07:17:29 +00:00
Paul Vinciguerra
dc22c839f0 tests: clean up gbp calls from vpp_papi_provider
Move info from vpp_papi_provider to .api/vpp_objects

Change-Id: Iaf46483fda2840dfec8d37e0b9262e1c9912be59
Type: test
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2021-04-26 06:05:52 +00:00
liuyacan
9f299030fd session: fix race condition in fifo allocation
Under some timing conditions,VCL may receive CONNECTED/ACCEPTED
event before ADD_SEGMENT event.

Timing example:

2 threads call segment_manager_alloc_session_fifos() parallelly

         Thread 1                Thread 2

       sm read lock                 |
            |                       |
     try to alloc fifo =>failed     |
            |                       |
       sm read unlock               |
            |                       |
       sm write lock                |
            |                       |
       add segment                  |
            |                       |
       sm write unlock              |
            |                  sm read lock
            |                       |
            |               try to alloc fifo=>successful
       sm read lock                 |
            |                  sm read unlock
            |                       |
            |                 emit CONNECTED/ACCEPTED
   emit ADD_SEGMENT event
            |
       sm read unlock

This commit move ADD_SEGMENT notification under the protection
of the write lock in some scenarios.

Type: fix

Signed-off-by: liuyacan <liuyacan@corp.netease.com>
Change-Id: I25d5475c5e6d37cfccefa9506f6030c26ce8ee9b
2021-04-26 04:25:40 +00:00
Damjan Marion
b14c49d227 vppinfra: add COMPILE_TIME_CONST() macro
Type: improvement
Change-Id: I10d7489f57bc60eb92049962b4e6ea84974f17b8
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-25 20:48:53 +00:00
Damjan Marion
e984831e07 vppinfra: AVX512 mask load/stores and compress store
Type: improvement
Change-Id: Id6be598aade072653e408cca465e62931d060233
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-25 17:43:34 +00:00
Damjan Marion
e21a0b2604 vppinfra: add clear_lowest_set_bit() function, use BMI2 if available
Type: improvement
Change-Id: I973cacd0cade0ca98e6261c1fb026a5eb38b44d3
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-04-25 10:59:42 +02:00
Klement Sekera
1ca6c65e51 nat: correct detection of icmp bypass presence
Type: fix
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: Iead167e7497e0779c440f7fb243014a06ae2b452
2021-04-23 19:59:27 +00:00
Nathan Skrzypczak
3e38422ab9 vxlan: Fix L3 mode
Type: fix

Partially revert fix SEGV reported in VPP-1962
[commit a4b0541f64eef02fa0d003d8f831cfdeb45d3668]

This adds an is_l3 option to choose between L2 & L3
mode add tunnel creation time

Change-Id: Ia2c91a1099074b7d23fc031b78ed0f68628eeabe
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-04-23 19:23:12 +00:00
Florin Coras
893bc97ed6 session: set connected session index for ct
Set connected session index for ct as well.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Id82ffcf5572b6a9d2769c0e685c7a0b4d1ea9e9f
2021-04-23 16:04:00 +00:00
Alexander Chernavin
961d363112 dpdk: support md5 async handler in dpdk cryptodev
With this change, enable MD5 with AES-CBC support in dpdk cryptodev.

Type: improvement
Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
Change-Id: Ic587aaa1fa0dc102e36eb34f329ef21a16156f26
2021-04-23 16:02:18 +00:00
Florin Coras
607ece36b6 tcp: try to update sack list only if not empty
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ieb5af96de5be33356dbab7bc4ab4696731fa8866
2021-04-23 15:24:26 +00:00