10042 Commits

Author SHA1 Message Date
Mohammed Hawari
b78607b1db build: do not _FORTIFY_SOURCE in debug mode
When compiling in -O0, the glibc feature.h ignores _FORTIFY_SOURCE and,
in some distributions, throws a #warning, which fails the build. This
patch removes -D_FORTIFY_SOURCE in all debug configurations.

Change-Id: Ic30229c038353e49ff9419779e082a7083c1ea5f
Type: fix
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
2021-01-28 08:38:21 +00:00
hemant_mnkcg
27df797978 Change unformat_init_string API in doc to match code
Signed-off-by: hemant_mnkcg <hemant@mnkcg.com>
Change-Id: I4ec487054f928d52fe06d530df095b30edf66ae5
2021-01-27 20:43:29 +00:00
Steven Luong
d6361c7b89 vhost: vhost interface hardware address not set
The check args->hwaddr is always true and it always copies the
mac address from args->hwaddr even though none was set.

Check args->use_custom_mac instead.

Type: fix
Fixes: gerrit 29970

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I0c51bf1ea79b02c4fbdc3c52e694f186bdd96600
2021-01-27 16:47:03 +00:00
Filip Tehlar
68d2753569 ikev2: add per SA stats
Type: feature

Change-Id: Ic502d806410ea3c8f3f1eac70b694114ccb053bf
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2021-01-27 11:35:35 +00:00
Florin Coras
1b9d2c2c9d session: clear ct fifo flag prior to notification
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I6db15780d87426eee852aa020c50cbdf45dc1f95
2021-01-26 22:11:01 +00:00
Mohammed Hawari
b85b0df2a0 interface: remove vnet_device_input_runtime_t
Change-Id: I85a463b4ca15baf11e3eb70189f5190ba2585170
Type: refactor
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
2021-01-26 21:45:20 +00:00
Dave Barach
832a316526 misc: fix snap image build
Clean up snapcraft.yaml bit rot, switch to Ubuntu 20.04, add README.md

Type: improvement

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: I2e0d3925cf43541e70b59083f8c91af539aa34e6
2021-01-26 16:07:53 +00:00
Florin Coras
86f1232dde svm: add custom q implementation for mq
Add separate queue implementation for the message queue as it's custom
tailored for fifo segments as opposed to binary api.

Also move eventfds to the private data structures.

Type: refactor

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I6df0c824ecd94c7904516373f92a9fffc6b04736
2021-01-25 15:34:21 +00:00
Benoît Ganne
15036ad0bc vlib: add show trace limit warning at the end of output too
Users tend to miss the warning too often, add it to the end of the
output in hope it would be easier to catch.

Type: improvement

Change-Id: I264df7e3b6ab1ffb1a383807f4444d9cbaf40999
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-01-25 12:12:02 +00:00
Benoît Ganne
566b427b05 crypto-ipsecmb: more explicit errors reporting
Use error counters related to ipsec-mb return codes instead of
'bad-hmac' only.

Type: improvement

Change-Id: I9329da300a70d76b4d4ab30fa45f0a2a85d6519b
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-01-25 08:54:24 +00:00
Radu Nicolau
5a48b3b9d8 vlib: startup multi-arch variant configuration fix for interfaces
Propagate the multi-arch variant selection to interfaces.

Type: fix

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Change-Id: I99c4a7896f172f0d14d2ded22a27383825529a7d
2021-01-25 08:37:40 +00:00
Benoît Ganne
78de92de0d svm: use standard function to reset stale mutex
Avoid accessing the private data structure of mutexes which is
implementation-dependent, eg. musl is different from glibc.

Type: improvement

Change-Id: I20ec0c1c9faef0749d89a1969cd2430c80ac04b3
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-01-24 02:36:16 +00:00
Mathias Raoul
2e4523816c quic: quicly v0.1.2 update
- update quic plugin with new quicly/picotls API
- remove packet allocator
- remove crypto batching
- update picotls plugin
- add cli for quicly congestion control configuration

Type: feature

Change-Id: If76ef31c43b430eea2f7674539b2112aee0f351e
Signed-off-by: Mathias Raoul <mathias.raoul@gmail.com>
2021-01-22 16:06:48 +00:00
Andrew Yourtchenko
06f328129a tests: add generalized tags for tests, use them for run-solo tests
We have accumulated several scenarios in prod or wishlists
where it would be useful to have a general infra to say yes/no
about a certain test, and potentially make decisions based on that,
for example:

- runs solo (aka 'time-dependent')
- (wishlist) part of quick smoke-test set
- (wishlist) intermittent failure unrelated to timing
- (wishlist) test broken with a multi-worker config in vpp

Refactor the current "run-solo" code to allow for this extension.

Type: test

Change-Id: Ia5b3810e57c0543753c8e0dc4dc0cfb4a30b36ac
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2021-01-22 15:35:11 +00:00
Dave Barach
b8f6122b4f docs: vpp stateless traffic generator
Add a use-case writeup.

Type: docs

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: Ib6e79e80455edbdeedcc96943dd98f16c57c559e
2021-01-22 14:02:27 +00:00
Mohammed Hawari
9fecbe1841 interface: fix rx-placement api/cli for new infra
Change-Id: Ic977ffe761efc2129c61aec581da5479fe4838da
Type: fix
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
2021-01-22 09:06:47 +00:00
Mohammed Hawari
e848c8fb8c interface: let drivers control polling when down
Change-Id: I03e164d8d5a329497f422e99f8b0058135241b4e
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Type: fix
2021-01-22 09:06:32 +00:00
Mohammed Hawari
85c1943e52 devices: adapt af_packet to new rxq framework
Change-Id: If8077280cef501599f810ad9255efa2a5a451ced
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Type: improvement
2021-01-22 09:06:15 +00:00
Mohammed Hawari
313380f950 interface: fix vnet_hw_if_update_runtime_data
Take into account pending interrupts when resizing rxq_interrupts

Type: fix
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Change-Id: I64f6f4404738c90ed5a2c10d72c7ce59cf96a644
2021-01-21 15:59:38 +00:00
Jakub Horn
91f4a97955 sr: SRv6 FlowLabel Added
Type: improvement

Signed-off-by: Jakub Horn <jhorn@cisco.com>
Change-Id: I06401a8645615d139893dca27d07bb3b3214bea7
2021-01-21 15:53:25 +00:00
Somnath Kotur
09332e9bc0 dpdk: do not use TSO for small packets
Asking for TSO (TCP Segmentation Offload) on packets that are already
smaller than (headers + MSS) does not make sense and may not work
on some HW.
Fix to only set the TSO flag when a segmentation offload is
really required, i.e when packet is large enough.

Type: improvement

Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Change-Id: I7830ae8474581c8e518fb4910f7863e10346bb62
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
2021-01-21 13:40:42 +00:00
Radu Nicolau
e1480a2c12 avf: use write combining store for queues tail update
Performance improvement: on supported platforms, currently only Intel Tremont,
use a write combining store to update the tail pointers.
Also, Tremont node variant is added for all.

Type: improvement

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Change-Id: Ie9606e403b7d9655184f778e3ffee3027c8c9edd
2021-01-21 13:39:12 +00:00
Jakub Grajciar
f35fef2446 libmemif: buffer enqueue refactor
Refactored memif_buffer_enq_tx - dequeue buffers from any queue (rx/tx) and
enqueue them to any tx queue.

Added memif_buffer_requeue - swap descriptors of provided buffers.

Type: refactor

Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
Change-Id: I8482824df920aaaf8325d52a297ed57a815aaba6
2021-01-21 13:33:44 +00:00
Chenmin Sun
9b8121cdc0 dpdk: dpdk i40e patch cherry-pick
This patch fixes flex payload flow creation failure issue

Type: fix

Signed-off-by: Chenmin Sun <chenmin.sun@intel.com>
Change-Id: I3ac0a168dadd033a668d7bd6f5e78798aedb61a5
2021-01-21 13:32:37 +00:00
Mohammed Hawari
b80b640a62 rdma: adapt to new vnet rxq framework
Change-Id: Id539d36635f0ab9625dc2fc73630be39bead09af
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Type: improvement
2021-01-21 13:31:40 +00:00
Benoît Ganne
aea54eb912 ip: do not return uninitialized IPv6 ll attributes
Type: fix

Change-Id: If35cf7da0c3d1b92532cc2e45c164d6b5a08592c
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-01-21 13:31:15 +00:00
Mohammed Hawari
7559418657 memif: adapt to new rxq framework
Change-Id: Ifa8bccd8a34ec1b14e772ee53757e9083373e3de
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Type: feature
2021-01-21 13:25:05 +00:00
Benoît Ganne
426a306cc1 af_xdp: update interrupt mode to new infra
Type: improvement

