vpp.git
2 years agotests: remove constant argument 00/32500/16
Klement Sekera [Mon, 31 May 2021 14:11:49 +0000 (16:11 +0200)]
tests: remove constant argument

Reduce number of arguments by removing an argument which is only ever
used with same constant value.

Type: refactor
Signed-off-by: Klement Sekera <klement.sekera@gmail.com>
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: I061635b28031d75eb1f853b570e85f6e5a9094df

2 years agotests: fix test-checkstyle-diff if no .py changed 11/35211/3
Klement Sekera [Thu, 3 Feb 2022 16:03:26 +0000 (16:03 +0000)]
tests: fix test-checkstyle-diff if no .py changed

Type: fix
Signed-off-by: Klement Sekera <klement.sekera@gmail.com>
Change-Id: I6d23ff14380b0154f617b3ab7cd1acd5aa45106a

2 years agoprom: add option to set stat name prefix 14/35214/6
Florin Coras [Thu, 3 Feb 2022 23:17:21 +0000 (15:17 -0800)]
prom: add option to set stat name prefix

Type: improvement

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

2 years agohttp: honor max seg len in ptr buffer 13/35213/3
Florin Coras [Thu, 3 Feb 2022 19:48:55 +0000 (11:48 -0800)]
http: honor max seg len in ptr buffer

Type: fix

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

2 years agoip nat: use ip rx sw_if_index in ip-local arc start 41/34441/8
Florin Coras [Wed, 10 Nov 2021 02:29:03 +0000 (18:29 -0800)]
ip nat: use ip rx sw_if_index in ip-local arc start

This also changes the behavior of the nat44-ei hairpinning feature.
Rather then enabling the feature on every nat interface, it is enabled
only on local0.

Type: improvement

Signed-off-by: Filip Varga <fivarga@cisco.com>
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I4e16a83c9e328aa75fc61df508b620ef743ca775

2 years agoprom: basic builtin prometheus stats exporter 60/35160/25
Florin Coras [Tue, 1 Feb 2022 00:16:13 +0000 (16:16 -0800)]
prom: basic builtin prometheus stats exporter

This is a vpp builtin alternative, not a replacement, for the existing
vpp_prometheus_exporter.

The plugin works by registering with http_static as a url handler for
stats.prom and handles requests by scraping the stats segment in the
main thread. It will therefore consume vpp process cpu cycles.

By default the plugin is disabled. To enable, first start the http
static server an then use "prom enable" cli.

Type: feature

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

2 years agobfd: restore the data within the packet after hash verification 74/35174/2
Andrew Yourtchenko [Wed, 2 Feb 2022 12:32:39 +0000 (13:32 +0100)]
bfd: restore the data within the packet after hash verification

The BFD delayed auth change test was failing intermittently within CI.
Debugging has shown it depends on the initial random seed, e.g. the below
will consistently fail:

RND_SEED=1643734669.7126195 TEST='bfd.BFDAuthOnOffTestCase.test_auth_change_key_delayed'

Same thing will happen with:
RND_SEED=1643736595.1363552
RND_SEED=1643722239.8224792

The analysis of the behavior shown that the function that is doing the hash verification,
modifies the content of the packet for the purposes of hash computation.
In case of the auth rollover, this function may be called twice - resulting in the second
comparison to be made with a bogus packet data, thus failing the check and the test.

The above values of random seed are the ones where the test makes it
to the point of this double comparison.

The solution is to restore the data within the packet after the check from the array
where we have copied it into before modifying the packet.

Change-Id: Ibb09beb4b1230032db04527bbf38fa335651866b
Type: fix
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2 years agohttp_static: add support for async tx from handlers 73/35173/6
Florin Coras [Tue, 1 Feb 2022 21:17:13 +0000 (13:17 -0800)]
http_static: add support for async tx from handlers

URL handlers can send data asynchronously if needed.

Type: improvement

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

2 years agogso: remove the assert if packet is geneve or gre encaped 72/35172/1
Mohsin Kazmi [Tue, 1 Feb 2022 19:06:58 +0000 (19:06 +0000)]
gso: remove the assert if packet is geneve or gre encaped

Type: fix

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

2 years agovirtio: coverity woes -- divide by zero 73/34973/3
Steven Luong [Wed, 19 Jan 2022 17:08:27 +0000 (09:08 -0800)]
virtio: coverity woes -- divide by zero

Coverity complains the expression, j % vif->num_txq, may encounter
divide by zero. While there is little chance that vif->num_txq is
zero, it is easy to prevent divide by zero if vif->num_txq is ever
zero.

Type: fix
Fixes: I337ec63d0868f665329d68eadf1744e080b73a0d

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I2e91f296737ce266ab70fffc1f442cc600724fa2

2 years agostats: vpp_get_stats crashes in stat_segment_data_free 42/35142/2
Steven Luong [Fri, 28 Jan 2022 22:12:53 +0000 (14:12 -0800)]
stats: vpp_get_stats crashes in stat_segment_data_free

STAT_DIR_TYPE_EMPTY is not handled. This can happen when the
interface is deleted.

Type: fix

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: Ic1f5a1a0e7005059628d1dde31118d692c1967d8

2 years agonat: memory leak on nat44_plugin_disable 40/35140/2
Steven Luong [Fri, 28 Jan 2022 16:28:04 +0000 (08:28 -0800)]
nat: memory leak on nat44_plugin_disable

We invoke nat_affinity_enable for nat44_plugin_enable.
We need to invoke nat_affinity_disable for nat44_plugin_disable
to free the memory for bihash.

