9402 Commits

Author SHA1 Message Date
Dave Barach
d135487aff vppinfra: elog multi-track g2 test pattern
Type: test

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: Ia4504629cb5e87067a337d16f43e044399b87cac
2020-08-26 21:57:09 +00:00
Damjan Marion
3373a55f91 dpdk: bump to DPDK 20.08
Type: improvement

Change-Id: Id864c80ac0c9e6f3514a99e516fed82a998effff
Signed-off-by: Damjan Marion <damarion@cisco.com>
2020-08-26 11:42:33 +00:00
hanlin
f8e1363c4f vcl: fix duplicated key of session_index_to_vlsh_table in multiple
threads vcl workers scenario

Type: fix

In multiple threads vcl workers scenario, multiple vcl workes can create
sessions with same index. Because only one vls worker created, key of
session_index_to_vlsh_table is duplicated.

Signed-off-by: hanlin <hanlin_wang@163.com>
Change-Id: I7e1f5bc471adc5378194452aef85e611f5d0df1d
2020-08-26 01:04:50 +00:00
Benoît Ganne
cd631b5ba0 rdma: bump rdma-core version to v31.0
Type: improvement

Change-Id: If02deabea1fe47bbe82c53182e24a97cff68f8ec
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2020-08-25 20:34:51 +00:00
Florin Coras
a5ea8211b1 vcl: cleanup non-blocking connect
Make sure session is in non-closed state after non-blocking connect to
ensure cleanup is performed, if needed.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ic1533b9864828f875c840dfdfeed08bf32d10651
2020-08-25 13:39:29 +00:00
Chenmin Sun
d0236f725d flow: add vnet/flow formal API
This patch adds the API for vnet/flow infra.
Currently this API supports the below flow types:
    VNET_FLOW_TYPE_IP4_N_TUPLE
    VNET_FLOW_TYPE_IP6_N_TUPLE
    VNET_FLOW_TYPE_IP4_N_TUPLE_TAGGED
    VNET_FLOW_TYPE_IP6_N_TUPLE_TAGGED
    VNET_FLOW_TYPE_IP4_L2TPV3OIP
    VNET_FLOW_TYPE_IP4_IPSEC_ESP
    VNET_FLOW_TYPE_IP4_IPSEC_AH
    VNET_FLOW_TYPE_IP4_GTPU

All the above flows are tested with Intel E810/X710 NIC

Type: feature

Signed-off-by: Chenmin Sun <chenmin.sun@intel.com>
Change-Id: Icb8ae20cab9bdad6b120dddc3bd4fb1d85634f3f
2020-08-25 12:13:43 +00:00
Matthew Smith
4fa3aad33f ip-neighbor: skip probe for disabled interfaces
Type: fix

In ip6_neighbor_probe(), if the interface is not enabled for ip6,
return NULL and skip trying to build a packet.

If the interface is not enabled, its mcast adjacency will be set to
~0 and a seg fault will ensue.

Change-Id: I825c9f40a0d5b2a77f788ac8dbd618138706383d
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2020-08-25 07:45:40 +00:00
Ole Troan
bad679291a api: register endian handlers for reply messages
Endian handlers was not registered for reply messages.
Causing endian-neutral handlers to crash.

Type: fix
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: Id14173300ee1ab2601e92d58c70d2fa260814b69
2020-08-25 07:35:49 +00:00
Steven Luong
3f54d96dac bonding: enhance binary api handling
- check input sw_if_index to make sure it is sane. Coverity actually
complains about it.
- return rv. Some of the APIs handlers were not passing back the rv.

Type: improvement

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I8378ea948af561ba2bd9b02fb10bf4f9df2a2cd2
2020-08-24 10:44:31 +00:00
Steven Luong
067ef751d3 vmxnet3: enhance debug CLI error handling
- Display the interface name upon successfully creating the interface.
- Don't go silent when error occurs. Be explicit about it.

Type: improvement

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: Ie4fdaf323f8b3833ad4a7af3872290141204aba8
2020-08-24 10:43:52 +00:00
jiangxiaoming
34a72c61ea hsa: set connected mode for udp server
Type: fix

