4996 Commits

Author SHA1 Message Date
Florin Coras
d6a0d0e206 vcl: fix bidirectional tests (VPP-1455)
- add epoll dequeued events beyond maxevents to unhandled
- filter multiple epoll rx events

Change-Id: I618f5f02b19581473de891b3b59bb6a0faad10b5
Signed-off-by: Florin Coras <fcoras@cisco.com>
(cherry picked from commit aa27eb95b7ee3bb69b62166d5e418e973cbbdcfa)
2018-10-16 10:05:57 +00:00
Steven
347c523c23 vmxnet3: show vmxnet3 with filtering capability [VPP-1452]
show vmxnet3 desc may display 5000 lines of output since it has 5 tables. Each
table may have 1000 entries. It would not be very useful to debug problem.

We need filtering capability for the subject show command. We need to be able
to display the descriptor table per interface, per interface per table, and
per interface per table per slot. The latter is the most useful.

tested the following valid combinations
show vmxnet3
show vmxnet3 desc
show vmxnet3 vmxnet3-0/13/0/0
show vmxnet3 vmxnet3-0/13/0/0 desc
show vmxnet3 vmxnet3-0/13/0/0 rx-comp
show vmxnet3 vmxnet3-0/13/0/0 rx-comp 1
show vmxnet3 vmxnet3-0/13/0/0 tx-comp
show vmxnet3 vmxnet3-0/13/0/0 tx-comp 1
show vmxnet3 vmxnet3-0/13/0/0 rx-desc-0
show vmxnet3 vmxnet3-0/13/0/0 rx-desc-0 1
show vmxnet3 vmxnet3-0/13/0/0 rx-desc-1
show vmxnet3 vmxnet3-0/13/0/0 rx-desc-1 1
show vmxnet3 vmxnet3-0/13/0/0 tx-desc
show vmxnet3 vmxnet3-0/13/0/0 tx-desc 1

negative tests and command is rejected
show vmxnet3 abc
show vmxnet3 desc abc
show vmxnet3 vmxnet3-0/13/0/0 abc
show vmxnet3 vmxnet3-0/13/0/0 desc abc
show vmxnet3 vmxnet3-0/13/0/0 rx-comp abc
show vmxnet3 vmxnet3-0/13/0/0 rx-comp 1 abc

Change-Id: I0ff233413496e58236f8fb4a94e493494c20c5cb
Signed-off-by: Steven <sluong@cisco.com>
2018-10-15 21:56:14 +00:00
Steven
3d29e83112 vmxnet3: vmxnet3_test_plugin.so: undefined symbol: format_vlib_pci_addr [VPP-1456]
When using vpp_api_test, there is an undefined symbol error for
format_vlib_pci_addr when vmxnet3_test_plugin.so is loaded.

The cause is due to vlib not included in vpp_api_test. Remove the reference
for vlib.so in vmxnet3_test.

Change-Id: I37c00dfe2f843d99ad6c4fc7af6ed10bac4c2df8
Signed-off-by: Steven <sluong@cisco.com>
2018-10-15 10:26:41 -07:00
mu.duojiao
051984c6a1 VPP-1448: Fix error when recurse on down the trie.
Change-Id: Idfed8243643780d3f52dfe6e6ec621c440daa6ae
Signed-off-by: mu.duojiao <mu.duojiao@zte.com.cn>
(cherry picked from commit 59a829533c1345945dc1b6decc3afe29494e85cd)
2018-10-15 08:43:25 +00:00
Eyal Bari
6a86ca9627 vxlan:fix ip6 tunnel deletion
Change-Id: I70fb7394f85b26f7e632d74fc31ef83597efdd16
Signed-off-by: Eyal Bari <ebari@cisco.com>
(cherry picked from commit f8d5e214687c17fba000607336295e054672459d)
2018-10-14 23:01:19 +00:00
Florin Coras
795539326b vcl: fix empty epoll returns (VPP-1453)
Change-Id: I0b191ddb749b1aa132c2d33b8359c146b36d27af
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-14 10:49:03 +00:00
Florin Coras
02a60e01a7 session: don't wait indefinitely for apps to consume evts (VPP-1454)
Change-Id: I544b24d2b2c4a09829773cf180d1747f4b087d4c
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-12 17:01:10 -07:00
Neale Ranns
9a5f9c9a43 L2-flood: no clone for 1 replication
Change-Id: If178dd38e7920f35588f5d821ff097168b078026
Signed-off-by: Neale Ranns <nranns@cisco.com>
(cherry picked from commit b9fa29d513bfad0d9f18e8ed8c2da3feaa6d3bf0)
2018-10-12 07:35:46 +00:00
Steven
9864f87b1b vmxnet3: better error handling [VPP-1449]
try harder on output - if there is no descriptor space available, try to free
up some and check again.
make sure we free the buffer if error is encountered on input.

