vpp.git
4 months agobuild: Add Debian12 environment 92/40192/2
Pim van Pelt [Sun, 14 Jan 2024 20:02:41 +0000 (21:02 +0100)]
build: Add Debian12 environment

Add clang-14 and libffi8 which ship with Debian Bookworm. The project
compiles cleanly with these versions.

Type: make
Change-Id: I17350aae30cec72987792d54d88231b3221b56b9
Signed-off-by: pim@ipng.nl
4 months agosession: fix app wrk free leak 91/40191/2
Florin Coras [Fri, 12 Jan 2024 18:10:17 +0000 (13:10 -0500)]
session: fix app wrk free leak

Type: fix

Change-Id: I9c48b163f174b824df1a76e75c272dc985386bf2
Signed-off-by: Florin Coras <fcoras@cisco.com>
4 months agocrypto-native: add AES-CTR 81/40181/5
Damjan Marion [Thu, 11 Jan 2024 17:37:46 +0000 (17:37 +0000)]
crypto-native: add AES-CTR

Type: feature
Change-Id: Iab84226043d8042a99a507767b75e9d4a89cc5c6
Signed-off-by: Damjan Marion <damarion@cisco.com>
4 months agovppinfra: native AES-CTR implementation 76/40176/8
Damjan Marion [Mon, 8 Jan 2024 19:05:40 +0000 (19:05 +0000)]
vppinfra: native AES-CTR implementation

Type: feature
Change-Id: I7ef3277edaeb266fbd3c8c9355d4443002ed2311
Signed-off-by: Damjan Marion <damarion@cisco.com>
4 months agohttp: fix memory leak 85/40185/1
Filip Tehlar [Fri, 12 Jan 2024 10:18:57 +0000 (11:18 +0100)]
http: fix memory leak

Type: fix

Change-Id: I36905132a42d23e719bf0e82eeafa48f60f4887a
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
4 months agolibmemif: fix segfault and buffer overflow in examples 66/39266/4
Tianyu Li [Wed, 12 Jul 2023 05:51:42 +0000 (05:51 +0000)]
libmemif: fix segfault and buffer overflow in examples

- Fix buffer overflow caused by strncpy(dst, src, strlen(src)),
use sized buffer to ensure overflow safe.

- Fix test_app getopt usage

 When use example/icmp_responder in slave mode
- Fix segfault when buffer size is not specified
- Fix wrong packet send out.

Type: fix
Signed-off-by: Tianyu Li <tianyu.li@arm.com>
Change-Id: I5ed47fd8e630420d7ae0203a2605d2b9abd33d2a

4 months agolibmemif: fix for memif_init_queues slot math 77/40077/6
mbly [Wed, 6 Dec 2023 20:22:14 +0000 (12:22 -0800)]
libmemif: fix for memif_init_queues slot math

Increase slot variable to u32 to address combinations of num-queues and queue-size that cause slot variable to wrap when declared as u16, e.g. num-queues > 8 && queue-size is 2^12

Type: fix
Change-Id: I5bd6198d60395156a06f1a280ea2594824ceaa9d
Signed-off-by: mbly <mbly@ciena.com>
4 months agolibmemif: Fix for memif_buffer_alloc rewind logic 65/40065/10
mbly [Tue, 5 Dec 2023 17:36:49 +0000 (09:36 -0800)]
libmemif: Fix for memif_buffer_alloc rewind logic

Rewind logic was not supporting count = 1, where size was > memif_buffer_size and a rewind is required.
Fixed slot-->next_buf bug for !master as well.

Type: fix
Change-Id: I65cf0d3d0c105f37125412a613e5ff8c5da9a3a2
Signed-off-by: mbly <mbly@ciena.com>
4 months agolibmemif: added tests 53/37953/9
Daniel Béreš [Thu, 19 Jan 2023 09:19:27 +0000 (10:19 +0100)]
libmemif: added tests

This patch provides unit tests for libmemif written in Unity

Type: test

Signed-off-by: Daniel Béreš <dberes@cisco.com>
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I19116def6e6d28efd5f460c93911245474a11321

4 months agohs-test: add more asserts 79/40179/2
Filip Tehlar [Thu, 11 Jan 2024 16:17:33 +0000 (17:17 +0100)]
hs-test: add more asserts

Type: test

Change-Id: Ia285ff39d9b19464ea086ec847ceaf52c6c0195c
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
4 months agocrypto: align host and VPP IPsec-mb lib 76/39976/16
Ranjan Raj [Mon, 20 Nov 2023 07:04:24 +0000 (07:04 +0000)]
crypto: align host and VPP IPsec-mb lib

Ensure alignment between the Intel IPsec-mb library on the
host and VPP targets.If the version of Intel ipsec-mb on the
host is misaligned with the targets,terminate the compilation
process to prevent potential library linkage issues.

Type: fix

Change-Id: I38864115d59ae09fb5556ad4a29e884ebace8155
Signed-off-by: Ranjan Raj <ranjanx.raj@intel.com>
4 months agohs-test: add tls proxy test 26/40026/5
Filip Tehlar [Wed, 29 Nov 2023 06:40:18 +0000 (07:40 +0100)]
hs-test: add tls proxy test

Type: test

Change-Id: I8f3f4c464907356bb1990ea53f0f46befc057acf
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
4 months agohs-test: retry command on test setup failure 70/40070/2
Filip Tehlar [Wed, 6 Dec 2023 10:35:11 +0000 (11:35 +0100)]
hs-test: retry command on test setup failure

Type: test

