vpp.git
14 months agoipsec: fix AES CBC IV generation (CVE-2022-46397) 52/38152/1 stable/2202
Benoît Ganne [Tue, 18 Jan 2022 14:56:41 +0000 (15:56 +0100)]
ipsec: fix AES CBC IV generation (CVE-2022-46397)

For AES-CBC, the IV must be unpredictable (see NIST SP800-38a Appendix
C). Chaining IVs like is done by ipsecmb and native backends for the
VNET_CRYPTO_OP_FLAG_INIT_IV is fully predictable.
Encrypt a counter as part of the message, making the (predictable)
counter-generated IV unpredictable.

Fixes: VPP-2037
Type: fix

Change-Id: If4f192d62bf97dda553e7573331c75efa11822ae
Signed-off-by: Benoît Ganne <bganne@cisco.com>
22 months agodpdk: improve rx burst count per loop 10/36410/1
Fan Zhang [Thu, 10 Mar 2022 14:49:19 +0000 (14:49 +0000)]
dpdk: improve rx burst count per loop

Type: improvement

This patch improves the per dpdk-input loop number of packets
received from the port. The change mimics how packets rx happened
before VPP 22.02/DPDK 21.11: instead of trying to rx huge number
of packets (256) in one go, rx more times with up to 32 packets
max each time.

Signed-off-by: Fan Zhang <roy.fan.zhang@intel.com>
Change-Id: I804dce6d9121ab21b02e53dd0328dc52ac49d80f
(cherry picked from commit a9fe20f4b8f7a9bd65cc8ee1b6a0204af7fc3627)

22 months agoipsec: fix vector after remove entry in spd 90/35990/2
Gabriel Oginski [Fri, 18 Feb 2022 08:05:00 +0000 (08:05 +0000)]
ipsec: fix vector after remove entry in spd

Originally after remove the policy entry in spd, macro "vec_del1"
can change localization of the last entry in vector and finally the
entry list has not been sorted.
This patch fixes this issue by change executed macro "vec_delete"
instead of "vec_del1".

Type: fix

Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Change-Id: I396591cbbe17646e1d243aedb4cdc272ed4d5e25
(cherry picked from commit aacd3ed6d5c9c32b646795583a634ca5925603d2)

23 months agodocs: update spelling word list and fix typos 01/36201/1
Dave Wallace [Wed, 25 May 2022 01:25:55 +0000 (21:25 -0400)]
docs: update spelling word list and fix typos

- update wordlist and fix typos so that 'make docs-spell' passes
- sort spelling_wordlist.txt
- update docs maintainers list

Type: docs

Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: I38ac7850c604c323427d2bb6877ea98bd10bcc38

2 years agotls: do not overwrite config parameters if set 28/36028/2
Ofer Heifetz [Thu, 14 Apr 2022 16:21:19 +0000 (19:21 +0300)]
tls: do not overwrite config parameters if set

User can define first_seg_size and add-segment-size in the tls
configuration section, but current code does not take this configuration
into account and sets a default value to first_seg_size and add_seg_size
respectively.

This commit checks if configuration was set and only if not uses the
default values.

Type: fix

Signed-off-by: Ofer Heifetz <oferh@marvell.com>
Change-Id: I0077f7d54fe7773dd92522476f882c924fda22df

2 years agoudp: fix inner packet checksum calculation in udp-encap 63/35663/1
Mauro Sardara [Tue, 22 Mar 2022 17:53:46 +0000 (17:53 +0000)]
udp: fix inner packet checksum calculation in udp-encap

When computing the inner packet checksum, the code wrongly
assumes that the IP version of the inner packet is the
same of the outer one. On the contrary, it is perfectly
possible to encapsulate v6 packets into v4 and viceversa,
so we need to check the IP format of the inner header before
calling vnet_calc_checksums_inline.

Ticket: VPP-2020
Type: fix

Signed-off-by: Mauro Sardara <msardara@cisco.com>
Change-Id: Ia4515563c164f6dd5096832c831a48cb0a29b3ad
Signed-off-by: Mauro Sardara <msardara@cisco.com>
(cherry picked from commit 9539647b895c456ca53892a9259e3127c6b92d35)