Signed-off-by: jiangxiaoming <jiangxiaoming@outlook.com>
Change-Id: I32a28a944fcee11657c4dd0ba34ad6d73de89263
2020-08-22 11:29:54 +00:00
Dave Barach
b08fe6617b vppinfra: add format_one_elog_event
To avoid ridiculous pointer gymnastics in golang

Type: improvement

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: Ic5a641c18281970e2b9bc3013a54cfc3ae92e372
2020-08-21 14:21:55 +00:00
Nathan Skrzypczak
9ff0cd7171 vppapigen: Fix missing api dir
Type: fix

pci_types.api lives in vlib/pci which wasn't included
in the generate_json.py script

Change-Id: I15649786282584b7aefb9ace83c5154eb697b50b
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2020-08-21 11:16:54 +02:00
Florin Coras
cc4d6d022f tcp: track reorder with sacks
Type: feature

Change-Id: I041bff2e8d589c171661de286fa1503531dff891
Signed-off-by: Florin Coras <fcoras@cisco.com>
2020-08-20 16:58:33 +00:00
Mohsin Kazmi
ad1e455f4d tap: fix flags in custom-dump
Type: fix

Change-Id: I4cd0b1855eab05344897686dc17b7df44de6c786
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2020-08-20 16:26:29 +02:00
Mohsin Kazmi
379aac395a virtio: add modern device support
Type: feature

Change-Id: I205f7c146a213d603d9d1e46fcf5195a876608dc
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2020-08-20 14:12:40 +00:00
Milan Lenco
7885c740ae ipsec: fix esp padding
Type: fix

Signed-off-by: Milan Lenco <milan.lenco@pantheon.tech>
Change-Id: Ic8db52b41d7e5af3425099f008984e50afb3da74
2020-08-20 14:00:40 +02:00
Mohsin Kazmi
a0a68339b7 virtio: refactor pci device code
Type: refactor

Change-Id: I7342178f9ab9adb99b91a4f984bc22bef2ce8021
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2020-08-20 09:33:23 +00:00
Elias Rudberg
224735bf09 ip: vnet_ip_mroute_cmd payload_proto fix
Make sure payload_proto variable is set properly in vnet_ip_mroute_cmd()
function. This avoids using an uninitialized payload_proto value which
could lead to assertion failure when using e.g. the ip mroute add
command.

Type: fix

Signed-off-by: Elias Rudberg <elias.rudberg@bahnhof.net>
Change-Id: I8b1d1df02e80150836b7b0448814d8f99747eeed
2020-08-20 08:56:37 +00:00
Filip Varga
9f57c72e27 nat: fixed cli nat summary and nat limit
Type: fix

Change-Id: I78017b02015116f93b579c7381119f618351c98d
Signed-off-by: Filip Varga <fivarga@cisco.com>
2020-08-20 07:17:49 +00:00
Florin Coras
dd7d24bdfb session: ct init error handling
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ie70348406a2bfc156302687d2f5f98bc1a50c88f
2020-08-19 16:27:47 +00:00
Dave Barach
e09ae01f67 vppinfra: minor tweaks for cgo interoperation
'type' is a keyword in golang, so s/type/event_type/ in elog.h and
elsewhere.

Add vec_len_not_inline(...), elog_write_file_not_inline(...) and
elog_read_file_not_inline(...) since the inline forms aren't usable.

More such tweaks may follow.

Type: improvement
Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: I9a80a6afa635f5cdedee554ee9abe400fafc1cb6
2020-08-19 07:04:36 -04:00
Filip Varga
5c1cba5401 nat: session cli command fix
Type: fix

Change-Id: I57ae649d1b26d5bea2df89c209f257372e565b49
Signed-off-by: Filip Varga <fivarga@cisco.com>
2020-08-19 08:01:31 +00:00
Florin Coras
587ea45ad8 api: retry sending fd on EAGAIN
Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I04117636ad95b706e3dd9331f00bd80e57d26d7f
2020-08-18 14:34:01 +00:00
Andrew Yourtchenko
1060332e62 build: add explicit commit to rc1, rc2 builds, and add ".0" to post-non-dot-release per-patch builds
This addresses problem with incorrect sorting of artifacts in the per-patch packagecloud repositories
for throttle branches, by slightly changing the version string for the non-released (per-build) artifacts:

1) the rc1 and rc2 artifacts now will have the count of
   commits since tag (0) and the explicit commit hash