Change-Id: Iad744c4b3f79820e8bd0dd2ef9f18e4f7718e845
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
4 months agolinux-cp: fix route prefix construction 42/40142/4
Alexander Skorichenko [Tue, 26 Dec 2023 15:27:10 +0000 (16:27 +0100)]
linux-cp: fix route prefix construction

Prevent comparison ops for uninitialized IPv6 prefix bytes.

Type: fix

Change-Id: I440fea7f0725769406ad348eb3402a98c593dc3c
Signed-off-by: Alexander Skorichenko <askorichenko@netgate.com>
4 months agolinux-cp: Fix looping netlink messages 22/39622/9
Pim van Pelt [Fri, 6 Oct 2023 09:26:33 +0000 (11:26 +0200)]
linux-cp: Fix looping netlink messages

Signal when consuming a batch of netlink messages, in order to inhibit
lcp_sync from generating new netlink messages. This avoids link up/down
state changess from triggering an infinite loop.
Do this in the regular case of nl_route_process_msgs()
and in the special case of re-synchronizing in lcp_nl_recv_dump_replies().
Type: fix
Change-Id: I419d3f9aa350c119b3778b644c65165cb4cc1bef
Signed-off-by: Pim van Pelt <pim@ipng.nl>
4 months agourpf: add interface dump to API 86/40086/6
Pim van Pelt [Sun, 10 Dec 2023 20:07:38 +0000 (21:07 +0100)]
urpf: add interface dump to API

Add an urpf_interface_dump() API call, with optional sw_if_index.
If either a mode or a table is specified in any given interface
address family and direction, return it in a list, otherwise omit
it.

TESTED:
create loopback interface instance 0
create loopback interface instance 1
create loopback interface instance 2
create loopback interface instance 3
ip6 table add 8298
set urpf ip4 rx loose loop1
set urpf ip6 tx off loop2 table 8298

API call urpf_interface_dump(sw_if_index=~1) returns:
[
urpf_interface_details(_0=658, context=2, sw_if_index=2, is_rx=True, mode=<vl_api_urpf_mode_t.URPF_API_MODE_LOOSE: 1>, af=<vl_api_address_family_t.ADDRESS_IP4: 0>, table_id=0),
urpf_interface_details(_0=658, context=2, sw_if_index=3, is_rx=False, mode=<vl_api_urpf_mode_t.URPF_API_MODE_OFF: 0>, af=<vl_api_address_family_t.ADDRESS_IP6: 1>, table_id=8298)
]

Type: improvement
Change-Id: I1ded5c445dc07dab73ea41b817b5827b72ca79d4
Signed-off-by: pim@ipng.nl
4 months agosession: make app listener pool global 39/40139/15
Florin Coras [Fri, 22 Dec 2023 03:41:12 +0000 (19:41 -0800)]
session: make app listener pool global

One less pointer chase when accepting sessions.

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I20dbb21d15d4a703f76e3b12f04a6f5b5d2a3cd8

4 months agosession: support for cl port reuse 91/40091/22
Florin Coras [Tue, 12 Dec 2023 00:04:57 +0000 (16:04 -0800)]
session: support for cl port reuse

Adds support for connectionless listener port reuse. Until now, cl
listeners had fifos allocated to them and therefore only one app worker
could ever listen, i.e., a session cannot have multiple fifos.

To circumvent the limitation, this separates the fifos from the listener
by allocating new cl sessions for each app worker that reuses the app
listener. Flows are hashed to app worker cl sessions but, for now, this
is not a consistent/fixed hash.

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ic6533cd47f2765903669f88c288bd592fb17a19e

4 months agosession: avoid spurious closed notifications 96/40096/4
Florin Coras [Tue, 12 Dec 2023 22:01:43 +0000 (14:01 -0800)]
session: avoid spurious closed notifications

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ia98556e7ae61547cf153c78ec085cd4248bee74a

4 months agolibmemif: add name to maintainer file 78/39978/1
Mohsin Kazmi [Mon, 8 Jan 2024 13:45:52 +0000 (13:45 +0000)]
libmemif: add name to maintainer file

Type: docs

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I994d843a035e6afc4b72d06745d2be74cd81cd3a

4 months agoflowprobe: fix calling vlib_time_now() from worker threads 43/40143/2
Alexander Chernavin [Wed, 27 Dec 2023 11:17:23 +0000 (11:17 +0000)]
flowprobe: fix calling vlib_time_now() from worker threads

Currently, when flowprobe_export_send() calls vlib_time_now(), a pointer
to the main thread's vlib_main_t is always passed (the one cached in
flow_report_main). However, that code can also be executed from a worker
thread. And passing a pointer to the main thread's vlib_main_t to
vlib_time_now() from a worker thread may cause time synchronization
issues. Also, running a debug binary will cause an assertion failure in
vlib_time_now() in this case.

With this fix, flowprobe_export_send() passes the pointer to the current
thread's vlib_main_t to vlib_time_how().

This doesn't allow to remove @tag_fixme_vpp_workers from the unit tests
yet as they will be failing for other multi-worker related problems.

Type: fix
Change-Id: Ia35e3a4176777b88cf8ca8af8af7c42c495cbc6a
Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
4 months agohttp: unify client/server state machines 10/37610/8
Filip Tehlar [Mon, 30 Oct 2023 07:21:36 +0000 (08:21 +0100)]
http: unify client/server state machines

Type: improvement

Change-Id: I57a816fbed8b681dec201edc8d5950a34a555a2b
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
4 months agodocs: minor updates to the lxc container test writeup 46/40146/2
Dave Barach [Fri, 29 Dec 2023 16:15:34 +0000 (11:15 -0500)]
docs: minor updates to the lxc container test writeup

