11078 Commits

Author SHA1 Message Date
Benoît Ganne
189383ddcc rdma: fix rdma-core install
We should not install symlinks to local build directory.

Type: fix

Change-Id: I81e624dd5775ec9c5dd8c58f578ee51c5acfef73
Signed-off-by: Benoît Ganne <bganne@cisco.com>
(cherry picked from commit 521a9f8eb9d35d2d8783175b89821c6a157237ca)
2021-11-30 14:11:52 +00:00
Andrew Yourtchenko
0385458a56 misc: 21.10.1 Release Notes
Type: docs
Change-Id: I4c9474f78c1226608e11ed4822b7fe091cb70c3e
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
v21.10.1
2021-11-17 13:45:25 +01:00
Matthew Smith
895a0a1fed ip6: set local flag on outbound echo reply
Type: fix

When VPP generates an ICMP echo reply in response to an incoming
echo request to a local address, set VNET_BUFFER_F_LOCALLY_ORIGINATED
on the buffer. It will prevent ip6-rewrite from decrementing the hop
limit.

Outbound IPv4 echo replies also get this flag set.

Change-Id: Iaa229294eb158edb58cf1bf1b7a90da281321406
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
(cherry picked from commit af50b4f727f6d9d85c722c39b459941e01a34217)
2021-11-16 15:43:45 +00:00
Benoît Ganne
48797d204f build: add missing fib headers in packages
Type: fix
Fixes: d6953332db225d5355f50348ef3b09f0525d5282

Change-Id: Ib85fee40e71ebe5bc2b84c62e37298b5e390d520
Signed-off-by: Benoît Ganne <bganne@cisco.com>
(cherry picked from commit d9fc708ee0c8c42fa09dda5d29e9cb0f985558dc)
2021-11-03 16:40:12 +00:00
Andrew Yourtchenko
0e0384cde9 misc: 21.10 Release Notes
Change-Id: I7aa0708d54156166f2dcdc8359e2450a3c4bf9af
Type: docs
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
v21.10
2021-10-27 12:39:32 +00:00
Joshua Roys
9298a7ec0c nat: fix static mapping segv
Adding a nat44 static mapping during startup on a DHCP interface leads
to a segv via this path:
- dhcp_client_acquire_address
- ip4_add_del_interface_address
- ip4_add_del_interface_address_internal
- nat44_ed_add_del_interface_address_cb
- nat44_ed_add_static_mapping
- ip4_interface_first_address

Type: fix

Signed-off-by: Joshua Roys <roysjosh@gmail.com>
Change-Id: I38dac8a096b052550f2b87b4e13a950d2cd868b0
(cherry picked from commit f9074fc51544d1849a2df06713c1ccf6cb2eb908)
2021-10-25 19:53:58 +00:00
Florin Coras
c1931b2f09 vcl: grab wrk create lock sooner
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I0faeef20c57486564122e39f01f31c8c45f38014
(cherry picked from commit 94fef3e67662c6a92e32164d8db6fcf4bc83e79e)
v21.10-rc2
2021-09-24 16:37:13 +00:00
Andrew Yourtchenko
fd9d936b3c misc: Initial changes for stable/2110 branch
Change-Id: Ib3bf8f46a987324be4c7f016b96027558e9d58ef
Type: docs
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
v21.10-rc1
2021-09-23 14:52:28 +02:00
Aloys Augustin
87f478be88 wireguard: fix wg-output-tun feature configuration
The removed code caused the feature to be wrongly removed on the wg
interface.

Type: fix
Signed-off-by: Aloys Augustin <aloaugus@cisco.com>
Change-Id: I998e01ec231527128eaeae78bcc7576ac00e5b12
2021-09-23 12:16:03 +00:00
Florin Coras
d60b432b13 svm: remove unused fifo functions
Type: refactor

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I4525bc669d1c42c41dbc398cf239a093b6853298
2021-09-23 12:15:47 +00:00
Ray Kinsella
5161c4ab57 stats: revert stat_validate_counter_vector3 non-static
This reverts commit c30157811e4c8e870d2680b08ecd3a38dff2d53b.

Type: refactor

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: Id011c8e5acb1613e09fd339ce614159c0acd651a
2021-09-23 06:57:08 +00:00
Mohsin Kazmi
a7d2aabae8 tap: remove cxq_vring from tap/tun
Type: fix