Change-Id: I41a45213e29de71935afe707889e515037cd081f
Signed-off-by: Steven <sluong@cisco.com>
(cherry picked from commit 8b0995366110ff8c97d1d10aaa8291ad465b0b2f)
2018-10-11 19:59:04 -07:00
Eyal Bari
125760947a bfd:fix handling session creation batch
when multiple session creating script is ran (via exec) only the first
one actually starts

Change-Id: I0fc36f65795c8921cf180e0b555c446e5a80be45
Signed-off-by: Eyal Bari <ebari@cisco.com>
(cherry picked from commit 0db9b04cf0f9c892a00988e7a61ae703aa83b721)
2018-10-11 23:38:24 +00:00
Ole Troan
0d222f88ed Stats: Include stat_segment.h in packages.
Change-Id: I976c0aba8397badf64763c4dbddce67009a4fb23
Signed-off-by: Ole Troan <ot@cisco.com>
2018-10-11 23:37:37 +00:00
Neale Ranns
713322bd32 Integer underflow and out-of-bounds read (VPP-1442)
Change-Id: Ife2a83b9d7f733f36e0e786ef79edcd394d7c0f9
Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-10-11 20:51:14 +00:00
Matus Fabian
33f276e0af NAT44: identity NAT fix (VPP-1441)
Change-Id: Ic4affc54d15d08b9b730f6ec6146ee053b28b4b6
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2018-10-11 20:40:02 +00:00
Andrew Yourtchenko
7212e61d92 acl-plugin: reduce the syslog level for debug messages (VPP-1443)
Change-Id: Ie8380cb39424548bf64cb19aee59ec20e29d1e39
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2018-10-11 19:35:26 +00:00
Andrew Yourtchenko
376414f4c3 vnet: complete the fix for l3_hdr_offset calculation for single loop fastpass case (VPP-1444)
20e6d36b has moved the calculation of the l3_hdr_offset into the determine_next_node()
function, with the assumption that the current_data in the buffer is at
the L3 header. This is not the case for the single loop fastpath,
where the vlib_buffer_advance() call is made after the call to
determine_next_node(), as a day1 behavior. As a result - that path
incorrectly sets the l3_hdr_offset.

Solution: move the vlib_buffer_advance() call to before determine_next_node()

Change-Id: Id5eaa084c43fb6564f8239df4a0b3dc0412b15de
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2018-10-11 17:48:27 +00:00
Damjan Marion
5551e41f78 Fix vpp-ext-deps package version in stable branch
Change-Id: Ifb33622b50113501f1d23ab94ba9da708678d6be
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-11 17:13:35 +00:00
Marco Varlese
90395743d3 Update .gitreview for stable 18.10 branch
Change-Id: I9f3d551acad6fd2fdd733f7f49e8c75ef43ceebc
Signed-off-by: Marco Varlese <marco.varlese@suse.com>
v18.10-rc1
2018-10-10 09:38:07 +02:00
Sirshak Das
4f611176e9 vppinfra: Fix extendto_high aarch64 NEON api.
This fixes the l2BD and ip4 test case failures.
Fixes VPP-1432, VPP-1428, VPP-1430

Change-Id: I48b5c961bab60cc3b39fcd6db47e098c81579480
Signed-off-by: Sirshak Das <sirshak.das@arm.com>
v19.01-rc0
2018-10-09 13:08:03 -05:00
Jakub Grajciar
7d476e03aa memif: coverity fix
Change-Id: I2b14e2a035a37b04816aac1e610146be58ad1e92
Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2018-10-09 10:07:41 +02:00
Ole Troan
de728ac3c0 API: Spurious timeouts from timeout thread.
Change-Id: I1be1101ba4d82688a32b5ae2c39ca5d92dc244b7
Signed-off-by: Ole Troan <ot@cisco.com>
2018-10-09 07:23:29 +00:00
Andrew Yourtchenko
20e6d36bca vnet: ethernet-input incorrectly sets l3_hdr_offset in some cases
The issue surfaced when developing the tap GSO code, with
an iteration where output path is reliant on
vnet_buffer (b0)->l3_hdr_offset being set correctly in
the input path, during performance testing.