Fix minor differences between Ubuntu 18.04 LTS and Ubuntu 22.04 LTS when
using the scheme to test new code.

Type: docs

Change-Id: I5810b6f3d76d8d98fa764b61828b1ca32507bd91
Signed-off-by: Dave Barach <dave@barachs.net>
4 months agosession: add flag to track cless sessions 35/40135/7
Florin Coras [Thu, 21 Dec 2023 21:50:53 +0000 (13:50 -0800)]
session: add flag to track cless sessions

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I0bb6aba26f1cd974d6bb3b5fe6234aacfee0d30c

4 months agohs-test: more proxy vars for docker builds 40/40140/2
Florin Coras [Sat, 23 Dec 2023 00:58:26 +0000 (19:58 -0500)]
hs-test: more proxy vars for docker builds

Type: improvement

Change-Id: Ica9d87abde7a1dc0b4007911a7e0abab46dfb75d
Signed-off-by: Florin Coras <fcoras@cisco.com>
4 months agotests: Temporarily skip an unstable test 38/40138/3
adrianvillin [Fri, 22 Dec 2023 15:52:56 +0000 (16:52 +0100)]
tests: Temporarily skip an unstable test

Type: test

Change-Id: Idd608511ed350a8e13afff393e558e20d52627a0
Signed-off-by: adrianvillin <avillin@cisco.com>
4 months agohs-test: use prebuilt curl with http3 support 36/40136/5
Florin Coras [Fri, 22 Dec 2023 03:18:25 +0000 (19:18 -0800)]
hs-test: use prebuilt curl with http3 support

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I4d17ae3f7736dc10c68ca6e304699ea39d012f6c

4 months agoquic: seed random generator during init 37/40137/2
Filip Tehlar [Fri, 22 Dec 2023 13:04:29 +0000 (14:04 +0100)]
quic: seed random generator during init

Quic does not seed random value, so if the plugin is loaded
separately RAND_bytes will fail.

Type: fix

Change-Id: If600cbde1fef30afb6316fc1a355261b008c3191
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
4 months agosession: unset fifo evt to enqueue ack evt on tcp timewait 28/40128/7
emmanuel [Thu, 21 Dec 2023 09:55:41 +0000 (01:55 -0800)]
session: unset fifo evt to enqueue ack evt on tcp timewait

Incase the ack for the fin is lost twice or want to dup ack
packets with incorrect ack/seq # at different times and
session state is already closed, this fifo event is set for
the first ack that went out and prevents queuing of further events.

Type: fix
Change-Id: I102019fca26918a51e055a751db7209011bd43ad
Signed-off-by: emmanuel <emmanuelscaria11@gmail.com>
4 months agovlib: lowercase vmbus device names 20/40120/2
Alexander Skorichenko [Tue, 19 Dec 2023 12:08:13 +0000 (13:08 +0100)]
vlib: lowercase vmbus device names

Use lowercased hex in uuid in sysfs/vmbus names

Type: fix

Change-Id: Ic4b7b995441723dc1b29ff8a75346cc8ba7f85f1
Signed-off-by: Alexander Skorichenko <askorichenko@netgate.com>
4 months agovlib: add error checks to thread pinning 25/40125/4
hsandid [Wed, 20 Dec 2023 14:41:54 +0000 (15:41 +0100)]
vlib: add error checks to thread pinning

Type: fix

Added error checks around pthread_setaffinity_np
calls to stop vpp launch if pinning fails.

Change-Id: Iec391c485d1832b6c2ff20fbf789608f6bcf7b57
Signed-off-by: hsandid <halsandi@cisco.com>
4 months agobuild: fix 'make test' target to build with clang 27/40127/2
Dave Wallace [Thu, 21 Dec 2023 01:02:45 +0000 (20:02 -0500)]
build: fix 'make test' target to build with clang

- gmake set CC=cc as the default therefore the test/test-debug
  makefile targets will build using gcc (cc == gcc for debian/ubuntu
  distros) unless set explicitly to clang due to use of 'CC=$(CC)' in
  test macro.

  Note: the CI builds vpp images prior to running 'make test', thus
  the CI does test vpp built using clang.  This basically makes local
  runs of 'make test' build using clang as well.

Type: make

Change-Id: I7221098c200be23b53bb616e41a42a6d65a03699
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
4 months agobuild: add .cmake to gitignore 34/40134/2
Damjan Marion [Thu, 21 Dec 2023 19:00:26 +0000 (20:00 +0100)]
build: add .cmake to gitignore

Type: improvement
Change-Id: I3047b4a750581d68053f522479b23865e3da2505
Signed-off-by: Damjan Marion <damarion@cisco.com>
4 months agobuffers: add vlib_buffer_unalloc_to_pool() 32/40132/3
Damjan Marion [Thu, 21 Dec 2023 14:52:46 +0000 (15:52 +0100)]
buffers: add vlib_buffer_unalloc_to_pool()

Change-Id: Icd616989a525ef0be6c73a2ad91ae4871cf3921d
Type: improvement
Signed-off-by: Damjan Marion <damarion@cisco.com>
4 months agodev: per-queue format callbacks 33/40133/1
Damjan Marion [Thu, 21 Dec 2023 14:54:14 +0000 (15:54 +0100)]
dev: per-queue format callbacks

Change-Id: Ia9fa6fab6288b4d0876022e72bf4f49bd00a19d2
Type: improvement
Signed-off-by: Damjan Marion <damarion@cisco.com>
4 months agofib: format deleted LB 30/40130/3
Nathan Skrzypczak [Thu, 21 Dec 2023 10:35:30 +0000 (11:35 +0100)]
fib: format deleted LB