Type: fix
Fixes: I2743f7b1104b627bcc5ef937e3a50655313a26ea

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I9adeb3225136e3fff853c2d5b8f9a30e98ddcf4c

2 years agonat: nat44-ei hairpinning code cleanup 75/34975/2
Filip Varga [Tue, 18 Jan 2022 21:17:07 +0000 (13:17 -0800)]
nat: nat44-ei hairpinning code cleanup

Removing obsolete unused nat44-ei nodes and functions.

Type: refactor
Change-Id: I1e03e283091c3c0d92908d04037cba00a348351a
Signed-off-by: Filip Varga <fivarga@cisco.com>
2 years agoperfmon: Add perfmon maintainer 41/35141/3
Ray Kinsella [Fri, 28 Jan 2022 09:02:10 +0000 (09:02 +0000)]
perfmon: Add perfmon maintainer

Add Ray Kinsella as maintainer of the perfmon plugin. Update maintainers of the
sphinx documentation.

Type: refactor

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I9c05dbed3dcc9909b497df776fa01c52bc048e0f

2 years agotests: correct python usage in virtualenv 53/31953/5
Klement Sekera [Sat, 10 Apr 2021 10:37:04 +0000 (12:37 +0200)]
tests: correct python usage in virtualenv

Use 'python3' for all python calls in virtualenv. Using $(PYTHON_INTERP)
(set to $(PYTHON)) is incorrect when $(PYTHON) contains absolute path
(e.g. '/usr/bin/pypy3') as it uses interpreter outside of virtualenv.

Type: fix
Change-Id: I19878360cfc1ab6a591e09a079b0b69c1a1a58cf
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2 years agoip: reassembly - add a way to disable for forus 94/34994/11
Klement Sekera [Tue, 14 Dec 2021 18:25:11 +0000 (18:25 +0000)]
ip: reassembly - add a way to disable for forus

Add API to disable full reassembly of "forus" packets. Mark packets
passing through ip[4|6]-local nodes with a new buffer flag and check for
that flag in reassembly.

Enable IP6 "forus" full reassembly by default to be consistent with
existing IP4 setting.

Type: improvement
Change-Id: I7067792fcd4304182654237968e4c4d9293c6143
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2 years agoip: fix length calculation in ip6-receive 37/35137/4
Klement Sekera [Fri, 28 Jan 2022 13:16:46 +0000 (13:16 +0000)]
ip: fix length calculation in ip6-receive

Replace unconditional usage of
buffer->total_length_not_including_first_buffer with a logic checking
whether that length is set to a valid value.

Type: fix
Fixes: 17478e4eb81d384f171ca27c9110a051cd434f16
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: I161d0957d62cc23826edd821aa5560bcfc5c1a33

2 years agotests: make VPP_BUILD_DIR to point to correct dir 42/32442/9
Klement Sekera [Tue, 25 May 2021 19:15:36 +0000 (21:15 +0200)]
tests: make VPP_BUILD_DIR to point to correct dir

Make VPP_BUILD_DIR hold the correct value and adjust paths where
necessary.

Type: refactor
Change-Id: I5bc60666c04919956bf26badaf1ee1f1b188ef65
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2 years agotests: support skipping to test method with STEP 13/35113/6
Klement Sekera [Fri, 28 Jan 2022 11:31:01 +0000 (11:31 +0000)]
tests: support skipping to test method with STEP

Allow entering a test name on stack trace window with STEP=y option
instead of a number. This allows to run a whole suite and skip all tests
until a particular test is hit.

Type: improvement
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: I23e45f8022b82545365b8921390e0e106e02b39c

2 years agocnat: maglev fixes & improvements 72/35072/5
Nathan Skrzypczak [Mon, 24 Jan 2022 16:10:41 +0000 (17:10 +0100)]
cnat: maglev fixes & improvements

This fixes the maglev logic which previously
included a wrong simplication.
It moves the maglev logic to its own file,
and adds a test function in the debug cli.

Type: improvement

Change-Id: I2790ae2a26fc1c5739ff02f41d436bfcafd5b380
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2 years agosnort: feature support on interface output 95/34995/3
Sivaprasad Tummala [Fri, 21 Jan 2022 21:39:18 +0000 (03:09 +0530)]
snort: feature support on interface output

support snort plugin on interface output via ip4-output fa

Type: feature

Signed-off-by: Sivaprasad Tummala <Sivaprasad.Tummala@intel.com>
Change-Id: I2d5e7d0719c03f88806b12debfe596675dbd66c1

2 years agoperfmon: topdown level 1 and 2 for icx 12/35112/4
Ray Kinsella [Thu, 27 Jan 2022 09:55:02 +0000 (09:55 +0000)]
perfmon: topdown level 1 and 2 for icx

Topdown level 1 and 2 for Intel Ice Lake (ICX). Limiting topdown support
to THREAD for the moment on Ice Lake, as NODE support is still
unreliable. Also removing Topdown Level 1 from Sapphire Rapids onwards,
as Topdown LeveL 2 also shows Level 1 on Sapphire, and it reduces the
overall number of bundles.

Type: improvement

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: Iaa68b711dc8b6fb1090880b411debadb3c37f8bc

2 years agoperfmon: fix init of bundles with pseudo events 36/35136/3
Ray Kinsella [Fri, 28 Jan 2022 05:01:52 +0000 (05:01 +0000)]
perfmon: fix init of bundles with pseudo events