Change-Id: Icb23af5f5e458a555f416cb0a829e84646b25dd9
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-01-21 13:22:40 +00:00
Mohammed Hawari
692b52dca6 marvell: adapt pp2 to new rxq framework.
Change-Id: I8759a07a24692b8b418ef8eb2025b61a62d2dda1
Type: improvement
Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
2021-01-21 13:22:27 +00:00
Damjan Marion
941005336e interface: rx queue infra rework, part one
Type: improvement
Change-Id: I4008cadfd5141f921afbdc09a3ebcd1dcf88eb29
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-01-21 13:20:10 +00:00
Ray Kinsella
1e4309538d perfmon: added cache hits and misses
Added basic support for counting cache hits and misses per node.

Type: improvement

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: Ic566611fd3d4246ccaa2117d8f74a569a6862e80
2021-01-21 13:17:47 +00:00
Matthew Smith
38b63a30ca dpdk: terminate device devargs string
Type: fix

When a device is whitelisted with devargs arguments specified, the
string that is generated and added to conf->eal_init_args is not
explicitly terminated with 0. If the formatted string takes up all
of the memory allocated to the vector which stores it and it is
used later as a string in a format() or printf() call, any nonzero
characters stored in memory at the address immediately following the
memory allocated for the vector will be erroneously appended to the
string.

Terminate the string with 0 to ensure that this does not happen.

Change-Id: I20a78d994daad93bf5aecab5c03d705022e882ec
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2021-01-21 13:16:58 +00:00
Dave Wallace
cfa8a89338 build: deprecate debian-9 support
Type: make

Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: Ib14ce5561446aefb03c3989cf82ac7c6eb1471bb
2021-01-21 13:16:09 +00:00
Nathan Moos
f15a5791ba dpdk: add support for system libdpdk
Type: improvement

This patch enables dynamically linking the dpdk plugin against a
system-wide packaged version of dpdk.

Change-Id: I2276d125f39986b0e1788c7b52b94485cdbcd855
Signed-off-by: Nathan Moos <nmoos@cisco.com>
2021-01-21 13:11:14 +00:00
Nathan Moos
323418dd1c vppinfra: ensure _GNU_SOURCE is present
Type: fix

When building with musl, _GNU_SOURCE is required to be defined in more
places. This patch defines it in those required places. Additionally,
this patch changes the udphdr field names to the standard names.

Change-Id: I0fec54214ccc8458289176488afb4218761e9d51
Signed-off-by: Nathan Moos <nmoos@cisco.com>
2021-01-21 13:08:57 +00:00
Neale Ranns
1523c96deb ip: Use correct enum type in ip_address_set
Type: refactor

Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: Ice2bc42838e6d5ba579f449c3f8b0feffebeb719
2021-01-21 11:00:14 +00:00
Ahmed Abdelsalam
f2984bbb01 ip: use IPv6 flowlabel in flow hash computation
extends ip6_compute_flow_hash() to include IPv6 flowlabel in flowhash computation

Type: improvement

Signed-off-by: Ahmed Abdelsalam <ahabdels@cisco.com>
Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
Change-Id: Id1aaa20c9dac729c22b714eea1cdd6e9e4d1f75e
2021-01-21 10:59:46 +00:00
Neale Ranns
03fabbd222 ipsec: Honour IPSec SA table-ID over API
Type: fix

Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: Ib08fe356e4dc710dd60a96736c48b27129f06786
2021-01-21 10:58:39 +00:00
Neale Ranns
45d6d83761 ipsec: Tunnelled packets are locally generated
Type: fix

this means we 1) don't decrement TTL and (for v6) can fragment.

Signed-off-by: Neale Ranns <neale@graphiant.com>
Change-Id: I0f718da7dcaba834ad495ae9242a9a58c9e7c184
2021-01-21 10:58:22 +00:00
Benoît Ganne
c15539af6f ip: set correct error in ip6-local
Type: fix

Change-Id: Ib23f823e46494f80d9d857ddde88f4939bf2b3d1
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-01-21 09:01:28 +00:00
Matthew Smith
f613a44020 vppinfra: add bihash with 32 byte key
Type: feature

Add header to define bihash_32_8.

