8208 Commits

Author SHA1 Message Date
Mohsin Kazmi
9bf616ca89 tap: fix the numa/queue for buffers
Type: fix

Change-Id: Ib320171708bebde6d1dae0b2c665f9bcfc9102db
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
(cherry picked from commit 547a61654629370211468679b263c49571ecb1f9)
2020-03-27 14:28:48 +00:00
Mohsin Kazmi
d6420459c7 virtio: fix link up/down flag
Type: fix

"set int state <interface> down" puts the virtio device link
down. It will not put the link in "UP" state, when
"set int state <interface up>" will be used again to change
the interface admin up. This patch fixes it.

To test:
create tap
set int state tap0 up
set int state tap0 down
sh hardware
sh int
set int state tap0 up
sh int
sh hardware

Change-Id: I3c0e31539f8a2a1e40220e7fb57eedecf408f067
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
(cherry picked from commit 529f0e97b6064039c500adce0d54b738954b2ffa)
2020-03-27 14:28:37 +00:00
Mohsin Kazmi
4f81e6ffe1 virtio: fix the out of order descriptors in tx
Type: fix

Some vhost-backends give used descriptors back in
out-of-order. This patch fixes the native virtio to
handle out-of-order descriptors.

Change-Id: I57323303349f6a385e412ee22772ab979ae8edbf
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
(cherry picked from commit 7f6d145accc6e63b150ab4efc282f19cbe996b57)
2020-03-27 09:39:58 +00:00
Florin Coras
0dfc3af13b classify: fix pcap filter set init
Type: fix

Change-Id: I6a48a6c14bfb84b3460e8211021bc9df6e915dba
Signed-off-by: Florin Coras <fcoras@cisco.com>
(cherry picked from commit cd681adab40f49d1305144b6bbbd5118e63a2805)
2020-03-25 13:52:12 +00:00
Neale Ranns
f2e2dd340a ip: Adding IP tables is no MP safe
Type: fix