This patch allows the formatting of deleted Load-balancer
objects. This is needed in the case a trace references a DPO
that went away in the interim.

Type: improvement

Change-Id: I6d67519b8d62f69aafde3c8fe3065bc85a7adbde
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
4 months agotests: memif interface tests using libmemif 19/39319/6
Naveen Joy [Fri, 28 Jul 2023 23:33:30 +0000 (16:33 -0700)]
tests: memif interface tests using libmemif

Type: test

Change-Id: I711dfe65ad542a45acd484f0b4e3e6ade9576f66
Signed-off-by: Naveen Joy <najoy@cisco.com>
4 months agovirtio: virtio_flags api use enumflag instead of enum 11/40111/2
Ole Troan [Fri, 15 Dec 2023 07:37:26 +0000 (08:37 +0100)]
virtio: virtio_flags api use enumflag instead of enum

In the API there is a difference between enum and enumflags.
The latter one allowing multiple set entitires, while enum
only allows one.

Type: fix
Change-Id: I5db88c15c85fc6c7130b7b35febcd1ea02ef8f76
Signed-off-by: Ole Troan <otroan@employees.org>
4 months agosrv6-mobile: Implement SRv6 mobile API funcs 04/40104/2
Takeru Hayasaka [Thu, 27 Oct 2022 19:26:05 +0000 (04:26 +0900)]
srv6-mobile: Implement SRv6 mobile API funcs

This merge request adds the feature to manipulate localsids and policies for SRv6 mobile via API.

Type: feature
Signed-off-by: Takeru Hayasaka <hayatake396@gmail.com>
Change-Id: Ibb46bf71ae1d9d4591ce2c8ccf66f520887dad70

5 months agodevices: add cli support to enable disable qdisc bypass 34/35934/8
Mohsin Kazmi [Mon, 11 Apr 2022 17:21:40 +0000 (17:21 +0000)]
devices: add cli support to enable disable qdisc bypass

Type: improvement

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: Ic124f44e64bd60f41e750b4118be3e8d1d1eb70b

5 months agohs-test: decrease docker image size 07/40107/3
Filip Tehlar [Thu, 14 Dec 2023 15:29:11 +0000 (16:29 +0100)]
hs-test: decrease docker image size

Type: test

Change-Id: Ic1ad2f1f983ad8f8e8e8813f941e11757930c92e
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
5 months agohs-test: remove unnecessary app ns configs 05/40105/2
Filip Tehlar [Thu, 14 Dec 2023 12:06:54 +0000 (13:06 +0100)]
hs-test: remove unnecessary app ns configs

Type: test

Change-Id: I0226227dc756a5a3af5e9d3b0d65a38c0aa55b3d
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
5 months agotests: Added bpf trace filter plugin test 75/40075/7
adrianvillin [Wed, 6 Dec 2023 18:21:49 +0000 (19:21 +0100)]
tests: Added bpf trace filter plugin test

Type: test

Change-Id: I026d9298fe1372d03f61b6ad57c82628bab4c831
Signed-off-by: adrianvillin <avillin@cisco.com>
5 months agordma: add rdma_create_v4 that handles flags properly 06/40106/6
Vratko Polak [Thu, 14 Dec 2023 16:11:38 +0000 (17:11 +0100)]
rdma: add rdma_create_v4 that handles flags properly

The _v3 was not handling endianness on flags (e.g. mode).
Marking _v3 as deprecated, but keeping it
as there might be users who learned to preprocess their flag values.

+ Also, format PCI product_name as a vector, not a string.

Type: fix

Change-Id: I50c4b44f3570f02518dbd9a43239c1a37612d24a
Signed-off-by: Vratko Polak <vrpolak@cisco.com>
5 months agosession: add forced reset api to ct transport 08/40108/3
Florin Coras [Thu, 14 Dec 2023 19:46:11 +0000 (11:46 -0800)]
session: add forced reset api to ct transport

Type: improvement

Change-Id: Iebf9ee8275a92e962679e3d0d22d33ed0bd8b3ab
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 months agotls: no closed notify if no app session 03/40103/3
Florin Coras [Wed, 13 Dec 2023 22:26:19 +0000 (14:26 -0800)]
tls: no closed notify if no app session

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I0e58bb970d371818217390d451cf26925b04970f

5 months agobpf_trace_filter: allow use whithout classifier 84/40084/2
Mohammed Hawari [Fri, 8 Dec 2023 10:16:54 +0000 (11:16 +0100)]
bpf_trace_filter: allow use whithout classifier

Change-Id: I7ac5693ca547fe7249e7b6297bade70a6052b169
Type: improvement
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
5 months agotls: postpone ho cleanup if not fully established 56/40056/3
Florin Coras [Tue, 5 Dec 2023 04:29:52 +0000 (20:29 -0800)]
tls: postpone ho cleanup if not fully established

If ho cleans up on first worker before owner of established session
receives connected notification, the ho session is prematurely cleaned
up.

Wait for established ctx to be allocated before freeing ho.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Icf707e5d8c62a288a49d078460d2ada3b5c41b0e

5 months agocnat: undo fib_entry_contribute_forwarding 90/40090/3
Nathan Skrzypczak [Mon, 11 Dec 2023 17:54:21 +0000 (18:54 +0100)]
cnat: undo fib_entry_contribute_forwarding

Type: fix

Change-Id: I9df43a34328209c87177a534d08919dda0af6096
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
5 months agodpdk: bump rdma-core to 49.0 92/40092/2
Dave Wallace [Tue, 12 Dec 2023 02:31:09 +0000 (21:31 -0500)]
dpdk: bump rdma-core to 49.0