Change-Id: Ia8a21a1e76cf0c05b8f8a2d1f5dbc0dc586d7801
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2021-01-21 08:43:18 +00:00
Nathan Moos
1550907d0a fib: fix includes for musl
Type: fix

When building with musl, the type `uint` is not available unless you
include <sys/types.h>.

Signed-off-by: Nathan Moos <nmoos@cisco.com>
Change-Id: I0003b0c373d9fd532b4135c43d78f36d6cd7afa4
2021-01-21 01:36:30 +00:00
Andrew Yourtchenko
4d084079cd tests: do not skip solo-run tests if running within a single job and all remaining tests are solo-run
There was a logic error, which results in not running solo tests
if TEST_JOBS=1, and we have finished running the regular test
and the remaining tests are all solo-run. They all get put into
that pile, but the new runners never start.

Solution: check the pile of solo-run jobs unconditionally.

Thanks to Klement Sekera for spotting the issue.

Type: fix
Change-Id: Iaecacbe4de44050cd8d0ff2d524559df99f2bae4
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2021-01-20 20:28:48 +00:00
Jerome Tollet
4f411d1191 build: add python files to ctags
Type: improvement

Signed-off-by: Jerome Tollet <jtollet@cisco.com>
Change-Id: Ifb97b3a52d8bf4ecc09dc1e8ff94992fef309a65
2021-01-20 18:38:56 +00:00
Nathan Moos
fce561226f acl: replace glibc internal __bswap_64 with clib
Type: fix

In order to build VPP as a package for an embedded Yocto-based
distribution, this patch replaces the use of the glibc internal
__bswap_64 function with the VPP function clib_net_to_host_u64, which is
provided by vppinfra.

Change-Id: I3ecc8525861dc3441bce2b51aa4c80f9a62d3051
Signed-off-by: Nathan Moos <nmoos@cisco.com>
2021-01-20 18:11:39 +00:00
Ed Warnicke
acaee3d36e memif: fix vpp to go link up immediately on admin up
Type: improvement

Previously, memif would check every 3 seconds to see if an interface
had gone admin up.  Now it does as soon as admin up occurs.

Signed-off-by: Ed Warnicke <hagbard@gmail.com>
Change-Id: I808699cd5980fa162c34ac977f43d00ed6b67115
Signed-off-by: Ed Warnicke <hagbard@gmail.com>
2021-01-20 17:59:11 +00:00
Ed Warnicke
a4b0541f64 vxlan: fix SEGV reported in VPP-1962
Type: fix

Replace vnet_register_interface with ethernet_register_interface

Fixes https://jira.fd.io/browse/VPP-1962

Signed-off-by: Ed Warnicke <hagbard@gmail.com>
Change-Id: I5f578fc416605429fe1e2b510ad49eb754451d40
Signed-off-by: Ed Warnicke <hagbard@gmail.com>
2021-01-20 17:53:01 +00:00
Nathan Moos
67d7acd059 vppinfra: add option to use libexecinfo
Type: feature

The musl libc does not provide <execinfo.h> or an implementation of the
functions provided. This patch enables the use of libexecinfo as an
alternative, which can be used on systems with musl.

Change-Id: I76b5744ddf731b66e16144025a6fdedf72925260
Signed-off-by: Nathan Moos <nmoos@cisco.com>
2021-01-20 15:23:06 +00:00
Nathan Moos
cf5ba26700 svm: add standard include for __WORDSIZE
Type: fix

In glibc, the __WORDSIZE macro is defined in a header included
indirectly from svm_common.h. In musl, the __WORDSIZE macro is not
indirectly included, so this patch directly includes <sys/user.h> to
ensure the __WORDSIZE macro is available.

Change-Id: If1b1fc97161b7a0b2e82351d4776c81c36a323cb
Signed-off-by: Nathan Moos <nmoos@cisco.com>
2021-01-20 15:21:55 +00:00
Nathan Moos
bfa0398f7a vlib: fix build with musl
Type: fix

When building with musl, some transitive includes from glibc are not
present. This patch adds direct includes for the necessary types, and it
also defines _GNU_SOURCE to ensure that the socket types are complete.

Change-Id: Ic69c307b9515fec764c32906b5bc7f1fb34f2525
Signed-off-by: Nathan Moos <nmoos@cisco.com>
2021-01-20 15:19:36 +00:00