Previously Linux pseudo events were being counted as multiple fixed
events, such that a bundle with pseudo events could exceed the number of
available fixed counters. Reworked to ignore pseudo events in the
accounting for the moment.

Type: fix
Fixes: 0024e53ad
Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: Ic938f8266fd04d7731afbd02e261c61ef22a8522

2 years agoperfmon: check for duplicates after other checks 15/35115/3
Ray Kinsella [Fri, 28 Jan 2022 04:59:00 +0000 (04:59 +0000)]
perfmon: check for duplicates after other checks

Move checking for duplicate bundle names after the other checks.

Type: fix

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I7fed5be758814e166eb8756b3df090130ac13bfd

2 years agohttp_static: incorporate builtinurl plugin 43/35143/6
Florin Coras [Fri, 28 Jan 2022 23:26:39 +0000 (15:26 -0800)]
http_static: incorporate builtinurl plugin

External handlers can still be registered via hss_register_url_handler
but url handlers must be enabled when server is created.

builtinurl plugin to be removed in a future patch

Type: refactor

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

2 years agolinux-cp: check if libmnl headers are present 44/35144/5
Florin Coras [Sat, 29 Jan 2022 01:41:54 +0000 (17:41 -0800)]
linux-cp: check if libmnl headers are present

Type: improvement

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

2 years agoperfmon: topdown backend bound core bundle 39/35139/2
Ray Kinsella [Fri, 28 Jan 2022 08:56:57 +0000 (08:56 +0000)]
perfmon: topdown backend bound core bundle

Add a bundle to measure topdown backend bound core cycles, will indicate if any
given execution port has contention.

Type: improvement

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I37d1b38c101ac42d51c10fa4452b822d34b729c9

2 years agomisc: remove mbedtls from dependencies 45/35145/4
Florin Coras [Sat, 29 Jan 2022 02:35:12 +0000 (18:35 -0800)]
misc: remove mbedtls from dependencies

Type: make

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

2 years agolinux-cp: Fix coverity issue 38/35138/3
Pim van Pelt [Fri, 28 Jan 2022 14:29:21 +0000 (14:29 +0000)]
linux-cp: Fix coverity issue

Type: fix

Possible negative return in open(), do not use curr_ns_fd if it is
negative.  Addresses Coverity issue 248535

Signed-off-by: Pim van Pelt <pim@ipng.nl>
Change-Id: I8429ede0f1fe9fe6619e3c4dbd83adb620ea62c2

2 years agomisc: vppctl - fix coverity warning 25/34525/4
Klement Sekera [Tue, 16 Nov 2021 11:14:40 +0000 (12:14 +0100)]
misc: vppctl - fix coverity warning

Calculate space left to silence coverity.

Type: fix
Fixes: 31f192434660
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: I9cd2e91ce74444e2625bf86721a8d3e44bf6afdd

2 years agomisc: vppctl - fix coverity warning 26/34526/6
Klement Sekera [Tue, 16 Nov 2021 11:19:26 +0000 (12:19 +0100)]
misc: vppctl - fix coverity warning

Check that provided path fits into defined buffer. Don't write too many
bytes to avoid having an unterminated string.

Type: fix
Fixes: 31f192434660
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: I1ea8b6d6a3474c032e542b6980ed14bac72093a8

2 years agolinux-cp: Linux Control Plane Netlink Listener 22/31122/21
Neale Ranns [Fri, 5 Feb 2021 09:04:35 +0000 (09:04 +0000)]
linux-cp: Linux Control Plane Netlink Listener

Type: feature

please see FEATURE.yaml for details.

Signed-off-by: Neale Ranns <nranns@cisco.com>
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
Signed-off-by: Jon Loeliger <jdl@netgate.com>
Signed-off-by: Pim van Pelt <pim@ipng.nl>
Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: I6255fd9953d0b03e6b4fe75b67a6845a7c206f74
Signed-off-by: Pim van Pelt <pim@ipng.nl>
2 years agobuild: fix compilation on OpenSSL 3.0 98/35098/3
Damjan Marion [Tue, 25 Jan 2022 22:11:47 +0000 (23:11 +0100)]
build: fix compilation on OpenSSL 3.0

So far by suppressing depreciation messages, as there was no transition
period.

Type: make
Change-Id: I9887613fd71a22bf11bf22a04c129aca4a16867f
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agovppinfra: sparse_vec_free free should free the sparse_vec_header not the embedded... 60/34860/4
Neale Ranns [Sun, 9 Jan 2022 13:27:04 +0000 (13:27 +0000)]
vppinfra: sparse_vec_free free should free the sparse_vec_header not the embedded vec_header_t

Type: fix

Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: Ie9532543c4d4439beec8ce097eafa34588ad1266

2 years agoperfmon: frontend and backend boundness bundles 08/35108/3
Ray Kinsella [Wed, 12 Jan 2022 04:47:27 +0000 (04:47 +0000)]
perfmon: frontend and backend boundness bundles

Renamed memory stalls to topdown backend-bound-mem, added topdown
frontend-bound-latency and frontend-bound-bandwidth.

Type: improvement

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I70f42b6b63fe2502635cad4aed4271e2bbdda5f1

2 years agoperfmon: prune bundles by available pmu counters 94/34594/10
Ray Kinsella [Fri, 26 Nov 2021 14:57:35 +0000 (14:57 +0000)]
perfmon: prune bundles by available pmu counters

Prune perfmon bundles that exceed the number of available pmu counters.

Type: improvement

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I70fec26bb8ca915f4b980963e06c2e43dfde5a23