- Per dpdk 23.11 release notes (rdma-core >= 48.0)

Type: feature

Change-Id: I6f73fdfd2226c501d22cd16e5c47500ff05fbff3
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
5 months agoipsec: allow receiving encrypted IP packets with TFC padding 63/39163/9
Arthur de Kerhor [Fri, 16 Jun 2023 07:48:52 +0000 (09:48 +0200)]
ipsec: allow receiving encrypted IP packets with TFC padding

Type: feature
Change-Id: I7b29c71d3d053af9a53931aa333484bf43a424ca
Signed-off-by: Arthur de Kerhor <arthurdekerhor@gmail.com>
Signed-off-by: Benoît Ganne <bganne@cisco.com>
5 months agovppinfra : fix alignment issue 87/40087/1
hsandid [Mon, 11 Dec 2023 03:47:11 +0000 (04:47 +0100)]
vppinfra : fix alignment issue

Type: fix

Modified alignment cast causing crash issues

Change-Id: Iae3bb767ef2ba81466bf1567264a4c76ae45bb92
Signed-off-by: hsandid <halsandi@cisco.com>
5 months agodev: caps and rx/tx offload support 80/40080/3
Damjan Marion [Thu, 7 Dec 2023 15:40:02 +0000 (16:40 +0100)]
dev: caps and rx/tx offload support

Type: improvement
Change-Id: I7972f595444eacdb020f3fa2a60331c40766fc0b
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 months agodpdk: never override devname if set via config 57/40057/4
Peter Morrow [Tue, 5 Dec 2023 10:07:10 +0000 (10:07 +0000)]
dpdk: never override devname if set via config

Even if the device name is specified in the startup config it may
be appended to if the device is a switch domain member. This leads
to unexpected device naming if an explicit device name was requested.

Type: fix
Change-Id: Ib56b4ac41c17008db55dc69497721e3cb7d540c1
Signed-off-by: Peter Morrow <pdmorrow@gmail.com>
5 months agodpdk-cryptodev: fix crypto-dispatch node stats 52/40052/2
Piotr Bronowski [Mon, 4 Dec 2023 14:47:48 +0000 (14:47 +0000)]
dpdk-cryptodev: fix crypto-dispatch node stats

This patch introduces a fix for correcting a counter for the number
of processed vectors in the crypto-dispatch node.

Type: fix

Signed-off-by: Piotr Bronowski <piotrx.bronowski@intel.com>
Change-Id: Icaeb925a352a9ac766652f43c4e752f6727cdeb9

5 months agomisc: fix tracedump `show graph` out-of-buffer 63/40063/4
Dmitry Valter [Tue, 5 Dec 2023 17:16:57 +0000 (17:16 +0000)]
misc: fix tracedump `show graph` out-of-buffer

Use the correct string type for vlib_get_node_by_name. Found by ASAN.

Type: fix
Signed-off-by: Dmitry Valter <d-valter@yandex-team.com>
Change-Id: I679d27050487e013e3320a4c558d78fa60c5e98a

5 months agocrypto-ipsecmb: bump intel-ipsec-mb version to 1.5 77/39977/2
Ranjan Raj [Wed, 29 Nov 2023 05:47:44 +0000 (05:47 +0000)]
crypto-ipsecmb: bump intel-ipsec-mb version to 1.5

This patch update the Intel IPsec-MB lib to v1.5

Type: feature

Change-Id: Ib2b5d28866f52d428d9400318cffcae11f935c3f
Signed-off-by: Ranjan Raj <ranjanx.raj@intel.com>
5 months agovnet: allow format deleted swifidx 78/40078/3
Nathan Skrzypczak [Wed, 6 Dec 2023 16:34:57 +0000 (17:34 +0100)]
vnet: allow format deleted swifidx

This patch prevents the sw interfaces format
function to fail when the interface was deleted.
It also prints the swifindex alongside the 'DELETED'
keyword.

Printing deleted swifindex should not happen, but it is still
helpful to have these safeguards for troubleshooting in the case
invariants get corrupted (e.g. fib entry refcounts, ...)

Type: improvement

Change-Id: I66711049db2eebe0ad17e37c3a260ac81d1e5134
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
5 months agodpdk: bump to DPDK 23.11 67/40067/2
Kai Ji [Tue, 5 Dec 2023 23:38:39 +0000 (23:38 +0000)]
dpdk: bump to DPDK 23.11

This patch bumps DPDK version to 23.11

Type: feature

Change-Id: Id19fa6e2789ffa3264614a011656dfe2303173ab
Signed-off-by: Kai Ji <kai.ji@intel.com>
5 months agotests: tracedump test replace hardcoded value 69/40069/9
hsandid [Wed, 6 Dec 2023 10:14:19 +0000 (11:14 +0100)]
tests: tracedump test replace hardcoded value

Type: fix

Fetch 'pg-input' node index instead
of using a hardcoded value

Change-Id: I1ca27ddb54806530b546085d83e83b880acc4573
Signed-off-by: hsandid <halsandi@cisco.com>
5 months agoiavf: set max_pkt_size even for disabled queues to make i40e PF driver happy 59/40059/1
Damjan Marion [Tue, 5 Dec 2023 12:23:31 +0000 (13:23 +0100)]
iavf: set max_pkt_size even for disabled queues to make i40e PF driver happy

Type: improvement
Change-Id: I3daf6c32888a15c7ef1f32e729c1e23765d14dc6
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 months agol2: resolve l2 rewrite entry 'hit_count' always being 0 bug 43/39943/8
yanlong [Sun, 19 Nov 2023 14:19:42 +0000 (06:19 -0800)]
l2: resolve l2 rewrite entry 'hit_count' always being 0 bug