it was marked MP safe in the CLI (which it shouldn't be) but
it it not marked MP safe on the API.

Change-Id: I4bdea498a510a8b406d13d62a899b6d03656f7e8
Signed-off-by: Neale Ranns <nranns@cisco.com>
2020-03-25 08:11:46 +00:00
Elias Rudberg
042e8b0d3d nat: in2out/out2in handoff node index bugfix
This fixes a bug in the initialization of handoff_out2in_index and
handoff_in2out_index where the node index for out2in was set to the
in2out node, and vice versa.

Type: fix

Signed-off-by: Elias Rudberg <elias.rudberg@bahnhof.net>
Change-Id: I983ddd3b3cec06f4cb3fb95b2a9cda4ab6d1270f
(cherry picked from commit dd9aedaf377f4af8620408843bd3e4610d3df5f9)
2020-03-17 10:03:46 +00:00
Ole Troan
ef678a4bd1 vppapigen: fix options representation
Type: fix
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: Ief77110160120ea0e1291cc79949a73404cdbfda
(cherry picked from commit 59b6c0c86d0c3310b8d87b9f2600b6fc7682b549)
2020-03-16 09:10:27 +00:00
Elias Rudberg
8e50e48f4d rdma: fix bug related to ring buffer
Fix a bug that caused some input packets to be dropped due to errors of
the type 'ip4 length > l2 length'. The change is related to the second
call to the rdma_device_input_bufs() function that happens when the end
of the ring buffer is reached.

Type: fix
Change-Id: I332d69ab22242b3443a0baca6e5dd86349a54765
Signed-off-by: Elias Rudberg <elias.rudberg@bahnhof.net>
(cherry picked from commit e5ecf3ea4b456afb710f4ed903cd7e4c1ae87859)
2020-03-11 20:03:18 +00:00
Steven Luong
6f171a7756 dpdk: TSO does not work for Cisco VIC
While TSO is supported for Intel NIC, Cisco VIC does not work.
The problem is due to txmode offloads is not properly set for
the Cisco VIC when enable-tcp-udp-checksum is configured.

Type: fix
Ticket: VPP-1838

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I72c41db9b327ed8d08ef70d74e8cc6206d4a102f
(cherry picked from commit ac8bb9263438221cc93db62257ffd8db711530e2)
2020-03-10 14:23:08 +00:00
Steven Luong
4056ed59a0 avf: Handle chain buffer in TX properly
For chain buffer, need to traverse b->next_buffer to transmit all buffers
in the chain. Only set EOP at the last descriptor in the chain to signal
this is a chain descriptor.

Introduce slow path to handle ring wrap. This is needed because chain
buffer may consist of multiple pieces and it may span from near the end of
the ring to the beginning of the ring.

Type: fix

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: Id7c872f3e39e09f3566aa63f3cdba8f40736d508
(cherry picked from commit f7ab7b2d9bc0f42c1e766d22d49dd0dc4f28abb6)
2020-03-10 14:22:23 +00:00
Matthew Smith
cd88ca366c ip6: fix l4 checksum with hop-by-hop header
L4 checksums for IPv6 should be calculated using a pseudo header that
includes the source/destination addresses, payload length, and payload
protocol.

ip6_tcp_udp_icmp_compute_checksum() was using the payload length and
protocol from the IPv6 header. If there is a hop-by-hop header (or any
other extension header), the payload length used for the pseudo header
should only include the upper layer header and payload and not the
extension header bytes. Same deal with the protocol, the upper layer
next header value should be used instead of the extension header.

Type: fix
Fixes: cb9cadad57

Change-Id: Ifa2c9ad41c0fc4eea674f0671255b637c8e01f71
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
(cherry picked from commit 97677a26f7c857e7ee0acbdb2c13eef214aa70a8)
2020-03-10 14:21:06 +00:00
Neale Ranns
24064d02aa fib: adjacency midchain teardown (VPP-1841)
Type: fix

Change-Id: I57f8bfbce4feed9d2775875cb8b1b729a47900a4
Signed-off-by: Neale Ranns <nranns@cisco.com>
2020-02-19 18:42:44 +00:00
Neale Ranns
02d5a67d39 fib: fib path realloc during midchain stack
Type: fix

Change-Id: I0677f46dfa22c8abab7f311230a09ef1cd8ac335
Signed-off-by: Neale Ranns <nranns@cisco.com>
2020-02-18 15:23:29 +00:00
Neale Ranns
61b96ce607 fib: Fix some more realloc errors
Type: fix

Change-Id: I6011f5d6eae79019d3c16a260a9bedf0a76d2151
Signed-off-by: Neale Ranns <nranns@cisco.com>
(cherry picked from commit 6ede570259a91cd0c34b9faf9fec7e4ec8275200)
2020-02-14 16:50:44 +00:00
Dave Barach
af9c2a3435 classify: fix "show classify filter" debug CLI
Null pointer bug, memory leak. D'oh!

Type: fix

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: Ic2865757ed9cbb7f48d23c7c30b64299eb5f6674
(cherry picked from commit 104112f2d412a4576b5e0d3bbb20665d2b5bd615)
2020-02-13 13:35:37 +00:00
Dave Barach
b01058ce2c classify: pcap / packet trace debug CLI bugs
"classify filter trace ... " and "classify filter pcap ..." are
mutually exclusive.

vnet_pcap_dispatch_trace_configure needs to check for
set->table_indices == NULL.

Type: fix
Ticket: VPP-1827

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: I43733364087ffb0a43de92e450955033431d559d
(cherry picked from commit 196fce2b62c0d215722dd233aa8bf70a43aa0a66)
2020-02-12 13:45:47 +00:00
John Lo
1d609270b6 ipsec: set l2_len for GRE-TEB tunnel decap
Type: fix
Ticket: VPP-1831

Signed-off-by: John Lo <loj@cisco.com>
Change-Id: I655964b22021ac38cbced577091a1156286d4fd6
2020-02-05 14:29:59 +00:00
Dave Barach
a4eac3fb0a vppinfra: fix typo in tw_timer_template.c
Fix minor memory leak

Type: fix
Ticket: VPP-1833
Fixes: 4af9ba1dab

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: Id10fba70471ca78f73f14146054f6b12c5d4431f
2020-02-05 08:34:18 +00:00
Steven Luong
7611d5d9e7 virtio: vhost gso is broken in some topology
Recent modification added a call to vnet_gso_header_offset_parser in the
beginning of vhost_user_handle_tx_offload. The former routine may set tcp or
udp->checksum to 0. While it is appropriate to set it to 0 for the GSO packet,
it is broken and causes checksum error if the aformentiooned routine is called
by a non-GSO packet. The fix is to not call vhost_user_handle_tx_offload
if the buffer does not indicate checksum offload is needed.

Type: fix

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I6e699d7a40b7887ff149cd8f77e8f0fa9374ef19
(cherry picked from commit 564e1672917e205d7ae79525bb937df18f8d764b)
2020-02-05 08:33:38 +00:00
Steven Luong
1934b13d36 fib: refresh adj pointer after fib_walk_sync due to possible realloc
fib_walk_sync may call adj_alloc which may cause adj_pool to expand. When
that happens, any previous frame which still use the old adj pointer needs to
refresh. Failure to do so may access or update to the old adj memory
unintentionally and crash mysteriously.

Type: fix
Ticket: VPPSUPP-54

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I173dec4c5ce81c6e26c4fe011b894a7345901b24
(cherry picked from commit 3d5f6229bccf77fcf7e0e17ab4f1b361fedd1b2b)
2020-02-03 15:06:38 +00:00
Andrew Yourtchenko
fce396738f misc: VPP 20.01 Release Notes
Type: docs
Change-Id: Iee518fbb9c72716cc90a3ea8efbf3ecbaa969a84
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
v20.01
2020-01-29 20:33:31 +00:00
Andrew Yourtchenko
fc98203b5d misc: Markdown cleanups for the 20.01 release
Type: docs
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Change-Id: I821197364a2fee9b52b1f014288b1f5e9e3c494c
2020-01-29 19:32:53 +00:00
Benoît Ganne
a2c1951e56 devices: vhost: fix data offset on input
Regardless of whether the virtio_net_hdr is sent as a separate
descriptors or in the same descriptor as the data, we always want to
skip the header length - maybe moving to the next descriptor along the
way.

Type: fix

Change-Id: Iaa70aeb310e589639b20f8c7029aaa8d3ce5d307
Signed-off-by: Benoît Ganne <bganne@cisco.com>
(cherry picked from commit 5ecc1e4d433a34845c7bfd761dc990413e6c321b)
2020-01-29 18:35:11 +00:00
Florin Coras
fb15c0c0cf session tcp: fix packet tracing
Type: fix
Ticket: VPP-1830

Change-Id: Ib823d016c64998779fb1d00b8aad3acb5e8340be
Signed-off-by: Florin Coras <fcoras@cisco.com>
(cherry picked from commit 30928f87a3c9d98e288d1364d50c032e052e69ab)
2020-01-28 16:28:32 +00:00
Neale Ranns
7d3c2b738e fib: Reload the adj after possible realloc (VPP-1822)
Type: fix
Fixes: 418b225931634f6d113d2971cb9550837d69929d

Change-Id: Ia5f4ea24188c4f3de87e06a7fd07b40bcb47cfc1
Signed-off-by: Neale Ranns <nranns@cisco.com>
2020-01-27 20:55:34 +00:00
Dave Wallace
664c9613ac nsim: enable output scheduling on main thread
Type: fix
Ticket: VPP-1813

Change-Id: I5d47cb9bc7eb7f3c8485e3b42f0701e81d87ba2a
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
(cherry picked from commit c0c4eec3bc309bcc656eade82f17754875f9ed7c)
2020-01-27 20:55:12 +00:00
Satoru Matsushima
0c514f0d76 srv6-mobile: Update the document
Updating the document of srv6-mobile plugin code integrated into stable/2001. The reason of this patch just only for the document is that the latest commit to master was reverted by the release master for some reason. The commit included not only the code for new feature, but also the updated document for the already merged code into stable/2001. The previous doc is work-in-progress status in terms of its CLI and features. It seems there is some confusion on this patch is trying to update the document of outside feature of stable/2001 which is not true. This patch exactly reflects the correct information of srv6-mobile plugin within the extent of stable/2001.


Type: docs



Signed-off-by: Satoru Matsushima <satoru.matsushima@gmail.com>
Change-Id: I376386ef6fc9584ab945db7358e3c4a698471e9b
Signed-off-by: Satoru Matsushima <satoru.matsushima@gmail.com>
2020-01-27 16:20:25 +00:00
Florin Coras
abd9312516 session: fix node runtime in pre-input queue handler
Call session queue node with the right node runtime instead of the
pre-input node runtime.

Type: fix
Ticket: VPP-1826

Change-Id: I43d20bed4930fc877b187ce7ecdce62034b393c5
Signed-off-by: Florin Coras <fcoras@cisco.com>
(cherry picked from commit 2d8829cbb5f3d214fbc09bf4258573659e0c5e60)
2020-01-25 19:31:43 +00:00
Dave Barach
9af7a98cf8 api: mark api_trace_command_fn thread-safe
Binary API trace replay with multiple worker threads depends in many
cases on worker thread graph replica maintenance. If we (implicitly)
assert a worker thread barrier at the debug CLI level, all graph
replica changes are deferred until the replay operation completes. If
an interface is deleted, the wheels may fall off.

Type: fix
Ticket: VPP-1824

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: I9b07d43f8501caa5519e5ff9ae4c19dc2661cc84
2020-01-24 00:21:06 +00:00
Florin Coras
864af09508 hsa: proxy app fixes
Type: fix
Ticket: VPP-1825

Change-Id: Icb4b331c9346d3781f4ddd6f62891c78d4059c1f
Signed-off-by: Florin Coras <fcoras@cisco.com>
(cherry picked from commit f5c7305c4ab21fe1c3eeeee1484449586464813a)
2020-01-23 19:00:29 +00:00
Neale Ranns
20398a368c fib: FIB crash removing labelled route (VPP-1818)
Type: fix

The crash occured trying to retreive a NULL path list to walk the path
extensions. A walk shoul not be required, because there should be no
extensins, since all paths are removed. The problem is that when the
paths were added, they were not sorted, hence neither were the
extensions and when they were updated, duplicate extensions were added,
and hence a path removal did not remove them all.
Fix is to make sure paths are sorted.

Change-Id: I069d937de8e7bc8aae3d92f588db4daff727d863
Signed-off-by: Neale Ranns <nranns@cisco.com>
(cherry picked from commit 257749c40946a9269140d322e374d74c3b6eefb8)
2020-01-22 22:34:43 +00:00
Neale Ranns
29acfa2ad5 ipsec: re-enable DPDK IPSec for tunnel decap/encap (VPP-1823)
Type: fix

Change-Id: Iff9b1960b122f7d326efc37770b4ae3e81eb3122
Signed-off-by: Neale Ranns <nranns@cisco.com>
v20.01-rc2
2020-01-22 19:23:38 +00:00
Neale Ranns
e3cabba9b8 fib: Adjacency realloc during rewrite update walk (VPP-1822)
Type: fix

Change-Id: I0e826284c50713d322ee7943d87fd3363cfbdfbc
Signed-off-by: Neale Ranns <nranns@cisco.com>
2020-01-21 20:26:43 +00:00
Andrew Yourtchenko
c7fe31cfff misc: Initial changes for stable/2001 branch
Type: docs
Change-Id: I0a8a43bd5436b5d3cdd9b8937cd0b2366e523f91
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
v20.01-rc1
2020-01-15 22:09:55 +00:00
Dave Wallace
e5060b33bd build: install vpp_echo for CSIT QUIC perf tests
Type: make

Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Change-Id: Iddfcce1f662efe63c5a6788a0a604917b1c9d81e
2020-01-15 18:16:31 +00:00
Simon Zhang
79bfb9e09c tcp: fix tcp check tx offload issue
Type: fix

Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com>
Change-Id: I3b8755831d762abf51e1cbe1b57024f9297de9a4
Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com>
2020-01-15 15:59:19 +00:00
Yu Ping
d63b356bdf tls: enable async node on demand
Type: fix

Change-Id: Iab7c65614c94497e8ec5a96624be72c1a139e486
Signed-off-by: Yu Ping <ping.yu@intel.com>
2020-01-15 15:55:34 +00:00
Alexander Chernavin
180210f99b ip6: during icmp to icmp6 translation truncate error messages
All translated ICMPv6 packets that exceed the minimal IPv6 MTU get
truncated but according to RFC 4443 2.4 only ICMPv6 error messages
(type < 128) need to be truncated.

With this commit, truncate only ICMPv6 error messages.

Type: fix

Change-Id: Ic455352de2ff4ff6aa3421b46a2a54923f2d3f80
Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
2020-01-15 15:11:27 +00:00
Aloys Augustin
fc0992cb8d quic: add FEATURE.yaml
Type: docs
Change-Id: Ica60b42e64703879c5c229209e4a4fac278bda31
Signed-off-by: Aloys Augustin <aloaugus@cisco.com>
2020-01-15 14:06:23 +00:00
Andrew Yourtchenko
61f7bfb6de srv6-mobile: Revert "srv6-mobile:"
This reverts commit 57584d99dd8a8524db90c67c88525d58879d9b8e.

The reasons for reverting:

- the documentation seems "work in progress". Also, 500K of pngs
  should probably go on wiki, rather than in the repo. Please
  make sure that newly added documentation renders correctly
  and sensibly as part of the review/commit process.

- runner.py seems to contain unit tests, so it should
  be rewritten in a manner that allows the testing from within
  CI (including an unprivileged docker container)

- the above items, especially the testing one, warrant more
  work, and at a RC1 milestone time it is probably not
  a good idea to include a significant patch without
  proper care. I suggest to prepare it so it is ready
  for the next release, or cherrypick it for a
  20.01.1 release, if having it in stable/2001 is absolute necessity.

- when submitting it, ensure that the commit message
  makes sense, especially having "srv6-mobile:" with no further
  text should be absolutely avoided.

Change-Id: If81441f7ebf11a6ad5638b1327faf18e8ebe6a35
Type: fix
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2020-01-15 11:06:59 +00:00
Simon Zhang
989c3c8fbd tls: add picotls session close process
Type: fix

Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com>
Change-Id: If0a1691c1435f2826c8c83f8bc52e4cd3ecc6256
2020-01-15 06:15:32 +00:00
Florin Coras
c95eefb393 tcp: handle ack advancement with no holes and reneging
Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I9afba8dc9e087b8c436fe568531c02614a577a7c
2020-01-14 23:38:05 +00:00
Paul Vinciguerra
48bdbcd8f9 tests: fix worker thread initialization
from threading.thread __init__:

    This constructor should always be called with keyword arguments.

    If a subclass overrides the constructor, it must make sure to invoke
    the base class constructor (Thread.__init__()) before doing anything
    else to the thread.

Type: test
Change-Id: Ifa89202e97053a4baf19e9a0ca0913430d5087a3
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2020-01-14 19:33:23 +00:00
Tetsuya Murakami
57584d99dd srv6-mobile:
Type: feature

Add new functions in SRv6 Mobile Plug-in

GTP4.DT and GTP6.DT

Signed-off-by: Tetsuya Murakami <tetsuya.mrk@gmail.com>
Change-Id: I573a0c27bd463dd56a4d11b940941b8a8c826e08
Signed-off-by: Tetsuya Murakami <tetsuya.mrk@gmail.com>
2020-01-14 18:16:21 +00:00
Neale Ranns
ba4a5bf884 classify: Reduce the include dependencies on vnet_classify.h
Type: refactor

currently vnet_classify.h is included in ip.h where it's not required.

Change-Id: Id55682637601655aa2edda681536a979c8e323bd
Signed-off-by: Neale Ranns <nranns@cisco.com>
2020-01-14 16:18:52 +00:00
Benoît Ganne
207a163309 dpdk: enforce max tx retries
n_retry was never decremented and so never enforced.

Type: fix

Change-Id: I71d60a72c156286f7e5b82b1c77a723361317c69
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2020-01-14 15:49:10 +00:00
Neale Ranns
fec52edb3c acl: Remove unsued type
Type: style

and add some indent offs.

Change-Id: I31cf3ab9ff9b64d2cd1f2034dcedd4a9c453efb4
Signed-off-by: Neale Ranns <nranns@cisco.com>
2020-01-13 17:13:54 +00:00
Neale Ranns
629e268aa1 ct6: dst,src copy typo
Type: fix

Signed-off-by: Neale Ranns <nranns@cisco.com>
Change-Id: I266fa5dc637383fd8dac6592c9c266a1b70a73e9
2020-01-13 16:56:54 +00:00
Ole Troan
b3745c431e misc: feature file for unsupported feature l2tp
Type: docs
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: I11db583650bc051f88f38358b877410f355b110f
Signed-off-by: Ole Troan <ot@cisco.com>
2020-01-13 16:52:25 +00:00
Andrew Yourtchenko
f63bf6a7d7 tests: disable the tap test for the time being
TAP tests require root access, which breaks
the testing in unprivileged scenario.
Disable the test until we find consensus on how
to deal with it.

Type: test
Change-Id: I66ee2b130723233682d858cad0b6e424ab0b2383
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2020-01-13 14:55:07 +00:00