2 years agohttp_static: code cleanup 04/35104/9
Florin Coras [Thu, 27 Jan 2022 00:28:58 +0000 (16:28 -0800)]
http_static: code cleanup

Type: refactor

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

2 years agoperfmon: add cli to show perf config 93/34593/3
Ray Kinsella [Fri, 26 Nov 2021 09:02:20 +0000 (09:02 +0000)]
perfmon: add cli to show perf config

Added a cli to show Linux perf config for a give perfmon bundle. This
makes it easier to format Linux perf commands for next level analysis.

Type: improvement

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I9adafa7d441b72120390d186e3c8f884b1bc9828

2 years agohsa: cleanup and rename http test server 99/35099/6
Florin Coras [Wed, 26 Jan 2022 08:15:03 +0000 (00:15 -0800)]
hsa: cleanup and rename http test server

- cleanup data structures, functions and cli
- remove option to return static html. For similar results, use
http static server
- rename to http_cli.c as it better describes what the app does

Type: refactor

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

2 years agohttp_static: refactor to use http transport 68/35068/13
Florin Coras [Tue, 25 Jan 2022 02:46:03 +0000 (18:46 -0800)]
http_static: refactor to use http transport

Type: refactor

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

2 years agohttp: generalize buffer implementation 63/35063/12
Florin Coras [Mon, 24 Jan 2022 20:47:50 +0000 (12:47 -0800)]
http: generalize buffer implementation

And add support for passing of pointers

Type: improvement

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

2 years agodpdk: not having cryptodev resources should not produce warnings 01/35101/1
Damjan Marion [Wed, 26 Jan 2022 10:07:47 +0000 (11:07 +0100)]
dpdk: not having cryptodev resources should not produce warnings

Type: fix
Change-Id: Ifb2e4d93dcf8648b1bd66f4c0ee937295683bd87
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agovppinfra: add support for mask_compare for u64 66/35066/3
Mohsin Kazmi [Mon, 24 Jan 2022 23:19:29 +0000 (23:19 +0000)]
vppinfra: add support for mask_compare for u64

Type: improvement

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

2 years agohttp hsa: avoid extra space in request 97/35097/2
Florin Coras [Tue, 25 Jan 2022 19:41:58 +0000 (11:41 -0800)]
http hsa: avoid extra space in request

Type: improvement

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

2 years agoapi: vapi: honor non-blocking setting 64/35064/3
Klement Sekera [Mon, 24 Jan 2022 21:37:09 +0000 (21:37 +0000)]
api: vapi: honor non-blocking setting

Pass correct conditional based on how vapi is configured wrt blocking.

Type: fix
Fixes: 3fca567ff438145e28dd1318ad5b1734c1091257
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: I47adca19f104d7a758cb2940e93c9fd8c7cc9bfa

2 years agoip: reassembly - fix missing ip6 owner thread init 65/35065/2
Klement Sekera [Mon, 24 Jan 2022 22:30:04 +0000 (22:30 +0000)]
ip: reassembly - fix missing ip6 owner thread init

Initialize ip6 memory owner thread index in reassembly context to avoid
unnecessary handovers.

Type: fix
Fixes: 630ab5846bceddf8d663e9f488a2dc0378949827
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: I2996caf1f82a0649c97d481b74dce24a96dce326

2 years agobonding: refactor bonding hash functions to vnet/hash 80/34680/3
Steven Luong [Fri, 3 Dec 2021 20:05:45 +0000 (12:05 -0800)]
bonding: refactor bonding hash functions to vnet/hash

- move bonding hash functions to vnet/hash
- register the corresponding hash function when the bond interface
is created
- remove floating point vec256 usage
- split bond_tx_inline into bond_tx_hash and bond_tx_no_hash

Type: refactor

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I1698023c48470290d11c9b2bd00996eee9aa079d

2 years agohttp: fix rescheduling when transport fifo full 69/35069/2
Florin Coras [Tue, 25 Jan 2022 07:30:08 +0000 (23:30 -0800)]
http: fix rescheduling when transport fifo full

Type: fix

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

2 years agowireguard: fix passing argument 59/35059/1
Gabriel Oginski [Mon, 24 Jan 2022 13:31:45 +0000 (13:31 +0000)]
wireguard: fix passing argument

Fixed coverity-issue CID 248456.
Originally passing argument of type "uint64_t *" to function:
"memcopy_s_inline".
This patch fixes the problem by changing type of passing argument and
make a portable assumption.

Type: fix

Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Change-Id: I17e4583a05ea1263e4d8a4acc9949454e5fd92c0

2 years agonat: TCP state tracking based on RFC 7857/RFC 6146 77/34877/15
Klement Sekera [Mon, 10 Jan 2022 21:57:27 +0000 (21:57 +0000)]
nat: TCP state tracking based on RFC 7857/RFC 6146

Implement proper state machine based on above RFCs. ACKs to SYNs/FINs
are no longer required/tracked. This is more friendly to peers and
accounts for lost packets and retransmits.

This change also means that all traffic is translated and forwarded
while in transitory timeout, which helps delivering e.g. retransmitted
FINs, FINACKs and other messages.

Also support reopening a session in transitory timeout after seeing both
FINs by seeing both SYNs again. This helps quick connection
reestablishment if the peers want to.

Type: improvement
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Signed-off-by: Miklos Tirpak <miklos.tirpak@gmail.com>
Change-Id: Ibf521c79463472db97e593bfa02b32b4a06dfd2a

2 years agodpdk-cryptodev: add support chacha20-poly1305 62/34662/8
Gabriel Oginski [Thu, 25 Nov 2021 08:21:41 +0000 (08:21 +0000)]
dpdk-cryptodev: add support chacha20-poly1305