The hit_count does not implement the corresponding processing logic, and here the missing is fixed

Type: fix
Fixes: missing

Change-Id: I04a8e11d6b48c2a15c371cbeb2467fa89a9d82bb
Signed-off-by: yanlong <dyl_wlc@163.com>
5 months agohttp: fix coverity warning 48/40048/2
Filip Tehlar [Mon, 4 Dec 2023 08:57:00 +0000 (09:57 +0100)]
http: fix coverity warning

Type: fix

Change-Id: I659a67293763a6035cfa64a4057ebf716fe93ab4
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
5 months agoiavf: add missing cfg_change_validate callback 50/40050/2
Damjan Marion [Mon, 4 Dec 2023 14:25:12 +0000 (15:25 +0100)]
iavf: add missing cfg_change_validate callback

Type: fix
Fixes: 47447f1f
Change-Id: I438f5535bc48ca5397b8f5d3fbbd893ca6a511b4
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 months agoiavf: workaround for case when PF driver sends zero for max_mtu 49/40049/2
Damjan Marion [Mon, 4 Dec 2023 12:15:23 +0000 (12:15 +0000)]
iavf: workaround for case when PF driver sends zero for max_mtu

Type: improvement
Change-Id: Ie4b2b958a24cdde8c183b700d864fc6f5b0df08f
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 months agodev: mark API handlers as thread safe 24/40024/2
Damjan Marion [Wed, 29 Nov 2023 13:54:15 +0000 (13:54 +0000)]
dev: mark API handlers as thread safe

Type: improvement
Change-Id: I2acab04ddb6a46a637ed17c683fb37ed7bce3df6
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 months agosession: no segment handle on worker del 45/40045/2
Florin Coras [Sat, 2 Dec 2023 02:47:45 +0000 (18:47 -0800)]
session: no segment handle on worker del

Coverity report.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I3ce06634b30688d2a9581b50d462092daa8b4cac

5 months agovcl: remove perror ldp call 44/40044/2
Florin Coras [Fri, 1 Dec 2023 21:23:35 +0000 (13:23 -0800)]
vcl: remove perror ldp call

Reported by coverity

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Idae1bceb1eeb6dfe0394eed39ced9d09342d201f

5 months agoipsec: should use praddr_ instead of pladdr_ 28/39228/2
Dengfeng Liu [Thu, 13 Jul 2023 12:57:59 +0000 (20:57 +0800)]
ipsec: should use praddr_ instead of pladdr_

Type: fix

Change-Id: I982ef624226807d7c263e3ff83c108f7d31f61f1
Signed-off-by: Dengfeng Liu <liudf0716@gmail.com>
5 months agotests: Added tracedump plugin tests 61/39861/12
adrianvillin [Fri, 10 Nov 2023 11:48:16 +0000 (12:48 +0100)]
tests: Added tracedump plugin tests

Type: test

Change-Id: Ie054924eb5e5b2b146db8d2b63511c8b0400f045
Signed-off-by: adrianvillin <avillin@cisco.com>
5 months agoiavf: limit maximum number of queues to 32 30/40030/2
Damjan Marion [Thu, 30 Nov 2023 17:16:20 +0000 (17:16 +0000)]
iavf: limit maximum number of queues to 32

First genaration of AVF APIs we currently use doesn't support more...

Type: improvement
Change-Id: I1ae27f322403a2b455fcad8b028fa2004b449789
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 months agodev: use the endian reply macro 28/40028/2
Vratko Polak [Thu, 30 Nov 2023 16:42:25 +0000 (17:42 +0100)]
dev: use the endian reply macro

Checkstyle also forces the new indentation.

Type: fix
Fixes: ddf6cec37027547ff7cc61e15bb8080664d41514

Change-Id: Ife96928d6ca30ba94e1c423d557d6ed9d68eca2b
Signed-off-by: Vratko Polak <vrpolak@cisco.com>
5 months agohs-test: add http prom test 21/40021/2
Filip Tehlar [Wed, 29 Nov 2023 11:59:05 +0000 (12:59 +0100)]
hs-test: add http prom test

Type: test

Change-Id: Ia15ecc3cf2c087a6959601ff02e187c32570ff60
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
5 months agosession: no reply on app del worker with sapi 17/40017/2
Florin Coras [Tue, 28 Nov 2023 23:28:16 +0000 (15:28 -0800)]
session: no reply on app del worker with sapi

With socket api, applications should not expect reply after worker del
msg. VCL in particular closes the socket after it enqueues the message.

Found by ASAN.

Type: fix

Signed-off-by: Dmitry Valter <d-valter@yandex-team.com>
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I1be02a0cde6b96a96edb709f3fe30bbc01ff2d24

5 months agovcl: fix init of ldp workers 18/40018/4
Florin Coras [Wed, 29 Nov 2023 00:05:29 +0000 (16:05 -0800)]
vcl: fix init of ldp workers

LDP workers is used as vector but was initialized as a pool. There was
no side effect but ASAN does not properly unpoison memory and this
triggers false used-after-poison crashes.

Type: fix

Signed-off-by: Dmitry Valter <d-valter@yandex-team.com>
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ie769dad0e86ab970de9929800d0a4131f846e70e

5 months agotcp: fix rxt send of new data assert 19/40019/2
Florin Coras [Wed, 29 Nov 2023 07:21:18 +0000 (23:21 -0800)]
tcp: fix rxt send of new data assert

We might have less than 1 mss when attempting write but more after
write, as application could be actively enqueuing more data. Relax
assert.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I54a83c4460f8e022a88758f0ebd7828df711dbb9