Adding a workaround in the TX path shows that
the issue surfaces only for relatively few packets
during the test (about 100 out of 600000).

Analysis shows the issue arises if the ethernet-input
is handling two untagged packets with different sw_if_index
values - then the accelerated path punts to slow path,
before the setting of the l2.l2_len values is done,
thus resulting in them being 0, and l3_hdr_offset being
the same as l2_hdr_offset, wreaking havoc on TX path.

The solution is to move the l2_hdr_offset calculation
into a place where it is done for all the packets,
and move the l3_hdr_offset calculation into
the determine_next_node() function - as that function is
also the one setting the special-case l2.l2_len value for
tagged packets and moving the current_data for the L2 case.

Change-Id: If728c7715e011930c1887691188c98055bddde67
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2018-10-09 01:24:43 +00:00
Jakub Grajciar
4a0559a804 memif: socket filename add/del bugfix
Check access rights using effective user/group IDs

Change-Id: I3683258c24bcd7817024bffbd56b54b2f596fdd7
Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
2018-10-08 17:44:58 +00:00
Vijayabhaskar Katamreddy
cef5db0acd Adding Multipath support for exclusive DPO based fib path entries via rpath
Change-Id: I3c84daf046dbad972b36e48fa2548bbe20c7b338
Signed-off-by: Vijayabhaskar Katamreddy <vkatamre@cisco.com>
2018-10-08 14:43:21 +00:00
Hongjun Ni
c210cb50e8 Fix coverity issue for NSH plugin
Change-Id: Ie99ff9aebe3c896e3e104a5a7bebd84f7766e713
Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2018-10-08 13:40:32 +00:00
Ole Troan
3620e61dec Stats: prometheus export coverity errors.
Change-Id: Ibc0a25dcf7d734215e0cffe789b5726f23e1c3d7
Signed-off-by: Ole Troan <ot@cisco.com>
2018-10-08 12:27:24 +00:00
Matus Fabian
e2f4e2f175 NAT44: do not create session record for identity mapping (VPP-1439)
Change-Id: I39a3146a4e4ba8eadf50af7113b9ae6b1c1d688f
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2018-10-08 11:46:23 +00:00
Neale Ranns
2fd4b56aea replicate trace fix
Change-Id: I785ecadbf30812a500629870aa717e64f4cf0cdd
Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-10-08 08:14:57 +00:00
Florin Coras
1502fc303b vcl: cleanup and fixes for vcl test code
- better approximate time when test finishes
- move common vcl and sock test code to vcl_test.h
- overall refactor of variable names

Change-Id: I8e6b43fc017cd05a0ddaa3891767a44fb300c09e
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-07 18:17:04 +00:00
Florin Coras
58c101adf0 vcl: use want_tx_evt for ct sessions
Change-Id: Id46c651c41b1c633326081583ee3383e27ef475d
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-07 12:39:47 +00:00
Steven
318de5de97 bond: active-backup mode is using the wrong load balance algo
active-backup mode is using l2 load balance algo. It should be using
active-backup. Also notice that the output is missing a character.

vpp# create bond mode active-backup
create bond mode active-backup
vpp# sh bond
sh bond
interface name   sw_if_index  mode         load balance  active slaves  slaves
BondEthernet0    6            xor          l34           2              2
BondEthernet1    9            xor          l34           1              1
BondEthernet2    10           active-backu l2            0              0
vpp#

Change-Id: If5ed0cc6c25f6c2ddabec15ff6188b34923d38e3
Signed-off-by: Steven <sluong@cisco.com>
2018-10-06 22:33:41 -07:00
Damjan Marion
b7620fdfd5 vfio: don't display error if no pci devices are assigned to container
Change-Id: I21429ce084cfd39af6a9997b4c1e459f5a6ef672
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-05 18:02:13 +00:00
Damjan Marion
16de39e1a1 bond: tx perf improvement, part trois
Introduce bond_tx_inline which takes lb as a constant for gcc to do the optimization

The number appears a tad better for 256 bytes frame.

with the patch
--------------
Thread 2 vpp_wk_1 (lcore 3)
Time 4.3, average vectors/node 224.00, last 128 main loops 40.00 per node 222.61
  vector rates in 8.4836e6, out 1.6967e7, drop 0.0000e0, punt 0.0000e0
             Name                 State         Calls          Vectors        Suspends         Clocks       Vectors/Call