2 years agotcp: update error counters in listen node 60/35660/1
Florin Coras [Wed, 16 Mar 2022 04:46:34 +0000 (21:46 -0700)]
tcp: update error counters in listen node

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ib2e1d847607c9c7d928b174b87e5c21d53153ebe
(cherry picked from commit e8d67719fde74eee34d2a36f0d00343de4bbac7d)

2 years agomemif: fix memif_process_desc indexing 95/35595/1
Mauro Sardara [Mon, 14 Mar 2022 20:08:22 +0000 (20:08 +0000)]
memif: fix memif_process_desc indexing

The index i was incremented in the wrong place, and the check on the
presence of a next buffer in the chain was actually done for the
next desc_status rather than the current one.

Type: fix

Signed-off-by: Mauro Sardara <msardara@cisco.com>
Change-Id: I74a64a34fea497900b7969cd96e1aeeb570a1bba
(cherry picked from commit b0f0f8c8dd9d694bfc13652f89b8b577e9c1c708)

2 years agodpdk: fix program vlans on ixgbevf 28/35628/2
Dzmitry Sautsa [Thu, 10 Mar 2022 13:17:07 +0000 (14:17 +0100)]
dpdk: fix program vlans on ixgbevf

Recent "dpdk: refactor device setup" have broken vlans programming for IXGBE_VF.

Type: fix

Signed-off-by: Dzmitry Sautsa <dzmitry.sautsa@nokia.com>
Change-Id: Idacda33a473f6b10dbe002d9926661a19d0f3f97

2 years agomemif: Fix underflow 90/35590/1
Nathan Skrzypczak [Fri, 11 Feb 2022 10:19:58 +0000 (11:19 +0100)]
memif: Fix underflow

Type: fix

Change-Id: Id183c47328510b5db7ffcc7a4dfb41f5a3151399
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
(cherry picked from commit 1b969c2f6a181d4f7cca542dad00e4feb1e45650)

2 years agovapi: Missing include file in vlib.api.vapi.h 95/35395/2
Dave Wallace [Wed, 23 Feb 2022 20:36:02 +0000 (15:36 -0500)]
vapi: Missing include file in vlib.api.vapi.h

- A call to vapi_msg_control_ping_hton() is generated in
  a static inline function in vlib.api.vapi.h, which is
  defined/generated in memclnt.api.vapi.h without
  including memclnt.api.vapi.h in vlib.api.vapi.h.
  This breaks the compilation of plugins which include
  only vlib.api.vapi.h (e.g. hicn_plugin from the HICN
  project).

Type: fix
Fixes: a1400cecb

Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: I5574f4ed496183ea93265f493bf3624254a865a2
(cherry picked from commit 14baada2140ad5a19e4d502e81296fe70b5b54d1)

2 years agobuild: export missing header files required by hicn_plugin 94/35394/1
Dave Wallace [Wed, 23 Feb 2022 22:15:14 +0000 (17:15 -0500)]
build: export missing header files required by hicn_plugin

- HICN project's hicn_plugin requires vnet header files
  fib/fib_entry_track.h and udp/udp_encap.h to be
  included in build-root/install-vpp*-*/vpp/include/vnet

Type: fix

Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: Iabd3f8fe0aee8d727758fc6ef202e859d68d63a3
(cherry picked from commit 40cfc1560ee6fa11e4d6c74e9730541a8a45b68a)

2 years agomisc: VPP 22.02 Release Notes 36/35336/5 v22.02
Andrew Yourtchenko [Tue, 15 Feb 2022 16:29:46 +0000 (16:29 +0000)]
misc: VPP 22.02 Release Notes

type: docs
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: I32291160f0d22a804929d0a040472ff952f02544
Signed-off-by: Maciek Konstantynowicz <mkonstan@cisco.com>
2 years agofib: fix mpls db label overflow 87/35387/2
Dmitry Valter [Tue, 22 Feb 2022 06:40:22 +0000 (06:40 +0000)]
fib: fix mpls db label overflow