2) the builds after version XX.YY but before XX.YY.1
are named as if the version was "XX.YY.0"

Type: fix
Change-Id: Ib69a59ee98aa296c5cb24b183bba807b6cb3c05c
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2020-08-18 10:40:15 +00:00
Nathan Skrzypczak
42b29ba3d4 vppinfra: fix RC in bihash instantiation
There can be a race condition in the case
a thread tries to do a bihash_search while
another instantiates the bihash.

Type: fix

Change-Id: Ic61b590763beb409e112957c43a5a66cd10afb28
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2020-08-17 16:33:50 +02:00
Klement Sekera
ec9bf61fcb nat: det: replace speculative buffer enqueue model
Replace speculative buffer enqueue coding model with
vlib_get_buffers(...)/vlib_buffer_enqueue_to_next(...).

Type: improvement
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: Ib5a32d60592fb17ed0ba1ac074047e39780f74be
2020-08-17 10:36:16 +00:00
Vratko Polak
9a412bcec4 stats: Move misplaced comment block
Type: fix
Fixes: fdc678081ca5f0971b8bcbf312c1e83017365c33

Change-Id: I64d15b050cfd3d88923bf996cb68b13504dbf6af
Signed-off-by: Vratko Polak <vrpolak@cisco.com>
2020-08-17 10:35:48 +00:00
Ole Troan
f92bfb1bde vppapigen: generate define for module_semver
Generate a semver define for API modules in the VPP side C generator.

E.g in map.api_types.h
\#define VL_API_MAP_API_VERSION_MAJOR 4
\#define VL_API_MAP_API_VERSION_MINOR 2
\#define VL_API_MAP_API_VERSION_PATCH 1

Type: improvement
Change-Id: I2ab86154e85e26fb075c4e91a01ff3692640654b
Signed-off-by: Ole Troan <ot@cisco.com>
2020-08-17 10:33:32 +00:00
Mohsin Kazmi
9e2a78564f tap: add gro support
Type: feature

Change-Id: I5868dd267aa26aa97aec5fd70e70c5956ac52277
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2020-08-17 08:46:53 +00:00
Filip Varga
00dd39044e nat: sessions get expired when fib table removed
fib table removal would leave lingering sessions in vpp
this patch is aimed at solving this issue by grouping
sessions by source and destionation fib. if one of the
fibs gets removed this grouping is tagged as expired
and session won't be passed to non existing fib table

Ticket: VPPSUPP-93
Type: improvement

Change-Id: I45b1205a8b58d91f174e6feb862554ec2f6cffad
Signed-off-by: Filip Varga <fivarga@cisco.com>
2020-08-17 07:53:18 +00:00
Florin Coras
17ec577f7b vcl: rx dequeue notifications with epoll
Add deq request on ct fifo if present and clear event when session is
removed from epoll group.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I8a20342879b3aac2f8fe8171556baaf9c992363b
2020-08-14 20:23:06 +00:00
Florin Coras
c34118b591 vcl: minimize vpp to vcl rx events
Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I2015162bd315927e45b9fe583324b1458fe69d8f
2020-08-14 20:22:47 +00:00
Mohsin Kazmi
f382b06feb gso: packet coalesce library
Type: feature

Change-Id: Ia19d3611e596d9ec47509889b34e8fe793a0ccc3
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2020-08-14 09:38:58 +00:00
Steven Luong
c3ed1c9913 ip: add VNET_IP_TABLE_ADD_DEL_FUNCTION
vrf table may be dynamically added or deleted. When the table is deleted,
clients who use the corresponding vrf table may need a callback to
do the clean up. The mechanism added here is cloned from
VNET_SW_INTERFACE_ADD_DEL_FUNCTION.

Type: improvement

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I08635c715cd7361a6c359b90890dd3545b0da94c
2020-08-14 08:15:31 +00:00
Florin Coras
2f630188b9 vcl: clear ct rx event on right fifo
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I70bab0d86287c108c6dffda5c5b2f29277c15de1
2020-08-13 14:21:43 +00:00
Christian Hopps
047f67eedd docs: correct fib tunnel diagram reference
The included image was pulling in figure 2, change to the correct
figure 11.