virtio_if_t is shared data struct between tap, tun and virtio pci.
cxq_vring is virtio pci specific element. It shouldn't be set or
accessed in tap driver.

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I8b34570f61b38d8b9d79d5b0669bda0f89ebc28c
2021-09-22 20:22:05 +00:00
Mohsin Kazmi
e4efbe73a3 virtio: fix the type of argument in virtio_show()
Type: fix

virtio have three different interfaces (tap, tun and native virtio).
virtio_show() is used by CLI commands to show information about these
interfaces. It uses interface type to print interface specific information.
virtio_show() should use proper type for virtio interfaces (TAP, TUN, VIRTIO).

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I2043dc2cfe2e2f6c7c9348b8494aa4a27cab31f3
2021-09-22 20:19:45 +00:00
Artem Glazychev
0455431a00 ping: set fib_index for lookup_node
lookup node uses this field later to set fib_index for buffer

Type: fix

Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
Change-Id: I993cf80296e1713b4f13fc6ccdf49ebeaf295467
2021-09-22 16:59:10 +00:00
Neale Ranns
e619ada151 interface: allow an interface's index to be given in 'sh int'
Type: improvement

e.g.:
DBGvpp# sh int 3
              Name               Idx    State  MTU (L3/IP4/IP6/MPLS)     Counter          Count
loop2                             3     down         9000/0/0/0

Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: Ie296167ab2b1b9576b46f6d4d9fb9546aef3a0da
2021-09-22 14:32:22 +00:00
Fan Zhang
c0d64ace0e misc: update MAINTAINERS file
Type: improvement

Add myself as maintainer for crypto related components.

Signed-off-by: Fan Zhang <roy.fan.zhang@intel.com>
Change-Id: Ib43bd30b69c52c6370e3dda9ad9ed9a04374d817
2021-09-22 14:30:58 +00:00
Mohsin Kazmi
ef356f57b5 hash: fix the initialization warning error on gcc-10
Type: fix

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: Ic7d99154def71cd06e8faa64180912e5b844424e
2021-09-22 09:59:49 +00:00
Aloys Augustin
6e4cfb5068 ip: add ip_table_allocate to api
Set tableID = ~0 for auto selection unused ID

https://jira.fd.io/browse/VPP-1993

Type: improvement
Change-Id: I4eec2cc1d18fc025196cb6ac4c9a4b374388eb56
Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
Signed-off-by: Aloys Augustin <aloaugus@cisco.com>
2021-09-22 09:02:18 +00:00
Damjan Marion
c3b62d1d13 classify: improve vnet_classify_hash
Type: improvement
Change-Id: I8b129b71f91b12ab2d8b05fe3891a7ab8926f072
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-09-22 08:30:01 +00:00
Damjan Marion
c31a234d5c classify: simplify vnet_classify_find_entry_inline
Type: improvement
Change-Id: I3de4450b95f6fa76705923d983cf93c21b02a635
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-09-22 08:29:48 +00:00
Damjan Marion
ff011b2560 vppinfra: make default hugepage size configurable
i.e.

memory {
  default-hugepage-size 1G
}

Type: improvement
Change-Id: I822afb51712ae92f4e4992b8ffa33dcb15ccaef1
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-09-22 08:29:23 +00:00
Mohammed Hawari
266929f2e4 interface: fix poll vector realloc
Change-Id: I60815b5827b4406228fd6b490f4ac1f874bac974
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Type: fix
2021-09-22 08:24:04 +00:00
Andrew Yourtchenko
5aa06abf24 pnat: fix the version of the PNAT plugin from the hardcoded 0.0.1
Type: fix
Change-Id: I35db6763f3c5bd73169a222a4a93a917e8f468e6
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Signed-off-by: Ole Troan <ot@cisco.com>
2021-09-21 15:35:07 +02:00
Arthur de Kerhor
b2819dd20e vapi: compile vpp-api folder before the plugins
Allows to use vapi symbols in a plugin.

Type: feature
Change-Id: Ic4534f266964127af54651b7d19c3b611b277860
Signed-off-by: Arthur de Kerhor <arthurdekerhor@gmail.com>
2021-09-21 08:03:57 +00:00
Nathan Skrzypczak
b3ea73e766 session: implement app_ns deletion
Type: feature