mpls fib DB size was 2^20 instead of intended 2^21.
Therefore large mpls labels caused DB to overflow and write
to other tables or some random objects. Or crash with ASAN.
Sometimes.

Type: fix

Signed-off-by: Dmitry Valter <d-valter@yandex-team.ru>
Change-Id: I6db65680037a266fe47e8213464a0c16de63c06c
(cherry picked from commit cf2595dfc0b446dd9bd5311d972cfb53b5567df8)

2 years agovxlan: add l2 mode test 90/35390/3
Artem Glazychev [Mon, 21 Feb 2022 10:51:29 +0000 (17:51 +0700)]
vxlan: add l2 mode test

Type: improvement

Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
Change-Id: I214f6fb5b63d97ca4afe3b10fd2d3e3410b5a6e4

2 years agovnet: add set_max_frame_size callbacks for several interfaces 89/35389/2
Artem Glazychev [Fri, 18 Feb 2022 05:23:20 +0000 (12:23 +0700)]
vnet: add set_max_frame_size callbacks for several interfaces

This is required after distinguishing between max_frame_size and MTU

Type: fix
Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
Change-Id: Ie642bee4e30ca76903bb8be5eeb6914c2c09bf35
(cherry picked from commit 66593a6a63fe30ed4b8bed96844244d78274e8f2)

2 years agolisp: fix ip and udp checksum computation 88/35388/2
Florin Coras [Fri, 18 Feb 2022 23:16:20 +0000 (15:16 -0800)]
lisp: fix ip and udp checksum computation

Type: fix
Fixes: 6fdcc3d

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I820c505482801ff2ab8dac41a0016bb3a741a4ee
(cherry picked from commit d85fe1a2164daf3cb23f48e6b9fd1ec2d97c87bc)

2 years agovxlan: crash on assigning IP address to interface 83/35383/2
Ed Warnicke [Fri, 18 Feb 2022 19:26:35 +0000 (19:26 +0000)]
vxlan: crash on assigning IP address to interface

Revert "vxlan: crash on configuring vxlan tunnel on l3 mode"

This reverts commit b8de7d43e4955bb4025cd0e0e7390279841b6d7d.

Reason for revert: VPP-2014

Type: fix
Fixes: b8de7d43e4955bb4025cd0e0e7390279841b6d7d

Change-Id: Ic4d10f28985ee10e0550a1bbfd465ada915e4aa6
Signed-off-by: Ed Warnicke <hagbard@gmail.com>
2 years agodpdk: enable scatter on Rx for net/ena 48/35348/2
akolechk [Wed, 16 Feb 2022 10:09:03 +0000 (12:09 +0200)]
dpdk: enable scatter on Rx for net/ena

Type: fix

Since commit https://github.com/DPDK/dpdk/commit/e2a6d08bef489215ebb77b1d3033875ada757cfa
DPDK started advertising scattered Rx feature for elastic network adapters. Thus, dpdk
plugin doesn't have to disable it for ENA by default anymore

Signed-off-by: akolechk <akolechk@cisco.com>
Change-Id: I2d4f429be992e3c4edcc0c3adf8c55f3d5381631

2 years agoipfix-export: pass ipv4 addr to format fn for show 12/35312/1
Paul Atkins [Wed, 1 Dec 2021 13:13:16 +0000 (13:13 +0000)]
ipfix-export: pass ipv4 addr to format fn for show

When the ipfix address was changed to be an ip_address instead of
an ip4_address the output when creating an exporter via the cli
should have been modified to take the address of the v4 part of
the addr.

Type: fix
Signed-off-by: Paul Atkins <patkins@graphiant.com>
Change-Id: I141456cd9092c861a4c4aefba4035dbde23efcd6
(cherry picked from commit bf9918a7e0c6bf116b90780cbc2c111ca7995399)

2 years agowireguard: fix passing argument 71/35071/2 v22.02-rc2
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
(cherry picked from commit ffd9057493ba75d157d8fd316f4978b64a6efb30)