Originally cryptodev doesn't support chacha20-poly1305 with aad length
0.

This patch add support in cryptodev for chacha20-poly1305 with aad
length 0. This length is using in Wireguard.

Type: improvement

Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Change-Id: I0608920bb557d7d071e7f9f37c80cf50bad81dcc

2 years agopolicer: fix memory leak 03/34803/3
Leung Lai Yung [Mon, 27 Dec 2021 04:14:20 +0000 (04:14 +0000)]
policer: fix memory leak

Type: fix

policer_add_del does not free "clib_error_t*" when it is not null.

Signed-off-by: Leung Lai Yung <benkerbuild@gmail.com>
Change-Id: I00ad8e53797e46adeb1819856262bb9f3c068c63

2 years agosr: fix coverity warning 44/34244/4
Klement Sekera [Tue, 26 Oct 2021 09:35:48 +0000 (11:35 +0200)]
sr: fix coverity warning

Remove dead code. Pool element cannot be NULL.

Type: fix
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: I7812efdcdc414af8352474c4e527c878d2e2c459

2 years agoip6-nd: fix coverity warning 43/34243/2
Klement Sekera [Tue, 26 Oct 2021 09:33:30 +0000 (11:33 +0200)]
ip6-nd: fix coverity warning

Restructure code to avoid NULL dereference.

Type: fix
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: If3a4319f1b93af272b7b315a9b15ba4ee1f8e7ae

2 years agovppinfra: fix compilation on riscv 72/34972/2
Damjan Marion [Wed, 19 Jan 2022 17:13:34 +0000 (18:13 +0100)]
vppinfra: fix compilation on riscv

Type: fix
Change-Id: I2bc58a711c9429d7989bfd0bfccd289d43fc35d0
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agosession: separate transports from apps in show cli 36/35036/2
Florin Coras [Sat, 22 Jan 2022 21:27:21 +0000 (13:27 -0800)]
session: separate transports from apps in show cli

Type: improvement

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

2 years agosession: update time for list of subscribers 87/34987/2
Florin Coras [Fri, 21 Jan 2022 02:10:26 +0000 (18:10 -0800)]
session: update time for list of subscribers

Instead of constantly scanning all transport vfts for update time
functions, build list at transport enable time.

Type: improvement

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

2 years agowireguard: add async mode for decryption packets 61/34661/5
Gabriel Oginski [Wed, 17 Nov 2021 10:27:00 +0000 (10:27 +0000)]
wireguard: add async mode for decryption packets

Originally wireguard doesn't support async mode for decryption packets.

This patch add async mode for decryption in wireguard.
In addition, it contains some performance improvement such as
prefetching packet header and reducing the number of current time
function calls.

Type: improvement

Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Change-Id: Ieba6ae0078f3ff140c05b517891afb57232b3b7d

2 years agowireguard: add async mode for encryption packets 60/34660/5
Gabriel Oginski [Wed, 10 Nov 2021 07:59:56 +0000 (07:59 +0000)]
wireguard: add async mode for encryption packets

Originally wireguard doesn't support async mode for encryption packets.

This patch add async mode for encryption in wireguard and also adds
support chacha20-poly1305 algorithm in cryptodev for async handler.
In addition it contains new command line to activate async mode for wireguard:
  set wireguard async mode on|off

and also add new command to check active mode for wireguard:
  show wireguard mode

Type: improvement

Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Change-Id: I141d48b42ee8dbff0112b8542ab5205268089da6

2 years agohsa: refactor test http server to use http proto 59/34959/18
Florin Coras [Tue, 18 Jan 2022 22:10:19 +0000 (14:10 -0800)]
hsa: refactor test http server to use http proto

Type: refactor

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

2 years agofib: missing include 85/34985/1
Damjan Marion [Thu, 20 Jan 2022 17:45:39 +0000 (18:45 +0100)]
fib: missing include

Type: fix
Change-Id: Idefded3443b383ba916a66051b003aac106af8e8
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agowireguard: add burst mode 24/34324/11
Gabriel Oginski [Thu, 4 Nov 2021 07:23:08 +0000 (07:23 +0000)]
wireguard: add burst mode

Originally wireguard does packet by packet encryption and decryption.

This patch adds burst mode for encryption and decryption packets. In
addition, it contains some performance improvement such as prefetching
packet header and reducing the number of current time function calls.

Type: improvement

Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Change-Id: I04c7daa9b6dc56cd15c789661a64ec642b35aa3f

2 years agodpdk: fix compilation for DPDK < 21.11 80/34980/2
Benoît Ganne [Wed, 19 Jan 2022 17:26:43 +0000 (18:26 +0100)]
dpdk: fix compilation for DPDK < 21.11

Type: fix

Change-Id: Ic5b74fb7a8e479e8cdccbb6a564ff3fdd299455c
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2 years agohttp: add http protocol plugin 04/34904/26
Florin Coras [Thu, 13 Jan 2022 19:59:44 +0000 (11:59 -0800)]
http: add http protocol plugin

Basic HTTP/1.1 server side implementation.

Type: feature

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

2 years agosvm: update number of segments in svm_fifo_segments 61/34961/3
Florin Coras [Wed, 19 Jan 2022 04:51:08 +0000 (20:51 -0800)]
svm: update number of segments in svm_fifo_segments

In addition to returning the number of bytes also update the number of
segments to reflect the number used.

Type: improvement

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