Change-Id: If0edbb21a0283d66c648a9e190d238c8cfa56353
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-09-21 05:13:26 +00:00
Damjan Marion
a9f5f85c95 classify: improve find entry performance
Type: improvement
Change-Id: I5245fc3f35b7a70833916db2ebf33f7c87398915
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-09-20 17:44:10 +02:00
Damjan Marion
3bb2da9cb1 classify: avoid dependent read of classify mask
Type: improvement
Change-Id: I176f08c74eb58a78f7fbdb48fd4592e6ddf74d34
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-09-20 17:44:10 +02:00
Nathan Skrzypczak
3d5e74172d session: use table_format in sh app ns
Type: refactor

Change-Id: I99162d80280e0f45344671b18b1ea96db90d4282
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-09-20 14:57:11 +00:00
Nathan Skrzypczak
8430b8de1d vppinfra: format table improvements
This adds a way to define default fg, bg colors
and alignement for cell tables.
It also allows removing the table title by not
setting it.
It also removes the trailing newline, for usage
inside a format("%U", format_table, ...)

Type: improvement

Change-Id: I27d7a04c4a919b34d0170b04e24a56831f581ea1
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-09-20 11:26:03 +00:00
Mohsin Kazmi
41b23bc955 hash: add support for hashing infra
Type: feature

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I3652ae275385d9b1eb1b11f418e3a7e5fef2f556
2021-09-20 11:11:02 +00:00
Nick Brown
e3cf4d0cf3 build: use GNUInstallDirs install destinations
So as to be compliant with distribution layouts, as recommend by:
https://cmake.org/cmake/help/latest/command/install.html#installing-files

Type: make
Change-Id: Ic46ace4f26aab1aa4902cbd013c40a92c480680d
Signed-off-by: Nick Brown <nickbroon@gmail.com>
2021-09-17 20:25:49 +00:00
Benoît Ganne
8b99777263 dpdk: enable ENA tx offload
Type: improvement

Change-Id: Ic7c2ac4237ecd192def7c3530ae5f788c62cf9ad
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-09-17 20:12:22 +00:00
Nathan Skrzypczak
0e6584014a vppinfra: move format_table from perfmon
This code seems really usefull for reuse in
other plugins, for pretty table formatting

Type: feature

Change-Id: Ib5784a0dfc81b7d5a5d1f5ccdd02072e460a50fb
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-09-17 20:10:59 +00:00
Damjan Marion
a274c3a2ed misc: put devtools plugins into separate component/package
Type: make
Change-Id: I2958e9eddadee6434766ecd3cdb3b9cea742ed64
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-09-17 15:04:28 +00:00
Mohammed Hawari
9db198556c ebuild: cleanup of DPDK options in external.mk
With the move to meson, most DPDK options in external.mk are not used
anymore

Type: improvement
Change-Id: I603ccd30c9e52bdc89a69aa4bece2394b3eed1fe
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
2021-09-17 14:59:23 +00:00
Steven Luong
d26a582759 memif: avoid double pool_put on a clib_file
When memif CP processes the socket connection error, it may go through
the following code paths which may eventually cause double pool_put on a
clib_file

memif_master_conn_fd_error:633 -> memif_disconnect ->
memif_socket_close -> memif_file_del_by_index ->
clib_file_del_by_index -> clib_file_del -> pool_put

After memif_master_conn_fd_error:633, the code continues on

memif_maser_conn_fd_error:651 -> memif_file_del -> clib_file_del ->
pool_put

The fix is to skip calling memif_file_del in
memif_master_conn_fd_error:651 if uf->file_descriptor == ~0 to catch
problem from all possible paths in memif_master_conn_fd_error

Type: fix

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I0960998db1ff358a8ddd4a5e22188a244eccd270
2021-09-17 14:57:33 +00:00
Florin Coras
91db3538c9 dpdk: fix checksum offload
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I89fb738903ee74ffcb7c77a041391f0388df6991
2021-09-16 20:50:12 -07:00
Benoît Ganne
895def45c8 avf: fix RSS hash key
Toeplitz hash key must respect certain properties, it cannot be purely
random. Use the default one from i40e.

Type: fix

Change-Id: Ic8e67a0426de8adfecc1fcdaa99879e13ae38cc9
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-09-16 14:23:53 +00:00
Nathan Skrzypczak
1a9e2f96d4 session: Add sock_name option to add_ns
This adds a new API call to add session namespaces
It now takes a netns and a sock_name.
(1) If no netns is passed, sock_name will be used as
socket path. Defaulting to /run/vpp/app_ns_sockets/${ns_id}
(2) If a netns is passed, the sock_name has to be
abstract (i.e. start with '@'). It will default to
`@vpp/session/${ns_id}` and will be created in the provided
netns.