BondEthernet0-output             active             141054        36109824               0          2.51e1          256.00
BondEthernet0-tx                 active             141054        36109824               0          2.55e1          256.00
TenGigabitEthernet6/0/0-output   active             141054        18055469               0          9.43e0          128.00
TenGigabitEthernet6/0/0-tx       active             141054        18055469               0          6.97e1          128.00
TenGigabitEthernet6/0/1-output   active             141054        18054355               0          9.54e0          127.99
TenGigabitEthernet6/0/1-tx       active             141054        18054355               0          7.05e1          127.99
bond-input                       active             141054        36109824               0          1.76e1          256.00
dpdk-input                       polling             70527        36109824               0          5.03e1          512.00
ethernet-input                   active             141054        36109824               0          6.12e1          256.00
ip4-input                        active             141054        36109824               0          3.26e1          256.00
ip4-lookup                       active             141054        36109824               0          2.94e1          256.00
ip4-rewrite                      active             141054        36109824               0          3.27e1          256.00

without the patch
-----------------
Thread 2 vpp_wk_1 (lcore 3)
Time 4.3, average vectors/node 224.00, last 128 main loops 40.00 per node 222.61
  vector rates in 8.4443e6, out 1.6889e7, drop 0.0000e0, punt 0.0000e0
             Name                 State         Calls          Vectors        Suspends         Clocks       Vectors/Call
BondEthernet0-output             active             142744        36542464               0          2.51e1          256.00
BondEthernet0-tx                 active             142744        36542464               0          2.67e1          256.00
TenGigabitEthernet6/0/0-output   active             142744        18270813               0          9.19e0          127.99
TenGigabitEthernet6/0/0-tx       active             142744        18270813               0          6.98e1          127.99
TenGigabitEthernet6/0/1-output   active             142744        18271651               0          9.43e0          128.00
TenGigabitEthernet6/0/1-tx       active             142744        18271651               0          7.02e1          128.00
bond-input                       active             142744        36542464               0          1.76e1          256.00
dpdk-input                       polling             71372        36542464               0          5.08e1          512.00
ethernet-input                   active             142744        36542464               0          6.15e1          256.00
ip4-input                        active             142744        36542464               0          3.23e1          256.00
ip4-lookup                       active             142744        36542464               0          2.96e1          256.00
ip4-rewrite                      active             142744        36542464               0          3.28e1          256.00

Change-Id: I9fd43eda3c735cbff680ac6d2f01ecdae81f0eda
Signed-off-by: Damjan Marion <damarion@cisco.com>
2018-10-05 10:00:12 -07:00
Neale Ranns
ccc70f6c6e Source VRF Select tests
Change-Id: Id6c16462fccf890eaa0e526ad048e032c9da8800
Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-10-05 16:25:55 +00:00
Dave Barach
f9faf2420c DOC ONLY: clean up plugin documentation
The old "sample_plugin" page was stuffed with superceded autotools
build information, so it morphed into an "add a new plugin" page based
on the emacs-lisp plugin generator.

Before sending hate mail about emacs, please *look* at the new
document: you'll find running the plugin generator hard to tell from
running a shell script.

Change-Id: I84da45675e838c05faeca05c8f7be45d8c7bff13
Signed-off-by: Dave Barach <dave@barachs.net>
2018-10-05 13:48:00 +00:00
Scott Keeler
25c4d396ea docs: add contiv vpp
Change-Id: I92227fc4968fc6a478beb7f38707b91e9f0635ec
Signed-off-by: Scott Keeler <skeeler@cisco.com>
2018-10-05 13:47:42 +00:00
Juraj Sloboda
2d24cd0272 NAT: convert remaining clib_warning to nat_log_*
Change-Id: Ie999ab852cc3775ec90820624d97be746d2590a4
Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
2018-10-05 13:32:55 +00:00
Paul Vinciguerra
98afc711c5 node_cli: Give the user a hint as to the problem.
tested with:
DBGvpp# show node foo
show node: unknown node name: 'foo'

DBGvpp# show node error-drop
node error-drop, type internal, state active, index 543
node function variants:
    ...

DBGvpp# show node error-drop bar
show node: unknown input 'bar'