2 years agodpdk-cryptodev: add support chacha20-poly1305 78/35078/3
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 agowireguard: add async mode for decryption packets 80/35080/2
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
(cherry picked from commit 77e69ae2d172dce74f4da4cae52bb63e28daa3ae)

2 years agowireguard: add async mode for encryption packets 79/35079/2
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
(cherry picked from commit 492d7790ff26c569bee81617c662363652891140)

2 years agowireguard: add burst mode 77/35077/1
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
(cherry picked from commit 8ca08496a43e8d98fe2d4130d760c6fb600d0a93)

2 years agomisc: Initial changes for stable/2202 branch 68/34968/1 v22.02-rc1
Andrew Yourtchenko [Wed, 19 Jan 2022 12:48:14 +0000 (13:48 +0100)]
misc: Initial changes for stable/2202 branch

Change-Id: I23e72a788d6f382601945986c8cb8cfc3bb9da8e
Type: docs
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
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

2 years agovlib: fix the total len not including first buffer formating 80/34880/2
Mohsin Kazmi [Tue, 11 Jan 2022 11:34:56 +0000 (11:34 +0000)]
vlib: fix the total len not including first buffer formating

Type: fix

total len not including first buffer is in vlib_buffer_t second cacheline.
It is not reset after the buffer has been consumed. It leads to printing
garbage in packet trace for subsequent use of this buffer. This patch
fixes the issue to only print when VLIB_BUFFER_NEXT_PRESENT flag is set.

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

2 years agodpdk: offloads cleanup 61/34861/10
Damjan Marion [Sun, 9 Jan 2022 13:05:27 +0000 (14:05 +0100)]
dpdk: offloads cleanup

Type: improvement
Change-Id: Ibf43aa483548e6055e4b851ad893371d7af3b018
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agomisc: fix the uninitialization error 74/34874/2
Mohsin Kazmi [Mon, 10 Jan 2022 15:32:35 +0000 (15:32 +0000)]
misc: fix the uninitialization error

Type: fix

| src/vppinfra/vector/toeplitz.c:69:9: error: ‘kv’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
| src/vppinfra/memcpy_x86_64.h:45:17: error: ‘*((void *)&key+16)’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
|    *(u8x16u *) d = *(u8x16u *) s;
|    ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~
| src/vnet/gre/interface.c:356:20: note: ‘*((void *)&key+16)’ was declared here

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

2 years agosession: increase postponed mq message min size 78/34878/5
Florin Coras [Mon, 10 Jan 2022 22:26:21 +0000 (14:26 -0800)]
session: increase postponed mq message min size

Reported by coverity

Type: fix

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

2 years agosession: fix segment manager format coverity warning 76/34876/3
Florin Coras [Mon, 10 Jan 2022 21:44:45 +0000 (13:44 -0800)]
session: fix segment manager format coverity warning

Type: fix

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

2 years agointerface: refactor interface capabilities code, part 2 29/34829/4
Damjan Marion [Mon, 10 Jan 2022 19:38:57 +0000 (19:38 +0000)]
interface: refactor interface capabilities code, part 2

Type: improvement

Signed-off-by: Damjan Marion <damarion@cisco.com>
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: Ie595e69af8657b0ee18a84ac71c5d433108d9ef8

2 years agovrrp: vrrp in unicast mode,interface not add virtual ip addresss 68/34768/2
jinsh [Sat, 18 Dec 2021 14:57:38 +0000 (22:57 +0800)]
vrrp: vrrp in unicast mode,interface not add virtual ip addresss

Type: fix

Signed-off-by: jinsh <jinsh11@chinatelecom.cn>
Change-Id: Id80601bc753c59c4ea95ff5f74f9b15c40c01e35

2 years agosession: allow pacer to send when bucket hits 0 65/34865/2
Florin Coras [Mon, 10 Jan 2022 03:03:09 +0000 (19:03 -0800)]
session: allow pacer to send when bucket hits 0