2 years agosvm: fix return for partial segment enqueue 60/34960/3
Florin Coras [Tue, 18 Jan 2022 22:11:11 +0000 (14:11 -0800)]
svm: fix return for partial segment enqueue

Type: fix

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

2 years agomisc: Initial 22.06-rc0 commit 67/34967/1 v22.06-rc0
Andrew Yourtchenko [Wed, 19 Jan 2022 12:34:15 +0000 (13:34 +0100)]
misc: Initial 22.06-rc0 commit

Type: docs
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Change-Id: I6b56d2cc785b505e77df0d24a1f441a4c09dc9a8

2 years agodpdk: add qat gen4-b device support 58/34958/2
Fan Zhang [Tue, 18 Jan 2022 15:51:21 +0000 (15:51 +0000)]
dpdk: add qat gen4-b device support

Type: feature

This patch adds the GEN4-b support to DPDK Cryptodev PMD and
fixes a problem on its raw api AEAD enqueue.

Signed-off-by: Fan Zhang <roy.fan.zhang@intel.com>
Change-Id: I3a1a9b0ae51a5725ce9d5265a059e26ceb16c49e

2 years agodpdk: limit number of TX queues to max supported 35/34935/2
Damjan Marion [Tue, 18 Jan 2022 12:42:24 +0000 (13:42 +0100)]
dpdk: limit number of TX queues to max supported

Also improve logging....

Type: fix
Change-Id: I3d3aee52cd45e59ecd6ce13bd516c66559638fec
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agovlib: allow bigger scalar data size 57/34957/2
Damjan Marion [Tue, 18 Jan 2022 15:24:23 +0000 (16:24 +0100)]
vlib: allow bigger scalar data size

Type: improvement
Change-Id: I1031c6ce80d90814edda7b52b11039874b95714f
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agomisc: fix coverity warnings 56/34956/2
Dave Barach [Tue, 18 Jan 2022 13:52:47 +0000 (08:52 -0500)]
misc: fix coverity warnings

Type: fix

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: I8ea0193ebb2a721a0582451ffd64c4063ac6d233

2 years agolinux-cp: fix possible null deref 32/34932/2
Pim van Pelt [Tue, 18 Jan 2022 13:30:52 +0000 (13:30 +0000)]
linux-cp: fix possible null deref

Found by coverity as defect id 243763

Signed-off-by: Pim van Pelt <pim@ipng.nl>
Type: fix
Change-Id: Idbada5528a1f2625f6498072d538edf306268b6d

2 years agovirtio: remove admin-up flag during interface creation 33/34933/2
Mohsin Kazmi [Tue, 18 Jan 2022 12:53:57 +0000 (13:53 +0100)]
virtio: remove admin-up flag during interface creation

Type: fix

During the interface creation time, (by default) admin-up
flag is locally set for tap and virtio interfaces.
While, in VPP the state of these interfaces are still
admin-down. User needs to explicitly call
'set interface state <interface-name> up' to admin-up the
newly created tap or virtio interface(s) in VPP. So, this
behavior is inconsistent.

This patch fixes the issue to have consistent behavior
for given interface between local and global administration
state.

Change-Id: Ifd8904a09fbdbe7b386874ac3231dc0527064518
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2 years agosrv6-mobile: Fix the coverity issue 31/34931/2
Tetsuya Murakami [Tue, 18 Jan 2022 11:43:07 +0000 (03:43 -0800)]
srv6-mobile: Fix the coverity issue

Type: fix

Signed-off-by: Tetsuya Murakami <tetsuya.mrk@gmail.com>
Change-Id: I35c36401ce3ab59900be59a9abddba66f6399978

2 years agovnet: distinguish between max_frame_size and MTU 28/34928/4
Damjan Marion [Mon, 17 Jan 2022 13:49:17 +0000 (14:49 +0100)]
vnet: distinguish between max_frame_size and MTU

Type: improvement
Change-Id: I3659de6599f402c92e3855e3bf0e5e3388f2bea0
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agoipsec: IPSec interface correct drop w/ no protection 69/34869/3
Neale Ranns [Mon, 10 Jan 2022 10:38:43 +0000 (10:38 +0000)]
ipsec: IPSec interface correct drop w/ no protection

Type: improvement

When an IPSec interface is first constructed, the end node of the feature arc is not changed, which means it is interface-output.
This means that traffic directed into adjacencies on the link, that do not have protection (w/ an SA), drop like this:

...
00:00:01:111710: ip4-midchain
  tx_sw_if_index 4 dpo-idx 24 : ipv4 via 0.0.0.0 ipsec0: mtu:9000 next:6 flags:[]
  stacked-on:
    [@1]: dpo-drop ip4 flow hash: 0x00000000
  00000000: 4500005c000100003f01cb8cac100202010101010800ecf40000000058585858
  00000020: 58585858585858585858585858585858585858585858585858585858
00:00:01:111829: local0-output
  ipsec0
  00000000: 4500005c000100003f01cb8cac100202010101010800ecf40000000058585858
  00000020: 5858585858585858585858585858585858585858585858585858585858585858
  00000040: 58585858585858585858585858585858585858585858585858585858c2cf08c0
  00000060: 2a2c103cd0126bd8b03c4ec20ce2bd02dd77b3e3a4f49664
00:00:01:112017: error-drop
  rx:pg1
00:00:01:112034: drop
  local0-output: interface is down

although that's a drop, no packets should go to local0, and we want all IPvX packets to go through ipX-drop.

This change sets the interface's end-arc node to the appropriate drop node when the interface is created, and when the last protection is removed.
The resulting drop is:

...
00:00:01:111504: ip4-midchain
  tx_sw_if_index 4 dpo-idx 24 : ipv4 via 0.0.0.0 ipsec0: mtu:9000 next:0 flags:[]
  stacked-on:
    [@1]: dpo-drop ip4 flow hash: 0x00000000
  00000000: 4500005c000100003f01cb8cac100202010101010800ecf40000000058585858
  00000020: 58585858585858585858585858585858585858585858585858585858
00:00:01:111533: ip4-drop
    ICMP: 172.16.2.2 -> 1.1.1.1
      tos 0x00, ttl 63, length 92, checksum 0xcb8c dscp CS0 ecn NON_ECN
      fragment id 0x0001
    ICMP echo_request checksum 0xecf4 id 0
00:00:01:111620: error-drop
  rx:pg1
00:00:01:111640: drop
  null-node: blackholed packets

Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: I7e7de23c541d9f1210a05e6984a688f1f821a155

2 years agointerface: improve MTU handling 43/34843/12
Damjan Marion [Thu, 6 Jan 2022 20:14:08 +0000 (21:14 +0100)]
interface: improve MTU handling

 - per hw-interface-class handlers
 - ethernet set_mtu callback
 - driver can now refuse MTU change

Type: improvement
Change-Id: I3d37c9129930ebec7bb70caf4263025413873048
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agovnet: introduce vnet_error() 18/34918/2
Damjan Marion [Sun, 16 Jan 2022 21:47:55 +0000 (22:47 +0100)]
vnet: introduce vnet_error()

Decouples vnet return values from API return codes.

New vnet_error() creates vnet_error_t whicgh contains both vnet function
return value and return string.

vnet_api_error() converts vlib_error_t constructed with vnet_error() to
API return value.

Type: improvement
Change-Id: I17042954d48c010150fc1dfc5fce9330e8149e87
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agovppinfra: bitops cleanup 16/34916/5
Damjan Marion [Wed, 12 Jan 2022 23:28:14 +0000 (00:28 +0100)]
vppinfra: bitops cleanup

Type: refactor
Change-Id: I7fa113e924640f9d798c1eb6ae64b9c0a9e2104c
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agomactime: fix memory leak 17/34917/1
Dave Barach [Sat, 15 Jan 2022 16:30:45 +0000 (11:30 -0500)]
mactime: fix memory leak

Type: fix

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: I1ef5cb250ac1e35b9a5003597eda3d54d2e5ca73

2 years agodpdk: refactor device setup 13/34813/12
Damjan Marion [Wed, 12 Jan 2022 23:28:14 +0000 (00:28 +0100)]
dpdk: refactor device setup

Type: improvement
Change-Id: I9772088bca176fd0fdb162677ec55c59aa8f3adf
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: fix burst function output 07/34907/1
Damjan Marion [Fri, 14 Jan 2022 10:57:40 +0000 (11:57 +0100)]
dpdk: fix burst function output

Type: fix
Fixes: 65105c95f
Change-Id: I8dee4b560a49891f954d7eb8e79ea535cedeaa88
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agocrypto-ipsecmb: bump to ipsecmb v1.1 05/34905/2
Marcel Cornu [Thu, 13 Jan 2022 23:48:54 +0000 (23:48 +0000)]
crypto-ipsecmb: bump to ipsecmb v1.1

Type: feature

This patch bumps ipsecmb library version from 1.0 to 1.1

Signed-off-by: Marcel Cornu <marcel.d.cornu@intel.com>
Change-Id: I9851fef2944a6e213d97039bb6dd48cc0df1e4b4

2 years agohsa: echo clients connect improvements 02/34902/3
Florin Coras [Thu, 13 Jan 2022 07:01:29 +0000 (23:01 -0800)]
hsa: echo clients connect improvements

Do burst of connects with barrier held.

Type: improvement

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

2 years agohsa: cleanup echo client app 01/34901/2
Florin Coras [Thu, 13 Jan 2022 01:59:31 +0000 (17:59 -0800)]
hsa: cleanup echo client app

Type: refactor

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

2 years agohsa: allow large segments for echo apps 95/34895/3
Florin Coras [Wed, 12 Jan 2022 18:32:52 +0000 (10:32 -0800)]
hsa: allow large segments for echo apps

Type: improvement

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

2 years agodpdk: bump to DPDK v21.11 05/34705/11
Damjan Marion [Tue, 11 Jan 2022 22:21:08 +0000 (23:21 +0100)]
dpdk: bump to DPDK v21.11

Type: feature

This patch bumps dpdk version from 21.08 to 21.11

Change-Id: Id37fdba75f1ea4f4eac3c92226f3b1c539e1daca
Signed-off-by: Dastin Wilski <dastin.wilski@gmail.com>
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: improve logging 94/34894/4
Damjan Marion [Wed, 12 Jan 2022 17:46:29 +0000 (18:46 +0100)]
dpdk: improve logging

Type: improvement
Change-Id: If61d7409ff14b9f771c1dc8ec9f35e179cea7a28
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: update packet offload flags 96/34896/1
Damjan Marion [Wed, 12 Jan 2022 18:17:26 +0000 (19:17 +0100)]
dpdk: update packet offload flags

Type: improvement
Change-Id: Ib2c55dd2a246a690b2089f5c0b88508f732281f2
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agosession: pass tx buffers in bulk to transports 38/31938/15
Florin Coras [Fri, 9 Apr 2021 02:10:07 +0000 (19:10 -0700)]
session: pass tx buffers in bulk to transports

