Florin Coras [Wed, 26 Jul 2023 18:27:33 +0000 (11:27 -0700)]
vcl: allow rx of zero length dgrams
Type: fix
Change-Id: I438ef488357456e9415e51a17355e9eba8518808
Signed-off-by: Florin Coras <fcoras@cisco.com>
Vratko Polak [Wed, 26 Jul 2023 11:48:20 +0000 (13:48 +0200)]
vlib: rename vnet_log_get_class_data
It is a function in vlib, so no reason to mention vnet.
Type: fix
Fixes:
bf179a91d8d224c64d08643a2bb52580f68ce96b
Change-Id: Ic5f601d94d88b667f7ce44a017a0e1d5b4db5da1
Signed-off-by: Vratko Polak <vrpolak@cisco.com>
Steven Luong [Tue, 25 Jul 2023 19:32:01 +0000 (12:32 -0700)]
stats: remove extra format line
The extra format line was added for no reason from patch
ff27c9f8e.
Type: fix
Fixes:
ff27c9f8e
Change-Id: Ib25149cc8a17c29d0c8a0dbc06f0ea12ca4f328c
Signed-off-by: Steven Luong <sluong@cisco.com>
Filip Tehlar [Wed, 28 Jun 2023 08:47:32 +0000 (10:47 +0200)]
session: use session error type instead of vnet error
Type: improvement
Change-Id: Ie0bad9e03ac2e29da23af01ee7f63cb44489ad9c
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Damjan Marion [Sun, 23 Jul 2023 12:24:22 +0000 (14:24 +0200)]
vlib: interrupt mode support for pre-input nodes
Type: improvement
Change-Id: Ic6e60597d2be63e3a0ae4399a81dbbd72392f30d
Signed-off-by: Damjan Marion <damarion@cisco.com>
Maxime Peim [Mon, 3 Jul 2023 15:45:51 +0000 (17:45 +0200)]
classify: add bpf support to pcap classifier
Type: feature
Change-Id: I28fb38e49c89f4c4d4cc58c1a5c0aa8502678472
Signed-off-by: Maxime Peim <mpeim@cisco.com>
Tianyu Li [Fri, 7 Jul 2023 06:38:06 +0000 (06:38 +0000)]
dpdk: fix signed single bit field
clang-16 complains about signed one-bit bitfield value changes
from 1 to -1. Use unsigned type instead.
Type: fix
Signed-off-by: Tianyu Li <tianyu.li@arm.com>
Change-Id: I84f8cf314d36183a5e6f544cd756c01d1d10a1a5
Gabriel Oginski [Fri, 7 Jul 2023 11:58:26 +0000 (11:58 +0000)]
vpp-swan: fix handler API messages
In the current implementation there is a bug related to the incorrect
message handling due to the wrong id.
The fix changes logic responsible for handling incoming API messages
by correcting their ids.
Type: fix
Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Change-Id: Iea29506053c9fd2e1d01bce83e7f4a6e1de39321
qinyang [Tue, 27 Jun 2023 08:11:53 +0000 (01:11 -0700)]
vcl: ldp support SO_ORIGINAL_DST
Type: improvement
Support SO_ORIGINAL_DST socket option to get original dst_ip4 and dst_port if nat44 rule enabled.
Change-Id: If00e00d03e48f3b78a23a68f1b078954d79dd0f7
Signed-off-by: qinyang <qiny@yusur.tech>
Naveen Joy [Tue, 27 Jun 2023 21:28:57 +0000 (14:28 -0700)]
tests: Add checksum offload interface tests
Type: test
Change-Id: I6edc8858b802d3d32159d71c1e867a06cc1025d5
Signed-off-by: Naveen Joy <najoy@cisco.com>
Piotr Bronowski [Thu, 23 Feb 2023 09:56:49 +0000 (09:56 +0000)]
ipsec: fix logic in ext_hdr_is_pre_esp
When _VEC128 instructions are not enabled logic is buggy.
The function always returned 1.
Type: fix
Signed-off-by: Piotr Bronowski <piotrx.bronowski@intel.com>
Change-Id: I603200637e8d65813f4e49ef15d798e74b79b9cf
Steven Luong [Wed, 19 Jul 2023 06:25:15 +0000 (23:25 -0700)]
vcl: zero out cmsg for recvmsg API
When msg->msg_controllen is set in recvmsg, the caller wants to receive
additional information about the messages. However, they might not
always be available. In that case, we should clear cmsg since
the caller uses CMSG_NXTHDR which might access uninitialized fields in
cmsg.
Type: fix
Change-Id: Ifdf9634bfcb1427f7ae3812014a46bfd7f4bc473
Signed-off-by: Steven Luong <sluong@cisco.com>
Gabriel Oginski [Fri, 14 Jul 2023 07:22:12 +0000 (07:22 +0000)]
vpp-swan: change flow in function for add route
This patch addresses the issue when the list of available interfaces
is not up to date. Due to this issue adding a new route fails
and finally the connection is not established.
Type: fix
Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Change-Id: I3a63c0dd99ebc28ea149b4b23867440937682761
Gabriel Oginski [Thu, 6 Jul 2023 11:13:16 +0000 (11:13 +0000)]
vpp-swan: fix incorrect msg ID in register_event
This patch addresses the issue where the message ID registration
in the register_event function is incorrect. Due to this incorrect
registration, the lookup for the corresponding callback on received
messages fails, eventually leading to a segmentation fault
and double-free memory space.
Type: fix
Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Change-Id: If95182f972f64adb44d514e18c831cc9627d8f0f
Gabriel Oginski [Thu, 6 Jul 2023 09:18:45 +0000 (09:18 +0000)]
vpp-swan: fix function to get sw_if_index
In the current implementation there is a bug in the function
responsible for getting software interface index by the name of the
interface. Incorrect function is used to send the API message, also
the handler with replied message is incorrect.
The fix changes function to send dump message and also adds handler
with replied message in the correct way.
Type: fix
Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Change-Id: Id1a3ba2ce7e92d216907f344431b9e2acb1d5572
Dave Wallace [Thu, 6 Jul 2023 20:38:49 +0000 (16:38 -0400)]
docs: add api change process from wiki
- Move the VPP API Change Process documentation
from the wiki page into the in-tree VPP docs
Type: docs
Change-Id: I42f661618b8632230bebe3aa8fbad455b9a05d01
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Matthew Smith [Fri, 14 Jul 2023 16:05:39 +0000 (16:05 +0000)]
ipip: populate mode in tunnel details
Type: improvement
There is a mode field in ipip_tunnel_details. The handler for the dump
API does not do anything to populate it so it always contains 0
(TUNNEL_API_MODE_P2P). This is correct for p2p tunnels but is wrong for
multipoint tunnels.
Populate the field with the correct mode.
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
Change-Id: I6c1288a0d3929db0f67100748b5760c36b594f97
Florin Coras [Wed, 12 Jul 2023 12:44:45 +0000 (05:44 -0700)]
hsa: fix echo client init
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ieb2d1e6e0949844a70c81b218ca7dc83690776ca
Nobuhiro MIKI [Wed, 28 Jun 2023 06:15:58 +0000 (15:15 +0900)]
lb: Fix src_ip_sticky evaluation bug in per-port-vip case.
Before this fix, the src_ip_sticky flag was passed as an argument to
the lb_node_get_hash function, which computes a hash value for a packet.
However, in per-port-vip case, the value of src_ip_sticky flag may be
different for each port number. As a result, the value is the same for
all port numbers, even though it is a per-port-vip case.
This commit fixes the src_ip_sticky evaluation by delaying it until the
packet is received, so that the correct value is obtained. Also, the
unit test case has been enhanced for this bug fix.
The steps to reproduce this bug are described below:
https://lists.fd.io/g/vpp-dev/message/23248
Type: fix
Fixes:
613e6dc0bf92 ("lb: add source ip based sticky load balancing")
Change-Id: I483492b214a1768e7a21fd86edd5151b3c46528b
Signed-off-by: Nobuhiro MIKI <nmiki@yahoo-corp.jp>
Alexander Chernavin [Tue, 11 Jul 2023 11:10:48 +0000 (11:10 +0000)]
linux-cp: fix crash on processing dump of routes
nl_route_add() recently started to use its optional argument to check
whether replace flag is set for the message. When notification messages
are processed, the argument is a pointer to the corresponding message
info. However, when dump replies are processed, the argument is a null
pointer. This leads to null pointer dereference and crash when dump of
routes is processed.
With this fix, check for replace flag only if message info was passed
to nl_route_add(). Otherwise, assume the flag is not set. Dump replies
do not have it set.
Type: fix
Change-Id: Icb04a1146e09cc965b623018c28f91b347be0eab
Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
Damjan Marion [Tue, 13 Jun 2023 14:05:56 +0000 (16:05 +0200)]
avf: remove barrier
Type: improvement
Change-Id: I95023d2e6034b77952e0423d0430b433ea0dab15
Signed-off-by: Damjan Marion <damarion@cisco.com>
Adrian Pistol [Wed, 7 Jun 2023 13:28:17 +0000 (15:28 +0200)]
linux-cp: Basic MPLS support.
1) Imports ENCAP_MPLS labels from IPv4/IPv6 routes.
Note that this requires libnl 3.6.0 or newer.
In previous patches, the fib_path_ext_t had a path ID of -1.
After a long investigation, it turned out to be caused by route weight
being set to 0. There is a comment explaining more details.
2) Handles MPLS routes.
MPLS routes were wrongly added as IPv4 routes before.
POP and SWAP are now both supported.
All the routes are installed as NON-EOS and EOS routes,
as the Linux kernel does not differentiate.
EOS POP used in PHP uses the next-hop address family
to determine the resulting address family.
This patch is sufficient for P setups.
PE setups with implicit null should also function okay, as long as a
seperate label gets programmed per address family.
PE setups with explicit null will also forward packets,
but punting is a bit odd and needs MPLS input enabled on the LCP host
device.
3) Propagate MPLS input state to LCP Pair and Linux.
Since the Linux kernel uses the MPLS routes itself,
the LCP pair tap needs MPLS enabled to allow host originated packets.
This also syncs the Linux `net.mpls.conf.<host_if>.input` sysctl to
allow punted packets to have MPLS labels, mostly explicit nulls.
In addition, a special feature is enabled to cross connect MPLS packets
coming from Linux directly to interface-output untouched.
Make sure to enable MPLS/add a table in VPP first and load the
MPLS kernel modules!!
Type: feature
Change-Id: Ie4184bb4cc96905bf8b483a27e7ca6d251697374
Signed-off-by: Adrian Pistol <vifino@posteo.net>
Signed-off-by: Pim van Pelt <pim@ipng.nl>
Steven Luong [Wed, 21 Jun 2023 05:22:45 +0000 (22:22 -0700)]
stats: fix duplicate /if/names entry
stats entries /if/names are never deleted as it is a vector of the
sw_if_index value. When the interface is deleted and then created again
later, and if the new interface takes a different sw_if_index, we may
end up with duplicate entries for the same interface name. For example,
the following configuration sequence causes problem
create loopback interface
create loopback interface
delete loopback interface intfc loop0
delete loopback interface intfc loop1
create loopback interface
vpp_get_stats dump /if/names
[0]: local0 /if/names
[1]: loop0 /if/names
[2]: loop0 /if/names
The fix is to set the delete /if/names entry to deleted when the interface is deleted.
Type: fix
Change-Id: I7d811b12d56e3cf8c7deffe14736ea0f24814d02
Signed-off-by: Steven Luong <sluong@cisco.com>
Tianyu Li [Fri, 7 Jul 2023 06:47:56 +0000 (06:47 +0000)]
api: fix signed single bit field
clang-16 complains about signed one-bit bitfield value
changes from 1 to -1. Use unsigned type instead.
Type: fix
Signed-off-by: Tianyu Li <tianyu.li@arm.com>
Change-Id: Iab006c036d4068af2fe3caaefc871a95b26cc578
Ondrej Fabry [Thu, 4 May 2023 12:52:54 +0000 (14:52 +0200)]
api: lcp - Mark old message versions as deprecated
List of changed messages:
- lcp_itf_pair_add_del
- lcp_itf_pair_add_del_reply
- lcp_itf_pair_add_del_v2
- lcp_itf_pair_add_del_v2_reply
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: Ic20a852dd1fb27858c8776095f9c98757b89bfe8
Ondrej Fabry [Thu, 13 Apr 2023 06:55:28 +0000 (08:55 +0200)]
api: ip - Mark old message versions as deprecated
List of changed messages:
- ip_punt_redirect_dump
- ip_punt_redirect_details
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: Icf91f760b9bd328110b0f9fc2e421bb954033d21
Ondrej Fabry [Wed, 26 Apr 2023 22:00:01 +0000 (00:00 +0200)]
api: memif - Mark old message versions as deprecated
List of changed messages:
- memif_socket_filename_add_del
- memif_socket_filename_add_del_reply
- memif_create
- memif_create_reply
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: Id334990584b64a0efa3c28a3d8b6b641adab8c09
Ondrej Fabry [Wed, 26 Apr 2023 22:00:27 +0000 (00:00 +0200)]
api: memclnt - Mark old message versions as deprecated
List of changed messages:
- memclnt_create
- memclnt_create_reply
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: I0031cc2f1604ca4c34574c8e1ee28e358c2bbe5d
Ondrej Fabry [Wed, 26 Apr 2023 22:00:33 +0000 (00:00 +0200)]
api: pg - Mark old message versions as deprecated
List of changed messages:
- pg_create_interface
- pg_create_interface_reply
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: I574927f0820c54d748f27fd96a45afec5243b645
Ondrej Fabry [Wed, 26 Apr 2023 22:00:40 +0000 (00:00 +0200)]
api: sr - Mark old message versions as deprecated
List of changed messages:
- sr_policies_dump
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: I16ae1bed83ad8c73e3254b6d195251702de84f97
Ondrej Fabry [Fri, 14 Apr 2023 08:50:12 +0000 (10:50 +0200)]
api: ipsec - Mark old message versions as deprecated
List of changed messages:
- ipsec_sad_entry_add_del_v2
- ipsec_sad_entry_add_del_v2_reply
- ipsec_sa_v2_dump
- ipsec_sa_v2_details
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: I8fd6906e9684ef7ebc0688dc8b0637ae2dc8d0a2
Laszlo Kiraly [Thu, 6 Jul 2023 10:27:11 +0000 (12:27 +0200)]
build: generate debug info rpm packages for opensuse
Enabling debug info RPM creation in spec file.
Type: fix
Signed-off-by: Laszlo Kiraly <laszlo.kiraly@est.tech>
Change-Id: Id284b135ec4125905145f7902a6e1cf42ba65aa4
Laszlo Kiraly [Thu, 6 Jul 2023 09:36:42 +0000 (11:36 +0200)]
build: add missing dependences for opensuse
VPP build failed when build xdp-tool on opensuse
Add the missing libraries and headers.
Type: fix
Signed-off-by: Laszlo Kiraly <laszlo.kiraly@est.tech>
Change-Id: I8c3f28ac6e88cd61a1bf0a823ffa1d5f3097be40
Piotr Bronowski [Fri, 9 Jun 2023 15:43:05 +0000 (15:43 +0000)]
dpdk-cryptodev: introduce sw_ring to the crypto op data path
This patch introduces sw_ring to the crypto op data path implementation,
so that raw data path and crypto op data path use same mechanism of processing
async frames. Crypto op ring has been removed from the implementation.
Type: improvement
Signed-off-by: Piotr Bronowski <piotrx.bronowski@intel.com>
Change-Id: Id823f80a88cfa0ff40252616a36de8bb044c7f45
Ting Xu [Mon, 3 Jul 2023 08:08:33 +0000 (08:08 +0000)]
packetforge: fix has_key invalid in python3
Python Dict attribute "has_key" was removed in Python3. Use "in"
operation instead.
Type: fix
Signed-off-by: Ting Xu <ting.xu@intel.com>
Change-Id: I7b63b0689e9970ca798921368c5616875f7d5682
Benoît Ganne [Wed, 7 Jun 2023 09:33:31 +0000 (11:33 +0200)]
docs: fix packages path in tutorial
Type: fix
Change-Id: I84bbb28490d9c66c5bf55839ab75b3aec1bf5854
Signed-off-by: Benoît Ganne <bganne@cisco.com>
Mohammed Hawari [Fri, 9 Jun 2023 14:50:56 +0000 (16:50 +0200)]
bpf_trace_filter: plugin for BPF Trace Filtering
Change-Id: I342de0a375b783725aa2b621c1c70bc8bf646450
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Type: improvement
Mohammed Hawari [Fri, 26 May 2023 12:52:50 +0000 (14:52 +0200)]
vlib: introduce trace filter functions
Change-Id: I7a988fafe98599e4fcf7cdaa307a69b9d76650f0
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Type: improvement
Piotr Bronowski [Wed, 28 Jun 2023 08:16:38 +0000 (08:16 +0000)]
dpdk-cryptodev: sync mbuf length with corresponding vlib buffer
When vlib buffer is processed on vnet side its length is corrected by
cipher padding and icv_sz. These changes need to be reflected in
the mbuf internals.
Type: fix
Signed-off-by: Piotr Bronowski <piotrx.bronowski@intel.com>
Change-Id: I0aa03f67f556dfc8f9a577ca1967210527221e02
Alexander Chernavin [Mon, 26 Jun 2023 15:57:57 +0000 (15:57 +0000)]
ip-neighbor: add api for getting neighbor db config
There is an API call to change neighbor database configuration (i.e.
limit on peer number, aging, and recycling). With this change, make
getting current values of these settings available via the API.
Type: improvement
Change-Id: Ie9394e086b68cf9b28ad98dea162f203f8043cbb
Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
Florin Coras [Wed, 28 Jun 2023 02:45:59 +0000 (19:45 -0700)]
session udp: add len check for tx dgrams
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I35391fb8c39defbe0e57a241a357c3c98e8cef54
Filip Tehlar [Thu, 15 Jun 2023 08:06:57 +0000 (10:06 +0200)]
hs-test: add nginx+quic test
Type: test
Change-Id: I15e4f2fb84cb4f34b6fea95978db000854a63e78
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Ondrej Fabry [Wed, 26 Apr 2023 21:59:55 +0000 (23:59 +0200)]
api: af_packet - Mark old message versions as deprecated
List of changed messages:
- af_packet_create
- af_packet_create_reply
- af_packet_create_v2
- af_packet_create_v2_reply
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: Ia065c3bbc2c7923de64f47417099aea1aa1216b1
Ondrej Fabry [Wed, 26 Apr 2023 22:00:46 +0000 (00:00 +0200)]
api: tapv2 - Mark old message versions as deprecated
List of changed messages:
- tap_create_v2
- tap_create_v2_reply
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: I7b1b22cc4a0e31f5c19fe48e7a0f30631576f9df
Ondrej Fabry [Wed, 26 Apr 2023 22:00:13 +0000 (00:00 +0200)]
api: vxlan - Mark old message versions as deprecated
List of changed messages:
- vxlan_add_del_tunnel
- vxlan_add_del_tunnel_v2
- vxlan_add_del_tunnel_reply
- vxlan_add_del_tunnel_v2_reply
- vxlan_tunnel_dump
- vxlan_tunnel_details
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: I0a7227e76a493731fd136f8e6310ad372fab2494
Stanislav Zaikin [Thu, 22 Jun 2023 14:46:01 +0000 (16:46 +0200)]
af_xdp: create_api_v3 without namespace keyword
Namespace keyword is reverved c++ word, so it's not possible to include
vapi header for af_xdp plugin and use it.
Type: fix
Signed-off-by: Stanislav Zaikin <stanislav.zaikin@46labs.com>
Change-Id: I42a0e0a89ff2c407090d3c18c1bc5a5605ddf032
Stanislav Zaikin [Thu, 5 May 2022 10:04:39 +0000 (12:04 +0200)]
virtio: use fast-path for ethernet-input if possible
If a frame should be sent to 'ethernet-input' set the
ETH_INPUT_FRAME_F_SINGLE_SW_IF_IDX flag. It will force 'ethernet-input'
to use a fast-path for such frames.
This patch also aligns the behaviour with other input nodes.
Type: improvement
Change-Id: Icff0fa31204d5304a2ea0a4f4e7bc418dedbfe32
Signed-off-by: Stanislav Zaikin <zstaseg@gmail.com>
Florin Coras [Sat, 24 Jun 2023 21:43:42 +0000 (14:43 -0700)]
udp: pass cless hdr to transport through buffer
Type: improvement
Signed-off-by: Florin Coras <fcoras@cisco.com>
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Change-Id: I7177ada23e5a69ec8e362ec98b98010c3b44b3d7
Florin Coras [Sun, 25 Jun 2023 01:57:17 +0000 (18:57 -0700)]
tcp: avoid initializing counters multiple times
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ia98dae5fdde16426d5457742aff0a1b04db4d034
Maxime Peim [Mon, 20 Mar 2023 14:13:56 +0000 (14:13 +0000)]
ipsec: manually binding an SA to a worker
An SA is normally bound to the first thread using it. However, one
could want to manually bind an SA to a specific worker.
Type: improvement
Signed-off-by: Maxime Peim <mpeim@cisco.com>
Change-Id: I05cbbf753e44a01d9964ee47812c964db9bbb488
Stanislav Zaikin [Tue, 14 Mar 2023 11:32:32 +0000 (12:32 +0100)]
fib: walk over adj glean per table
Type: fix
Signed-off-by: Stanislav Zaikin <stanislav.zaikin@46labs.com>
Change-Id: I07f54bb643c24b1839a2d0e93acc593d13a43fed
Florin Coras [Thu, 22 Jun 2023 03:02:25 +0000 (20:02 -0700)]
tcp: add simple stats collector
Type: feature
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I435ff10fa3af15b0bed83607aca508a1c087a159
Dave Wallace [Thu, 22 Jun 2023 03:14:38 +0000 (23:14 -0400)]
tests docs: fix lcov code coverage report generation
- Updated/rebased version of https://gerrit.fd.io/r/c/vpp/+/34199
Type: test
Change-Id: I43913ecfd11a4578bdb10c4be76253fe38d57976
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Maxime Peim [Mon, 19 Jun 2023 16:19:48 +0000 (18:19 +0200)]
tcp: options support into pg
Packet-generator does not support TCP options.
Along with its support, a formatting function has been added.
Further work will be needed to update header formatting functions
to take into account TCP connection options. For now, TCP options
are taken on a per-packet basis.
Type: improvement
Change-Id: Id800887853c4941d893be353ce6d8624ed8bbc5d
Signed-off-by: Maxime Peim <mpeim@cisco.com>
Andrew Yourtchenko [Tue, 20 Jun 2023 14:52:08 +0000 (14:52 +0000)]
tests: do not run qemu interface tests if the environment does not allow it
cdf73b973181ff4c67147900408216e37bae897a has added the qemu tests as part of the default test run,
which results in "make test" failure in more restricted environments which do not allow the
namespace creation.
Add a config flag to skip those tests, and skip them if the namespace creation fails.
Type: test
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Change-Id: Ie631f7fb2a80864f77c79619eba4a43712e950e5
Florin Coras [Tue, 20 Jun 2023 23:50:51 +0000 (16:50 -0700)]
session: mark half-open transport closed on ntf
Make sure half-open sessions are marked as transport closed once
connected notification is provided. This ensures that if they've been
scheduled for tx, the event is ignored.
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I8c44584e843d93365ec737ae4e1bcb74eba35506
Benoît Ganne [Tue, 20 Jun 2023 10:03:36 +0000 (12:03 +0200)]
af_xdp: fix chained buffer free on failure
Type: fix
Change-Id: I7c6fb783e5200773cbd02c86d39fd241efcc39f9
Signed-off-by: Benoît Ganne <bganne@cisco.com>
Florin Coras [Tue, 20 Jun 2023 15:47:37 +0000 (08:47 -0700)]
vcl: fix epoll lt coverity warning
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I6900d9ab147d35f99f944bf741f6bb329c8ea0df
Piotr Bronowski [Fri, 9 Jun 2023 15:08:54 +0000 (15:08 +0000)]
dpdk-cryptodev: enq/deq scheme rework
This rework tries to address issues found on SPR QAT, for traffic
reaching max possible throughoutput for single QAT PF packet drops were
observed.
Fix changes enq/deq scheme by utilizing software ring in enq call from
VNET but enq and deq to QAT happens only in deq callback function what
should enable better utlization of hardware resources.
Type: improvement
Signed-off-by: Dastin Wilski <dastin.wilski@gmail.com>
Signed-off-by: Piotr Bronowski <piotrx.bronowski@intel.com>
Change-Id: I2e8c473d20a269fd5e93f0c8d1f8c8aa193712bd
Florin Coras [Wed, 14 Jun 2023 18:15:36 +0000 (11:15 -0700)]
vcl: no hup events in lt mode if session not epolled
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I9f7dfe086bf7e11b7e0de7392f020c1052ba656a
Dave Wallace [Mon, 12 Jun 2023 20:33:55 +0000 (16:33 -0400)]
tests: Run interface tests as a regular test
Type: test
Change-Id: I5cf5a0e6437b274e565066f1012d7225c62b87a8
Signed-off-by: Naveen Joy <najoy@cisco.com>
Florin Coras [Wed, 14 Jun 2023 00:18:56 +0000 (17:18 -0700)]
vcl: fix debug logging of mapped segments
Type: improvement
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I73034cdba51157466713884c3fbeae7054d92ad7
Shmuel Hazan [Tue, 13 Jun 2023 10:55:04 +0000 (13:55 +0300)]
af_xdp: linearize buffer chains before TX
The af_xdp plugin does not support chained buffers; attempting to send
chain buffers will result truncated packets or even send other packet's
data. As a workaround, turn any buffer chain into a single buffer before
tx.
Type: fix
Change-Id: I05dec912455eb2bb6c8122a28cd646f88983aa9a
Signed-off-by: Shmuel Hazan <shmuel.h@siklu.com>
Dave Wallace [Tue, 6 Jun 2023 16:05:30 +0000 (12:05 -0400)]
vppapigen: fix crash with autoendian arrays
Type: fix
Ticket: VPP-2078
Change-Id: I418269632bdfc823c5f0ba7652957277276d294d
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Piotr Bronowski [Fri, 9 Jun 2023 14:22:40 +0000 (14:22 +0000)]
dpdk-cryptodev: introduce sw_ring
This patch introduces sw_ring. This ring is used in next set of patchas
and plays role of a buffer for QAT, allowing collecting frame elements
in case QAT queue is fully utilized, and assembling frame
from QAT dequeued elements.
Type: improvement
Signed-off-by: Piotr Bronowski <piotrx.bronowski@intel.com>
Signed-off-by: Dastin Wilski <dastin.wilski@gmail.com>
Change-Id: I20718e200986ab4dba5cbc31c05a904072a6981a
Artem Glazychev [Thu, 1 Jun 2023 04:18:13 +0000 (11:18 +0700)]
af_xdp: set frame_no_append flag
Make sure the same frame is not used for multiple interfaces, otherwise it breaks the ETH_INPUT_FRAME_F_SINGLE_SW_IF_IDX promise.
Type: fix
Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
Change-Id: I02546259ceaea36f65cb9f78b9b3ee45ed4075c9
Florin Coras [Fri, 9 Jun 2023 03:47:11 +0000 (20:47 -0700)]
tcp: cleanup next nodes and drop logic
TCP nodes consume the buffers so they have no nexts. To avoid long drop
path through vlib graph, add drop node.
Type: improvement
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ibe6e075e83612ed16270934398c6a013f236ae35
Florin Coras [Mon, 5 Jun 2023 21:58:15 +0000 (14:58 -0700)]
svm: convert fifo want_deq_ntf ops to atomics
Type: improvement
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Iba2e4de24ff0724e31859f5d2f4ffa3cfe2cf284
Filip Tehlar [Thu, 8 Jun 2023 16:30:37 +0000 (18:30 +0200)]
hs-test: increase test run timeout
Type: test
Change-Id: Ica211c79373777c3352d6ccbb619c0d67b70fa06
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Filip Tehlar [Thu, 8 Jun 2023 15:39:39 +0000 (17:39 +0200)]
hs-test: rename address allocator
Type: test
Change-Id: I1745719315d4e0785df5a03aa4312f84c40cb18f
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Mohammed Hawari [Wed, 7 Jun 2023 08:15:05 +0000 (10:15 +0200)]
misc: fix INFO.yaml mistakes
Change-Id: If4e7911788b6aab67672b7e7228ecbdb402a85d5
Type: fix
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Benoît Ganne [Thu, 2 Dec 2021 15:06:12 +0000 (16:06 +0100)]
af_xdp: make sure all packets are transmitted
AF_XDP socket will only tx enqueued packets up to a max batch size so
we need to retry until everything has been sent.
Type: fix
Change-Id: Ia487ab63d3e85a478471cd1d679c5fb471804ba3
Signed-off-by: Benoît Ganne <bganne@cisco.com>
gaoginskx [Mon, 7 Jun 2021 11:07:01 +0000 (12:07 +0100)]
crypto: use fixed crypto frame pool
The async frames pool may be resized once drained. This will cause 2 problems: original pool pointer is invalidated and pool size changed, both problems will confuse the crypto infra user graph nodes (like IPsec and Wireguard) and crypto engines if they expect the pool pointers always valid and the pool size never changed (for performance reason).
This patch introduces fixed size of the async frames pool. This helps zeroing surprise to the components shown above and avoiding segmentation fault when pool resizing happened. In addition, the crypto engine may take advantage of the feature to sync its own pool/vector with crypto infra.
Type: improvement
Signed-off-by: Gabriel Oginski <gabrielx.oginski@intel.com>
Signed-off-by: Piotr Bronowski <piotrx.bronowski@intel.com>
Change-Id: I2a71783b90149fa376848b9c4f84ce8c6c034bef
Artem Glazychev [Mon, 5 Jun 2023 08:02:46 +0000 (15:02 +0700)]
af_xdp: remove the previous program before loading a new one
Otherwise, we will get an error. The program could remain from the previous run.
Type: fix
Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
Change-Id: I68e4072bd3b327592013804d67ccab7eb0ed3a0e
Florin Coras [Fri, 2 Jun 2023 04:50:03 +0000 (21:50 -0700)]
vcl: fix epoll ctl frequent deq ntf requests
SVM_FIFO_WANT_DEQ_NOTIF_IF_FULL should be treated as a
config option that is not frequently changed. Or alternatively, it
should be set together with SVM_FIFO_WANT_DEQ_NOTIF to elicit a one time
tx notification.
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ie4132c7789ee87227a875ff981eb98f9f4d898a9
Mohsin Kazmi [Mon, 5 Jun 2023 16:15:38 +0000 (16:15 +0000)]
misc: fix the license header
Type: style
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I6b3ecf0bdb6cfdf260cf4ccae89b6bc2335ff54c
Florin Coras [Mon, 5 Jun 2023 17:24:56 +0000 (10:24 -0700)]
vcl: avoid duplicate tx events with epoll lt
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ic6436426ead561e47fb77ed9a95afbd85f2998ae
Benoît Ganne [Mon, 5 Jun 2023 08:02:29 +0000 (10:02 +0200)]
udp: improve port validity check
- do not allocate port sparse vector when only checking if a port is
already in use
- do not display port that have been unregistered by default
Type: improvement
Change-Id: I6cc94e35806dd8d415cd5d1c1c51e6b066ac26a1
Signed-off-by: Benoît Ganne <bganne@cisco.com>
Pim van Pelt [Sun, 21 May 2023 06:35:26 +0000 (08:35 +0200)]
linux-cp: Fix add vs update on routes
Linux uses NLM_F_REPLACE in the netlink message to signal a FIB update
The code invariably does a FIB update for IPv4 and a addition for IPv6.
Without this fix, the following:
ip route add 2001:db8::/48 via 2001:db8::1
ip route replace 2001:db8::/48 via 2001:db8::2
ends up as two separate FIB entries in VPP. With the fix, there will be one FIB entry (the second one with nexthop ::2).
Type: fix
Change-Id: I8f98d6ded52ae0c60bfddaa7fc39acbbaa19d34a
Signed-off-by: Pim van Pelt <pim@ipng.nl>
Mohammed Hawari [Fri, 2 Jun 2023 13:10:32 +0000 (15:10 +0200)]
misc: update INFO.yaml
Change-Id: I55ea2c11148421aef8f891829671d88be171daa2
Type: improvement
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Florin Coras [Mon, 29 May 2023 23:19:38 +0000 (16:19 -0700)]
vcl: refactor want deq ntf checks for null fifos
Type: refactor
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I5d0445ca381f1a4943bb2fe454433b3454043b56
Florin Coras [Thu, 1 Jun 2023 16:11:27 +0000 (09:11 -0700)]
session: cleanup cless listeners from session lookup
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Change-Id: I46b8194ff00c6a0a4a2bc19df9991f037856cede
Alexander Chernavin [Wed, 29 Mar 2023 16:09:37 +0000 (16:09 +0000)]
wireguard: add support for chained buffers
Type: feature
With this change, packets that are larger than a single buffer can fit
will be able to be sent and received over a Wireguard tunnel. Also,
cover this with tests.
Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
Change-Id: Ifaf7325676d728580097bc389b51a9be39e44d88
Ondrej Fabry [Wed, 26 Apr 2023 22:00:20 +0000 (00:00 +0200)]
api: nat44_ed - Mark old message versions as deprecated
List of changed messages:
- nat44_add_del_static_mapping
- nat44_user_session_dump
- nat44_user_session_details
- nat44_user_session_v2_dump
- nat44_user_session_v2_details
This change is part of VPP API cleanup initiative.
Type: fix
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
Change-Id: I317ae93a0e763c3759a8c24fd550e1c97f6f4987
Filip Tehlar [Wed, 31 May 2023 10:26:59 +0000 (12:26 +0200)]
hs-test: fix vcl test parameter
Type: test
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Change-Id: Ieb6e46439d8e66a792f9c508e7dc49ecdd392487
Xiaoming Jiang [Thu, 9 Mar 2023 02:03:50 +0000 (02:03 +0000)]
crypto: make crypto-dispatch node working in adaptive mode
This patch can make crypto dispatch node adaptively switching
between pooling and interrupt mode, and improve vpp overall
performance.
Type: improvement
Signed-off-by: Xiaoming Jiang <jiangxiaoming@outlook.com>
Change-Id: I845ed1d29ba9f3c507ea95a337f6dca7f8d6e24e
Stanislav Zaikin [Wed, 31 May 2023 12:30:44 +0000 (14:30 +0200)]
fib: fix memory leak in fib_attached_export_purge
Type: fix
Change-Id: I879594fcade4e081190e8dfb1dbcfc53e8431edf
Signed-off-by: Stanislav Zaikin <stanislav.zaikin@46labs.com>
Maxime Peim [Fri, 26 May 2023 07:52:35 +0000 (07:52 +0000)]
misc: fix tracedump API
In some cases, in the trace dump v2 dump function, we iterate over the
client cache even though this one could be empty.
Type: fix
Change-Id: Ice5cefa25bb93dabe86fe565347cdc32faa674ac
Signed-off-by: Maxime Peim <mpeim@cisco.com>
Mohsin Kazmi [Wed, 24 May 2023 11:25:39 +0000 (11:25 +0000)]
virtio: fix the packet buffering initialization order
Type: fix
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: Idada695432d2bfac8808f35f1e8cd16f84d963c6
Mohsin Kazmi [Wed, 22 Jun 2022 12:25:51 +0000 (12:25 +0000)]
libmemif: add testing application
Type: test
This application creates two memif interfaces which connect
to an external application i.e. VPP.
Usage:
1) Start VPP with following config.
create interface memif id 0 master
create interface memif id 1 master
set int state memif0/0 up
set int state memif0/1 up
create packet-generator interface pg0
set int state pg0 up
create packet-generator interface pg1
set int state pg1 up
set int l2 xconn pg0 memif0/0
set int l2 xconn memif0/0 pg0
set int l2 xconn pg1 memif0/1
set int l2 xconn memif0/1 pg1
packet-generator new { \
name memif \
limit -1 \
node ethernet-input \
size 64-64 \
interface pg0 \
worker 0 \
data { \
IP4: 42:01:0a:00:00:0a -> 02:fe:4b:6e:4d:c1 \
UDP: 172.16.2.2 -> 172.16.0.2 \
UDP: 1234 -> 1234 \
length 30 checksum 0 incrementing 1 \
} \
}
2) Compile and Run the test_app in another terminal.
mkdir -p extras/libmemif/build
cd extras/libmemif/build
cmake ..
make
sudo ./examples/test_app
3) Run in VPP cli
vpp# packet enable
4) Run monitor to see the throughput and pps
vpp# monitor interface memif0/0
Or
vpp# monitor interface memif0/1
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I4b9062fca8ad3020225adb7b1b09e5d66b1a7d48
Xiaoming Jiang [Fri, 5 May 2023 02:28:20 +0000 (02:28 +0000)]
ipsec: fix ipsec_set_next_index set with wrong sa index when async frame commit failed
Type: fix
Signed-off-by: Xiaoming Jiang <jiangxiaoming@outlook.com>
Change-Id: Ib4c61906a9cbb3eea1214394d164ecffb38fd36d
Damjan Marion [Fri, 26 May 2023 19:08:38 +0000 (19:08 +0000)]
vppinfra: add bit_extract_u32 and bit_extract_u64
Type: improvement
Change-Id: Icfaa856aa4b50ad5c6828f1690ce3fb6ba08ec00
Signed-off-by: Damjan Marion <damarion@cisco.com>
Damjan Marion [Fri, 26 May 2023 19:01:29 +0000 (19:01 +0000)]
vlib: add foreach_vlib_frame_bitmap_set_bit_index to .clang-format
Type: improvement
Change-Id: I6b999bcc6394bcc9325de1568dba98d1eb5a7b15
Signed-off-by: Damjan Marion <damarion@cisco.com>
Damjan Marion [Fri, 26 May 2023 19:06:10 +0000 (19:06 +0000)]
vlib: add vlib_log_is_enabled
Type: improvement
Change-Id: I052e0d56cc6d89cd66c83a9bb81e2273d396d510
Signed-off-by: Damjan Marion <damarion@cisco.com>
Alexander Chernavin [Fri, 19 May 2023 15:43:06 +0000 (15:43 +0000)]
linux-cp: update adjs for subifs too when mac changes
The plugin creates and manages adjacencies for the physical interface in
each interface pair (they are part of the x-connect feature). When a
link update notification is received from the host system, MAC address
of the corresponding physical interface is updated (as needed) as well
as previously created adjacencies for it (because a new rewrite string
needs to be generated).
Subinterfaces inherit MAC address from the parent interface. When MAC
address of the parent interface changes, it also implies MAC address
change for its subinterfaces. The problem is that this is currently not
considered in the plugin. After MAC address update on the parent
interface, packets sent from subinterfaces might have wrong source MAC
address. For example, IPv6 Neighbor Solicitation messages will be sent
with the wrong (previous) MAC address and neighbor discovery will fail.
With this fix, when the plugin updates adjacencies for a physical
interface, it will also update adjacencies for the subinterfaces with
existing interface pair.
Type: fix
Change-Id: Ia5f617197e33cb79b9b025c02c2c126c31a551ec
Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
Xiaoming Jiang [Fri, 26 May 2023 00:32:25 +0000 (00:32 +0000)]
tls: fix memory leak when client/server init error
Type: fix
Signed-off-by: Xiaoming Jiang <jiangxiaoming@outlook.com>
Change-Id: I484f3759b6c27052e08741398ec389729285f035
Florin Coras [Thu, 25 May 2023 19:04:53 +0000 (12:04 -0700)]
udp: fix local port reuse check
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I323946f7838507110c663f5a904399a74fc76691
Filip Tehlar [Mon, 22 May 2023 13:48:51 +0000 (15:48 +0200)]
hs-test: add vcl echo tests
Type: test
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Change-Id: I3e543cb292c7ed0f9d240f8f2473a1db07aff0fd
Mohsin Kazmi [Fri, 5 May 2023 11:09:31 +0000 (11:09 +0000)]
hash: add hash documentation
Type: docs
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I36764aa3c0e9657d228413aeafa0a54bbd755e49
Andrew Yourtchenko [Wed, 24 May 2023 11:06:58 +0000 (11:06 +0000)]
misc: Initial 23.10-rc0 commit
Type: docs
Change-Id: Id9b0ca0d43db0e5a52fd9696a5cba77a6772db5b
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>