So after bucket reset session can send max burst of bytes.
Also, reset pacer bucket to 0 not min burst

Type: improvement

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

2 years agosession: deschedule sessions with no data to send 64/34864/2
Florin Coras [Mon, 10 Jan 2022 02:18:10 +0000 (18:18 -0800)]
session: deschedule sessions with no data to send

This ensures the scheduler always tracks sessions that are descheduled,
i.e., do not have events in the old io events list. When app retries to
send, clear descheduled flag and potentially the pacer.

Consequently, transports no longer need to reset the pacer when
sessions are rescheduled after a long app tx pause.

This also fixes a tcp bug whereby the pacer was reset too often when
snd_una was equal to snd_nxt as there was no way to distinguish betwen
app tx breaks and congestion.

Type: improvement

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

2 years agosession: fix pacer bucket update cast 63/34863/3
Florin Coras [Mon, 10 Jan 2022 01:20:28 +0000 (17:20 -0800)]
session: fix pacer bucket update cast

Make sure comparison is done between two i64 values.

Type: fix

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

2 years agodpdk: interface capabilities cleanup 58/34858/4
Damjan Marion [Sun, 9 Jan 2022 12:02:12 +0000 (13:02 +0100)]
dpdk: interface capabilities cleanup

Type: improvement
Change-Id: If5636d4376fb06da62f947c28b18c07b6ad21722
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: port type code cleanup 57/34857/4
Damjan Marion [Sun, 9 Jan 2022 12:13:13 +0000 (13:13 +0100)]
dpdk: port type code cleanup

Type: improvement
Change-Id: I4ead18dee249a27b4dbb8bbf53b6238d91042890
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agovppinfra: Check for NULL vec before the backwards iteration 59/34859/2
Neale Ranns [Sun, 9 Jan 2022 13:24:47 +0000 (13:24 +0000)]
vppinfra: Check for NULL vec before the backwards iteration

Type: improvement

'vec_end(v) - 1' does not yield a good starting point. Check for NULL vec before the loop, so the user does not have to.

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

2 years agofib: multiple memory leaks upon deleting a VRF table 35/34735/5
Steven Luong [Wed, 15 Dec 2021 21:27:53 +0000 (13:27 -0800)]
fib: multiple memory leaks upon deleting a VRF table

fib_table->ft_locks
name string for parsing the ip table add|del name <tag> command
path list for ip4_specials in mfib
mfib->fib_entry_by_dst_address[0..32]
mfib entry path_ext, msrc->mfes_exts

Type: fix

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

2 years agodpdk: new mbuf flags in format function 54/34854/3
Damjan Marion [Sat, 8 Jan 2022 20:07:03 +0000 (21:07 +0100)]
dpdk: new mbuf flags in format function

Type: improvement
Change-Id: I9022e29ebc0edb7946d374d6c3c45ee6962d725f
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: new flags format 37/34837/17
Damjan Marion [Wed, 5 Jan 2022 21:51:33 +0000 (22:51 +0100)]
dpdk: new flags format

introduced in DPDK 21.11

Type: improvement
Change-Id: I8c845949dd904a2bf8fa4a91e2f3ae5d704f2283
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agotcp: fix cubic cwnd accumulate use of bytes acked 53/34853/1
Florin Coras [Fri, 7 Jan 2022 23:06:42 +0000 (15:06 -0800)]
tcp: fix cubic cwnd accumulate use of bytes acked

Use what was provided instead of tc->bytes_acked

Type: fix

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

2 years agobonding: memory leak on parsing bad CLI command 46/34846/3
Steven Luong [Thu, 6 Jan 2022 21:02:00 +0000 (13:02 -0800)]
bonding: memory leak on parsing bad CLI command

When parsing bad "create bond" command, we should call unformat_free
prior to return

Type: fix
Fixes: 9cd2d7a5a4fafadb65d772c48109d55d1e19d425

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

2 years agovmxnet3: memory leak on parsing bad CLI command 47/34847/2
Steven Luong [Thu, 6 Jan 2022 23:15:11 +0000 (15:15 -0800)]
vmxnet3: memory leak on parsing bad CLI command