5 months agopci: fix MSI-X vector length check 22/40022/1
Damjan Marion [Wed, 29 Nov 2023 12:32:54 +0000 (12:32 +0000)]
pci: fix MSI-X vector length check

Type: fix
Fixes: 38c6191
Change-Id: I7760947986dc56236f2494fb1c8c238321489ef6
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 months agotcp: allow unsent segments less than mss in recovery 11/40011/2
Florin Coras [Tue, 28 Nov 2023 00:03:26 +0000 (16:03 -0800)]
tcp: allow unsent segments less than mss in recovery

During recovery, send unsent data even if less than mss available as
application is not guaranteed to provide more.

This should speed up recovery when all data in flight was lost.

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I7a3c73a0d04d93d51a5910d85450c173c3ad8e93

5 months agotcp: add counter for accepted connections 16/40016/3
Florin Coras [Tue, 28 Nov 2023 19:30:42 +0000 (11:30 -0800)]
tcp: add counter for accepted connections

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I2925134cfcfa36c14b3b69efa892b9b96fce2e6f

5 months agosession: fix asan failure 15/40015/4
Georgy Borodin [Tue, 28 Nov 2023 15:04:27 +0000 (16:04 +0100)]
session: fix asan failure

fix asan failure when params number is less then 3:
functions that are set as format_half_open pointer values have
different number of arguments

Type: fix
Fixes: de9a849a18514f0b09bb5f57a73f6a57ee425c76
Change-Id: I6b6e1adf4ffc0c1ec847613f00fe269af640d42b
Signed-off-by: Georgy Borodin <bor1-go@yandex-team.ru>
5 months agotests: fix default node variant in tests 58/33758/3
Dmitry Valter [Sun, 19 Sep 2021 20:50:57 +0000 (23:50 +0300)]
tests: fix default node variant in tests

Pass a correct form of node variant config in tests

Type: fix
Signed-off-by: d-valter@yandex-team.ru
Change-Id: I8cdc240b18a1664e57a5814d6cd644891c99f515
Fixes: 8800f732f868bf54da8adba05e38bd2477895ca5

5 months agotests: Added NSIM plugin tests 00/39900/15
adrianvillin [Thu, 16 Nov 2023 09:03:00 +0000 (10:03 +0100)]
tests: Added NSIM plugin tests

Type: test

Change-Id: Id621a806b853688ced7c6a38e1a9e5f298d2b97e
Signed-off-by: adrianvillin <avillin@cisco.com>
5 months agotests: refactor pcap file deletion to improve robustness 12/40012/2
Dave Wallace [Tue, 28 Nov 2023 01:23:03 +0000 (20:23 -0500)]
tests: refactor pcap file deletion to improve robustness

Type: test

Change-Id: I504c079126bd8b33c5e217a1b9086788a8c778e5
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
5 months agofib: fix fib_path_create() with drop targets 01/40001/2
Alexander Skorichenko [Fri, 24 Nov 2023 08:59:42 +0000 (09:59 +0100)]
fib: fix fib_path_create() with drop targets

Properly set type
path->fp_type = FIB_PATH_TYPE_SPECIAL
for paths with (path->fp_cfg_flags & FIB_PATH_CFG_FLAG_DROP)

Type: fix

Change-Id: Id61dbcda781d872b878e6a6410c05b840795ed46
Signed-off-by: Alexander Skorichenko <askorichenko@netgate.com>
5 months agotests: Excluded some components from LCOV 10/40010/2
adrianvillin [Mon, 27 Nov 2023 17:44:07 +0000 (18:44 +0100)]
tests: Excluded some components from LCOV

Type: test

Change-Id: I387611cfc361e664eb1e78ae669ba4e3901c4fe6
Signed-off-by: adrianvillin <avillin@cisco.com>
5 months agobfd: fix buffer leak when cannot send periodic packets 97/39997/2
Alexander Chernavin [Thu, 23 Nov 2023 11:36:09 +0000 (11:36 +0000)]
bfd: fix buffer leak when cannot send periodic packets

When a periodic BFD packet cannot be sent because the interface is
disabled, the allocated buffer needs to be freed. This currently will
occur for IPv4 sessions. However, buffers will leak for IPv6 sessions as
in this case, bfd_transport_control_frame() and bfd_transport_udp6()
will not indicate failure.

With this fix, stop always returning success in bfd_transport_udp6() and
start returning the actual return value.

Type: fix
Change-Id: I5fa4d9206e32cccae3053ef24966d80e2022fc81
Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
5 months agotcp: allow multiple rxt rescues during recovery 07/40007/2
Florin Coras [Sat, 25 Nov 2023 17:00:44 +0000 (09:00 -0800)]
tcp: allow multiple rxt rescues during recovery

Type: improvement

Change-Id: Ia8d7cd6ff9b1449d986d514d9556cbf803deb670
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 months agodev: initial set of APIs 99/39999/3
Damjan Marion [Wed, 22 Nov 2023 16:25:55 +0000 (16:25 +0000)]
dev: initial set of APIs

Type: improvement
Change-Id: I9ecbf705d460a1744f36c7005b08097dc58d9522
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 months agodev: fix null dereference of arg list 38/39938/2
Damjan Marion [Thu, 16 Nov 2023 19:14:12 +0000 (19:14 +0000)]
dev: fix null dereference of arg list

Type: fix
Fixes: 69768d9
Change-Id: Iafd3a55634583f2799a81c477ccbf5e53b6f29d0
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 months agoavf: put sentinel at correct place 48/39948/4
Vratko Polak [Wed, 22 Nov 2023 12:39:47 +0000 (13:39 +0100)]
avf: put sentinel at correct place