Type: improvement

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

2 years agoperfmon: skipping bundle message 91/34891/2
Ray Kinsella [Wed, 12 Jan 2022 06:15:34 +0000 (06:15 +0000)]
perfmon: skipping bundle message

Change the skipping bundle message to debug

Type: refactor

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I942ff72bd9c26ccad923442fdedddf22ba75e117

2 years agodpdk: postpone updating runtime data 92/34892/1
Damjan Marion [Wed, 12 Jan 2022 13:09:01 +0000 (14:09 +0100)]
dpdk: postpone updating runtime data

This prevents crash due to worker tread accessing device data
while device vector is growing.

Type: fix
Change-Id: I5cf9f53ddbe97fe52db8fd431ea7c0e480f3d4bc
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: use blunt force to skip irrelevant and confusing logs 89/34889/2
Damjan Marion [Wed, 12 Jan 2022 10:13:24 +0000 (11:13 +0100)]
dpdk: use blunt force to skip irrelevant and confusing logs

Type: improvement
Change-Id: I2cd37f0c1a1ed33438bfa4b7590e5609e5094fc8
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: always display burst function name 88/34888/2
Damjan Marion [Wed, 12 Jan 2022 09:52:14 +0000 (10:52 +0100)]
dpdk: always display burst function name

Also change the way how we dig function pointer so it works with dpdk
21.11+

Type: improvement
Change-Id: I38d5909eea9c2893651710bd45057b1635aa7b37
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agoip: coverity illegal access in ip6_ext_header_walk 82/34882/2
Ole Troan [Tue, 11 Jan 2022 15:08:23 +0000 (16:08 +0100)]
ip: coverity illegal access in ip6_ext_header_walk

*** CID 243670:  Memory - illegal accesses  (OVERRUN)
/src/vnet/ip/ip6_packet.h: 713 in ip6_ext_header_walk()
CID 243670:  Memory - illegal accesses  (OVERRUN)
Overrunning array "res->eh" of 4 4-byte elements at
element index 5 (byte offset 23) using index "i" (which evaluates to 5).

Type: fix
Fixes: 03092c1
Change-Id: I27e0435cf10534f3b41e11bf7a5629b5428b0651
Signed-off-by: Ole Troan <ot@cisco.com>
2 years agodpdk-cryptodev: run dequeue again in case of interrupt mode being used 80/34780/4
Dastin Wilski [Tue, 21 Dec 2021 08:51:52 +0000 (08:51 +0000)]
dpdk-cryptodev: run dequeue again in case of interrupt mode being used

Type: fix

Change-Id: I7aa172e58c970c4971db6ef2ff5b199b7f3c0b99
Signed-off-by: Dastin Wilski <dastin.wilski@gmail.com>
2 years agocrypto: omit loop iteration 85/34885/1
Dastin Wilski [Wed, 12 Jan 2022 08:28:45 +0000 (09:28 +0100)]
crypto: omit loop iteration

This fix adds check that will omit loop iteration
in case dequeue handler is zero.

Type: fix

Signed-off-by: Dastin Wilski <dastin.wilski@gmail.com>
Change-Id: I7526e3fe7d8c8da9662b4e9204efd5e2d8be1908

2 years agohsa: allow use of default port for vcl test apps 84/34884/2
Florin Coras [Tue, 11 Jan 2022 21:58:54 +0000 (13:58 -0800)]
hsa: allow use of default port for vcl test apps

Type: improvement

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

2 years agolinux-cp: Add VPP->Linux synchronization 09/33709/14
Pim van Pelt [Thu, 9 Sep 2021 17:53:09 +0000 (17:53 +0000)]
linux-cp: Add VPP->Linux synchronization

Part 1 -- notes in https://ipng.ch/s/articles/2021/08/13/vpp-2.html
Add the ability for VPP to copy out (sync) its state from the dataplane
to Linux Interface Pairs, when they exist. Gated by a configuration
flag (linux-cp { lcp-sync }), and by a CLI option to toggle on/off,
synchronize the following events:

- Interface state changes
- Interface MTU changes
- Interface IPv4/IPv6 address add/deletion

In VPP, subints can have any link state and MTU, orthogonal to their
phy. In Linux, setting admin-down on a phy forces its children to be
down as well. Also, in Linux, MTU of children must not exceed that of
the phy. Add a state synchronizer which walks over phy+subints to
ensure Linux and VPP end up in the same consistent state.

Part 2 -- notes in https://ipng.ch/s/articles/2021/08/15/vpp-3.html
Add the ability for VPP to autocreate sub-interfaces of existing Linux
Interface pairs. Gated by a configuration flag
(linux-cp { lcp-auto-subint }), and by a CLI option to toggle on/off,
synchronize the following event:

- Sub-interface creation (dot1q, dot1ad, QinQ and QinAD)

A few other changes:
- Add two functions into netlink.[ch] to delete ip4 and ip6 addresses.
- Remove a spurious logline (printing MTU) in netlink.c.
- Resolve a TODO around vnet_sw_interface_supports_addressing()

Type: improvement
Signed-off-by: Pim van Pelt <pim@ipng.nl>
Change-Id: I34fc070e80af4013be58d7a8cbf64296cc760e4e
Signed-off-by: Pim van Pelt <pim@ipng.nl>
2 years agotls: ssl close only after all data drained 75/34875/3
Florin Coras [Mon, 10 Jan 2022 17:15:41 +0000 (09:15 -0800)]
tls: ssl close only after all data drained

Type: fix

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