When parsing bad "create interface vmxnet3" command, we should call
unformat_free prior to return

Type: fix
Fixes: df7f8e8cffcc43531f7daeda44d436b60e538141

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

2 years agoethernet: new interface registration function 41/34841/4
Damjan Marion [Thu, 6 Jan 2022 19:36:14 +0000 (20:36 +0100)]
ethernet: new interface registration function

Prep for supporting multiple callbacks, optional args, etc.

Type: improvement
Change-Id: I96244c098712e8213374678623f12527b0e7f387
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: fix rx and tx descriptor config 50/34850/3
Florin Coras [Fri, 7 Jan 2022 01:51:17 +0000 (17:51 -0800)]
dpdk: fix rx and tx descriptor config

Type: fix

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

2 years agotcp: optimize newreno cong ack handler 49/34849/1
Florin Coras [Fri, 7 Jan 2022 01:47:14 +0000 (17:47 -0800)]
tcp: optimize newreno cong ack handler

Type: improvement

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

2 years agotcp: update snd_congestion only during congestion 42/34842/3
Florin Coras [Thu, 6 Jan 2022 19:58:24 +0000 (11:58 -0800)]
tcp: update snd_congestion only during congestion

If running without sacks, if snd_una does not cover snd_congestion fast
recovery can be missed but the two heuristics from RFC6582 should avoid
that.

Also snd_congestion was used as a means of inferring if the connection
recently exited congestion while setting the persist timer but that does
not always work correctly if not congested.

Type: fix

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

2 years agotcp: mark lost first sack hole on timeout 31/34831/5
Florin Coras [Wed, 5 Jan 2022 18:16:07 +0000 (10:16 -0800)]
tcp: mark lost first sack hole on timeout

Type: improvement

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

2 years agotcp: handle start tx event in cubic 30/34830/6
Florin Coras [Wed, 5 Jan 2022 17:48:36 +0000 (09:48 -0800)]
tcp: handle start tx event in cubic

If app was idle update start time of current congestion avoidance phase
unless tcp connection was not idle.

Type: improvement

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

2 years agotcp: always exit recovery if not in fastrecovery 40/34840/3
Florin Coras [Thu, 6 Jan 2022 03:54:45 +0000 (19:54 -0800)]
tcp: always exit recovery if not in fastrecovery

Stay in fast recovery only if it's already on.

Type: improvement

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

2 years agotcp: exit retransmit before processing feedback 36/34836/5
Florin Coras [Wed, 5 Jan 2022 20:55:35 +0000 (12:55 -0800)]
tcp: exit retransmit before processing feedback

Type: refactor

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

2 years agotcp: use bytes delivered to compute cwnd 28/34828/4
Florin Coras [Wed, 5 Jan 2022 16:47:11 +0000 (08:47 -0800)]
tcp: use bytes delivered to compute cwnd

Should estimated cwnd better with loss

Type: improvement

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

2 years agotcp: cast timer ticks to u32 14/34814/5
Florin Coras [Mon, 3 Jan 2022 18:34:52 +0000 (10:34 -0800)]
tcp: cast timer ticks to u32

tc->rto * TCP_TO_TIMER_TICK can return garbage if not cast to u32 and
that confuses clib_max

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
signed-off-by: Vipul Agrawal <Vipul.Agrawal@enea.com>
Change-Id: Ief4d29b9625e2ef2e75e0c7e3d731ab147465f6d

2 years agodpdk: cleanup MTU handling 39/34839/4
Damjan Marion [Wed, 5 Jan 2022 22:25:12 +0000 (23:25 +0100)]
dpdk: cleanup MTU handling

Type: improvement
Change-Id: I4b929693f3671be8ee63a58afcbac75a27d99d57
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: port type from speed_capa bitmap on Cisco VIC 38/34838/2
Damjan Marion [Wed, 5 Jan 2022 23:23:38 +0000 (00:23 +0100)]
dpdk: port type from speed_capa bitmap on Cisco VIC