Change-Id: I896cee9e60028a189dce83666fa4d32a14983a7b
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2018-10-05 11:47:18 +00:00
Florin Coras
326b81e30e session: fix local session tagging and cleanup
Change-Id: I0d42a0c71fea7dd669fb1fe5ded7e6e944245c7d
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-05 11:40:58 +00:00
Juraj Sloboda
b3f9050331 vhost_user: Add test for interface states and events
Change-Id: I2c330945bb0b07f649f574a055bfbea455e5d0b3
Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
2018-10-05 10:13:18 +02:00
John Lo
d63abff00f On interface deletion - make sure any vlan qinq table is cleared
Change-Id: Ie9bb1cfce2369b448ca55a21b2f8b8bbbb81c59c
Signed-off-by: John Lo <loj@cisco.com>
2018-10-05 06:25:32 +00:00
Ian Wells
412ecd320a Improve ip_mroute_add_del documentation
Change-Id: Ieb882cc67c37bf591b6c737234263c7c35416e6d
Signed-Off-By: Ian Wells <iawells@cisco.com>
2018-10-05 03:46:48 +00:00
Eyal Bari
efd9cf302f vxlan:ip4 decap:remove access to tunnel object
store local/remote addresses + vrf + vni in hash key
store complete decap info in hash value (sw_if_index + next_index +
error)

this removes the need to access the tunnel object when matching both
unicast and mcast.

however for mcast handling it requires 3 hash lookups:
* one failed unicast lookup (by src+dst addrs)
* lookup by mcast(dst) addr .
* unicast lookup (tunnel local ip as dst + pkt's src addr)

where previously it needed 2:
* lookup by src to find unicast tunnel + compare dst to local addr
(failing for mcast)
* lookup by mcast to find the mcast tunnel

Change-Id: I7a3485d130a54194b8f7e2df0431258db36eceeb
Signed-off-by: Eyal Bari <ebari@cisco.com>
2018-10-05 03:25:39 +00:00
Florin Coras
dc7b1aa1e3 vcl: fix test throughput computation
Change-Id: I78260cd1a412e93a5d6686888b6ea17f52245a4a
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-04 18:47:53 +00:00
Juraj Sloboda
3048b63de9 Support reassembly for fragments coming to ip4-local node
Change-Id: I3aa4708c1c3cdda344f282d56b617677080eaaa1
Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
2018-10-04 17:55:10 +00:00
Andrew Yourtchenko
6f40a8a4c5 acl-plugin: tuplemerge: avoid batch-resize of the applied entries vector - VPP-1352
If the number of rules within a given partition exceeds the limit,
the split_partition() might get called, in which we calculate
the relaxed mask, create a new partition with that mask and
attempt to reallocate some entries from the overcrowded partition.

The non-TM code was pre-expanding the vector with rules by
the number of rules in the new ACL being applied - which
caused the split_partition() to iterate over the rules
filled with zeroes. Most of the time it is benign, but
if a newly created relaxed partition is such that these
entries can be "relocated", then the code attempts to
do so, which does not end well.

Change-Id: I2dbf3ccd29ff97277b21cdb11c4424ff0915c3b7
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2018-10-04 17:53:44 +00:00
Florin Coras
a44d6b133b udp_echo: fix cut-through server mode
Change-Id: I20dd2071c936eb2c1870d45860553007c8e20587
Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-10-04 17:51:30 +00:00
Neale Ranns
3e42ebe6ab MFIB-API: when programming an (S,G) fix the grp-len
Change-Id: I97052d29080501de53fe95499c860faf0765e81d
Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
2018-10-04 17:50:59 +00:00
Neale Ranns
2329e090fc clib_count_equal_*: don't read of the end of a small array and init data only if used (VPP-1429)
Change-Id: I8afa57ecca590698d3430746968aa0a5b0070469
Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-10-04 15:28:42 +00:00
Marco Varlese
29d22c5206 VPP-1430: remove unnecessary padding
A copy/paste mistake caused to add padding to the buffer used to send
data.

Change-Id: I04d8dfec4ae195927be1675c5ce8b30230d5b376
Signed-off-by: Marco Varlese <marco.varlese@suse.com>
2018-10-04 12:36:04 +00:00
John Lo
06fda9cea9 Fix handling of mpls_tunnel_add_del API
Handles next_hop_weight, next_hop_preference and next_hop_table_id
properly in vl_api_mpls_tunnel_add_del_t_handler(). Also updated
vpp_api_test and custom_dump handling of related APIs.

Change-Id: I89e211bfa3b9d8ead396b24b3c46b7c7f6511f44
Signed-off-by: John Lo <loj@cisco.com>
2018-10-04 07:46:10 +00:00