Type: feature

Change-Id: I90e9a8e5ecca2cabe7c05335663e33c8506dc9e7
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-09-16 14:14:38 +00:00
Mohsin Kazmi
4fd9f10c45 vxlan: improve to use the hardware offload
Type: improvement

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: Ic0fa4f83048a280a7d1b04198c0f903798562d2d
2021-09-16 10:43:56 +00:00
Mohsin Kazmi
64dd1720e5 dpdk: add support for outer udp and ipv4 checksums
Type: improvement

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I10141033030342881298d70742fa5bdea402b4c9
2021-09-16 10:42:59 +00:00
Mohsin Kazmi
82f9444dbe dpdk: fix the outer ipv4 checksum
Type: fix

Change-Id: Ibc476b807ba0310f0cc926b0e386831ef0cbcc25
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2021-09-16 10:40:15 +00:00
Mohsin Kazmi
cebb477339 ip6-nd: add ip6-nd proxy
Type: feature

Change-Id: I91f72f5802db195d1a15424d67c1b6e518168f9f
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2021-09-16 07:12:13 +00:00
Damjan Marion
ef4ddfa482 vlib: add option to plugin registration to prefer deep binding
Type: improvement
Change-Id: I9ce7e1ee7e7afe8e9befe36ae8c59291beaaaf36
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-09-15 15:15:40 +02:00
Duncan Eastoe
764a8780c2 tap: set device name on creation via TUNSETIFF
Type: fix

Currently when a new TAP/TUN device is created from tap_create_if()
via the TUNSETIFF ioctl(), a name is allocated by the kernel (eg.
tap0). If the caller supplied a name this is subsequently set via
netlink, after the device has been created.

Now we request the kernel to create the new device with the caller's
requested name in the first instance, thus avoiding the need to
rename the device, and therefore avoiding a window where the device
exists with a different name.

This can be beneficial, for example, when writing systemd-udevd link
files [1]. Having the TAP/TUN devices created with the requested name
ensures they can be correctly matched by the OriginalName option.

Writing link files might be necessary, for example, to avoid VPP and
systemd-udevd racing to set the MAC address on a newly created TAP
interface. systemd-udevd can be configured to not manipulate the MAC
addresses of matched interfaces.

These changes also resolve an issue where the created device would not
be renamed if the caller requested it be moved to a different network
namespace, since vnet_netlink_set_link_name() was not called in that
case.

[1] https://www.freedesktop.org/software/systemd/man/systemd.link.html

Signed-off-by: Duncan Eastoe <duncan@graphiant.com>
Change-Id: I3d657632856d03979d6b914225c3c841c379e0a1
2021-09-15 12:58:35 +00:00
Pierre Pfister
c26cc72edf vlib: add graceful termination with status
This commit allows a non-VPP thread to request VPP to gracefully
shutdown and return a specific process status value.

Type: improvement
Change-Id: I9bf52b789e7ee28eb272630eaea495fd94349f79
Signed-off-by: Pierre Pfister <ppfister@cisco.com>
2021-09-14 14:42:07 +00:00
Mohammed Hawari
46e020183e misc: volunteer as extra maintainer for DPDK
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Change-Id: I97fa566612641f78c2e9850a251cfe9f2d7cfde1
Type: docs
2021-09-14 06:52:10 +00:00
Nathan Skrzypczak
7854b46f77 interface: fix init fib_index_by_sw_if_index
Type: fix

The init of fib_index_by_sw_if_index wasn't
setting default value to 0. Which we now
need for setting interfaces unnumbered

Change-Id: Ie5be9b5e5373ef055557a871ad4d1c45fbfc1dee
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-09-13 13:54:59 +00:00
Tianyu Li
006bbc4945 snort: fix epoll_wait unsigned return value
When epoll_wait return -1, access array epoll_events[i] out of bound
and lead to segmentation fault.

1. Change return value to signed return value
2. Skip non fatal error e.g. EINTR

Type: fix
Signed-off-by: Tianyu Li <tianyu.li@arm.com>
Change-Id: I4ece118999402ec6054baf0efb52419151655def
2021-09-13 13:44:24 +00:00
Florin Coras
596c45b222 tcp session: initialize sw_if_index at connect time
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Id0e67a9ce9c5d8bca2cd7a30493f03a02a46dc46
2021-09-13 13:39:18 +00:00