The previous fix was adding the sentinel before refilling rx,
which gave the NIC time to overwrite it with a new descriptor.

Ticket: VPP-2087
Type: fix
Fixes: 8b4d474abd62c623502ad9a4a279a9b4535ca0c1

Change-Id: I32bde4a763a62fb66c5c3871d9f10af6066e2d47
Signed-off-by: Vratko Polak <vrpolak@cisco.com>
5 months agosession: per app wrk client ct segment handle 46/39946/5
Florin Coras [Mon, 20 Nov 2023 22:46:10 +0000 (14:46 -0800)]
session: per app wrk client ct segment handle

Make sure ct client segment handles do not collide if multi worker
application establishes cut-through sessions to only one server segment
manager.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I905379f9ed73c64d57a826a3e97d53dab3a87517

5 months agovirtio: fix cli parsing for tx-queue-size 72/39872/4
Vratko Polak [Tue, 14 Nov 2023 18:41:11 +0000 (19:41 +0100)]
virtio: fix cli parsing for tx-queue-size

The previous change made CSIT virtio tests fail,
but those tests are not part of trending.

Ticket: VPP-2088
Type: fix
Fixes: a181eaa59bb2ff2784376918e95bbf92e5340db1

Change-Id: If0439a030c051894e07007da9cf0a2e4dc1434c3
Signed-off-by: Vratko Polak <vrpolak@cisco.com>
5 months agosession: add session lookup cli for stats 41/39941/8
Florin Coras [Sat, 18 Nov 2023 00:35:04 +0000 (16:35 -0800)]
session: add session lookup cli for stats

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I96bff47206ef64ea7369ae92e1b9ff1f74dfd71b

5 months agodpdk: fix description for mlx5_pci driver 86/39586/4
Nobuhiro MIKI [Tue, 26 Sep 2023 06:39:28 +0000 (15:39 +0900)]
dpdk: fix description for mlx5_pci driver

This is because mlx5_pci is also compatible with another
series of NICs such as ConnectX-5 and ConnectX-6.

Type: fix
Change-Id: I10f0468bbe36ab61c72fb3dc0aa898f8e2f9e88c
Signed-off-by: Nobuhiro MIKI <nmiki@yahoo-corp.jp>
5 months agosession: always clear rx evt flag on ntf 40/39940/3
Florin Coras [Fri, 17 Nov 2023 05:16:13 +0000 (21:16 -0800)]
session: always clear rx evt flag on ntf

Apps may drain fifos prior to handling of accept notification, e.g.,
vcl session relying on epoll lt mode.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I7d105d35a6bf33c419f4f137a5132e6a5d294fe7

5 months agoipsec: keep esp encrypt pointer and index synced 36/39936/2
Matthew Smith [Thu, 16 Nov 2023 02:27:29 +0000 (02:27 +0000)]
ipsec: keep esp encrypt pointer and index synced

Type: fix

In esp_encrypt_inline(), an index and pointer to the last processed SA
are stored. If the next packet uses the same SA, we defer on updating
counters until a different SA is encountered.

The pointer was being retrieved, then the SA was checked to see if the
packet should be dropped due to no crypto/integ algs, then the index was
updated. If the check failed, we would skip further processing and now
the pointer refers to a different SA than the index. When you have a
batch of packets that are encrypted using an SA followed by a packet
which is dropped for no algs and then more packets to be encrypted using
the original SA, the packets that arrive after the one that was dropped
end up being processed using a pointer that refers to the wrong SA data.
This can result in a segv.

Update the current_sa_index at the same time that the sa0 pointer is
updated.

Signed-off-by: Matthew Smith <mgsmith@netgate.com>
Change-Id: I65f1511a37475b4f737f5e1b51749c0a30e88806

6 months agodev: startup.conf handling improvements 96/39896/4
Damjan Marion [Wed, 15 Nov 2023 21:47:37 +0000 (22:47 +0100)]
dev: startup.conf handling improvements

Type: improvement
Change-Id: I74fb01061b4949d68ec39d0b7d08e6df8dc44b98
Signed-off-by: Damjan Marion <damarion@cisco.com>
6 months agodev: device and port specific args 81/39881/2
Damjan Marion [Mon, 13 Nov 2023 17:33:32 +0000 (17:33 +0000)]
dev: device and port specific args

Type: improvement
Change-Id: I26124a50d8e05d6f01a2e6dbc4bc8183fb5a09c4
Signed-off-by: Damjan Marion <damarion@cisco.com>
6 months agodhcp: api to enable client detect on interface 18/39718/3
Ole Troan [Thu, 19 Oct 2023 07:05:38 +0000 (09:05 +0200)]
dhcp: api to enable client detect on interface

DHCPv4 aka BOOTP is somewhat awkward. A DHCP client
on an interface must receive DHCP packets to
the broadcast address or to a unicast address.
Apparently before it's been assigned to itself.

Add this new API to allow external DHCP clients
enable the DHCP client detect feature per interface.

Type: improvement
Change-Id: If55aac03f25a045496be483940e4f5e7e18885b9
Signed-off-by: Ole Troan <otroan@employees.org>
6 months agomisc: VPP 23.10 Release Notes 51/39751/1
Andrew Yourtchenko [Fri, 20 Oct 2023 09:24:01 +0000 (11:24 +0200)]
misc: VPP 23.10 Release Notes

Type: docs
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Change-Id: Icd40064c06ccc53efba1cd9564613108b999b656
(cherry picked from commit 7c4027fa5e42a8cc7176cd62ab7a0043fb1933ff)