Type: docs
Signed-off-by: Christian Hopps <chopps@labn.net>
Change-Id: I3679916364753fc682d1d1713fce952de398e626
2020-08-13 12:29:10 +00:00
Filip Varga
603e754658 nat: move deterministic nat to det44 sub feature
Type: refactor

Change-Id: I0bb203102a0e13dd7448e2125925ab356bbd7937
Signed-off-by: Filip Varga <fivarga@cisco.com>
2020-08-13 10:06:33 +00:00
Klement Sekera
de118da58e nat: remove non-error error counters
Some statistics counters were implemented as error counters. Move them
to stat segment, where they belong.

Type: improvement
Change-Id: I5600bec1b4e0496282297374ec1e79d909cdaf8a
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2020-08-13 08:34:33 +00:00
Andrew Yourtchenko
fbecd936bd acl: use the global heap when allocating the lookup context
The "ACL as a service" lookup infra is shared, so a global heap must
be used.

Type: fix
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Change-Id: I86894254b737392c1968b6a581b5a37590376428
2020-08-13 08:19:17 +00:00
Ole Troan
920acd47bc vppapigen: remove unreachable code
Type: fix
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: Ifd81acaa020f6ebff20ec4eff4370d8a18323860
2020-08-13 07:33:08 +00:00
Ole Troan
7d29e320fb stats: remove offsets on vpp side
Represent pointers directly in shared memory and require clients to adjust for
shared memory segment being mapped at different base address.
Deprecated: stat_segment_pointer() / stat_segment_offset()
Added: stat_segment_adjust()

Bumped the stat segment version to 2.

Type: refactor
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: I33e756187b8903b45dcd353e6c1a101b7a4acb79
2020-08-13 07:28:13 +00:00
Florin Coras
ff40d8f1b2 vcl: mt detection and cleanup
Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I521c110fd4d7445bd585c96d4c768f16a0a7d3b8
2020-08-12 07:52:17 -07:00
hanlin
a3a489691d vcl: support multi-threads with session migration
Currently, mutlti-threads only support one dispatch thread and multiple
worker threads, eventually only dispatch thread is a vcl worker and can
interact with epoll.
This patch will register all threads as vcl worker, and then each
thread can interact with epoll now. Moreover, session migration also
supported, such as socket created in thread A and used (bind, connect
and etc.) in thread B.

Type: feature

Signed-off-by: hanlin <hanlin_wang@163.com>
Change-Id: Iab0b43a33466968c1423d7d20faf1460c8589d91
2020-08-12 01:57:18 +00:00
Florin Coras
40c07ce7a7 vcl: support inter worker rpc
Type: feature

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I664cd14c84fc5cf2ffe61efce99c95219b44fad7
2020-08-11 18:05:06 +00:00
Ole Troan
68ebcd50bf vppapigen: add support for empty options
Type: improvement
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: I59323447bee7bb4f0563251a5df80cbefb9bd89e
Signed-off-by: Ole Troan <ot@cisco.com>
2020-08-11 14:55:41 +00:00
Ole Troan
710fe10462 papi: allow unknown address family
In unions all representations of the union are decoded.
Which means trying to decode something that isn't an address
might have invalid address family types.

Type: fix
Ticket: VPP-1884
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: Id3381ef8cc885952c1eb488ebc70e276eaceb366
2020-08-11 13:51:59 +00:00
Ole Troan
fdc678081c stats: add timeout for in_progress access to stat segment
add new api stat_segment_set_timeout_nsec to limit time waiting for vpp
in_progress state.

Change-Id: Ic78a97bc5013d67d7e4bbcc4a6f0ef918f9f9b33
Type: improvement
Signed-off-by: Ole Troan <ot@cisco.com>
2020-08-11 09:48:13 +02:00
Ole Troan
3c70c05e1f stats: name and error index client memory leak
Type: fix
Change-Id: I6c9999b93d4f4ad4b8540a21e793c9a90e7c8ecf
Signed-off-by: Ole Troan <ot@cisco.com>
2020-08-10 17:29:09 +02:00
Simon Zhang
53ec96777c vcl: fix getting wrong non-blocking flags issue in VPPCOM_ATTR_GET_FLAGS action
Type: fix

Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com>
Change-Id: If4c700b59b8936a43d6a73ed75cc6fdaf6cf141d
2020-08-09 01:37:07 +00:00