enic driver now properly exposes speed_capa bitmap so this workaround
is not needed anymore.

Type: refactor
Change-Id: Ic754de0b9de32d488405ffcd8d62dd6aa035d2bc
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agotap: add num_tx_queues API 57/34757/4
Nathan Skrzypczak [Wed, 15 Dec 2021 17:45:59 +0000 (18:45 +0100)]
tap: add num_tx_queues API

This adds a create_tap_v3 api that has a num_tx_queues
parameter allowing to create more than num_workers queues,
following on multi TX support

Type: feature

Change-Id: Idce433147e8dd165f842241d6c76e041e1b1c9b8
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2 years agodpdk: remove unused defines 35/34835/2
Damjan Marion [Wed, 5 Jan 2022 20:30:54 +0000 (21:30 +0100)]
dpdk: remove unused defines

Type: refactor
Change-Id: I41d5d07eef670e89eba8fd816e123981940b5d79
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: no need to copy default tx conf 34/34834/2
Damjan Marion [Wed, 5 Jan 2022 20:26:51 +0000 (21:26 +0100)]
dpdk: no need to copy default tx conf

Type: improvement
Change-Id: Ifd5201c101da7f4fb63f9b64280a6ec35b2af6a0
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: improve checksum computation 33/34833/8
Florin Coras [Wed, 5 Jan 2022 19:31:03 +0000 (11:31 -0800)]
dpdk: improve checksum computation

Type: improvement

Based on gerrit 26480 by chenmin.sun@intel.com

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

2 years agointerface: refactor interface capabilities code 26/34826/4
Damjan Marion [Wed, 5 Jan 2022 00:52:38 +0000 (01:52 +0100)]
interface: refactor interface capabilities code

Make it shorter to type, easier to debug, make adding callbacks in
future simpler.

Type: improvement
Change-Id: I6cdd6375e36da23bd452a7c7273ff42789e94433
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: move port config to single struct 27/34827/3
Damjan Marion [Wed, 5 Jan 2022 13:51:50 +0000 (14:51 +0100)]
dpdk: move port config to single struct

Type: refactor
Change-Id: I0bce385c7e391fa2b74646d001980610f80f7062
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agovppinfra: few bitops inlines 25/34825/2
Damjan Marion [Wed, 5 Jan 2022 13:06:34 +0000 (14:06 +0100)]
vppinfra: few bitops inlines

Change-Id: I9aa01fafd5329a399aa9d72a6e2cc6c9d65dc85c
Type: improvement
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agodpdk: remove unused flag 23/34823/3
Damjan Marion [Wed, 5 Jan 2022 00:28:55 +0000 (01:28 +0100)]
dpdk: remove unused flag

Type: refactor
Change-Id: Iff96a79323d7d428a779e9736e07c1dc9dddb518
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 years agosrv6-mobile: Update GTP4/6.D function 12/34712/8
Tetsuya Murakami [Fri, 10 Dec 2021 16:11:07 +0000 (08:11 -0800)]
srv6-mobile: Update GTP4/6.D function

GTP4/6.D behavior is updated as shown below.
1. When receiving GTP-U message or IPv6 linklocal destination in inner IP, GTP packet is tnralated to SRv6.
2. When receiving T-PDU packet, OuterIP/UDP/GTP headers are stripped off and Inner IP is encapsulated into SRv6 based on L3VPN SRv6 manner.

Type: feature

Signed-off-by: Tetsuya Murakami <tetsuya.mrk@gmail.com>
Change-Id: I6092c98ea80236d54017f84c5b35cca0b645f034
Signed-off-by: Tetsuya Murakami <tetsuya.mrk@gmail.com>
2 years agodpdk: keep buffer flags per-device 20/34820/2
Damjan Marion [Tue, 4 Jan 2022 19:07:32 +0000 (20:07 +0100)]
dpdk: keep buffer flags per-device

Type: improvement
Change-Id: Idb0b079df49c12643c9a93ee0effe011d3489068
Signed-off-by: Damjan Marion <damarion@cisco.com>