vpp.git
5 years agosession: cleanup use of api_client_index 61/16061/5
Florin Coras [Tue, 20 Nov 2018 19:31:26 +0000 (11:31 -0800)]
session: cleanup use of api_client_index

Change-Id: I8a680be62ab91d2ccb144641981a635506973a49
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoethernet-input: fix assert in l2 mode 64/16064/2
Damjan Marion [Tue, 20 Nov 2018 23:47:42 +0000 (00:47 +0100)]
ethernet-input: fix assert in l2 mode

Change-Id: I3befc762694e7c6d6847c361a144f72547038ba1
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoAdd wireshark dissector to extras 65/16065/1
Dave Barach [Wed, 21 Nov 2018 01:15:37 +0000 (20:15 -0500)]
Add wireshark dissector to extras

See extras/wireshark/readme.md for a quick writeup.

Change-Id: Id48d198aa2f1d643d0587947fe9c3fd62b613a9f
Signed-off-by: Dave Barach <dbarach@cisco.com>
5 years agoAdd buffer tracing to the dispatch tracer 60/16060/3
Dave Barach [Tue, 20 Nov 2018 17:08:39 +0000 (12:08 -0500)]
Add buffer tracing to the dispatch tracer

Change-Id: I56f25d653b71a25c70e6c5c1a93dd9c5158f2079
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agomemif input-node improvements 54/16054/3
Damjan Marion [Tue, 20 Nov 2018 13:20:15 +0000 (14:20 +0100)]
memif input-node improvements

Change-Id: Ida2262238c0558d8340f05c678a84e76f990935d
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoethernet-input optimizations 42/15842/16
Damjan Marion [Wed, 14 Nov 2018 15:55:53 +0000 (16:55 +0100)]
ethernet-input optimizations

Change-Id: I4ec7750ef58363bd8966a16a2baeec6db18b7e9e
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agovhost-user: cleanup 62/16062/2
Damjan Marion [Tue, 20 Nov 2018 20:07:03 +0000 (21:07 +0100)]
vhost-user: cleanup

Change-Id: Ibf68423e9514b8e85cdf0a3e57ababd55dd4fcc4
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoIPSEC: remove duplicate memcy 59/16059/2
Neale Ranns [Tue, 20 Nov 2018 17:06:25 +0000 (09:06 -0800)]
IPSEC: remove duplicate memcy

Change-Id: If91257fa23ba74c09e5c3b5528eb2fd4c4b36b6a
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agomake test: Shorten VCL extended test times 15/13215/9
Dave Wallace [Tue, 26 Jun 2018 05:14:04 +0000 (01:14 -0400)]
make test: Shorten VCL extended test times

- And include them in regular CI testing

Change-Id: I519fd07e1482baf6808601b3c928b825f9691c87
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
5 years agoFix inspection for 18.10, requirements 58/16058/2
jdenisco [Tue, 20 Nov 2018 16:25:17 +0000 (11:25 -0500)]
Fix inspection for 18.10, requirements

Change-Id: I1ecc278f43afff184a26f6f18fe22a49d8916eb1
Signed-off-by: jdenisco <jdenisco@cisco.com>
5 years agoLink speed sent as little endian across API 46/16046/3
Ole Troan [Tue, 20 Nov 2018 10:03:10 +0000 (11:03 +0100)]
Link speed sent as little endian across API

Change-Id: I03c991cbf13c6d3599bfb5a60b18dc8ec9390414
Signed-off-by: Ole Troan <ot@cisco.com>
5 years agoacl-plugin: performance optimizations for established connections 08/14708/12
Andrew Yourtchenko [Thu, 25 Oct 2018 16:49:45 +0000 (18:49 +0200)]
acl-plugin: performance optimizations for established connections

Change-Id: Id5b7429ca7cce10ce8022c9b8a223bd02f6c3b5f
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
5 years agoNAT44: fix virtual fragmentation reassembly in forwarding mode (VPP-1501) 48/16048/2
Matus Fabian [Tue, 20 Nov 2018 10:19:05 +0000 (02:19 -0800)]
NAT44: fix virtual fragmentation reassembly in forwarding mode (VPP-1501)

Change-Id: Id86d8aa8753b9b2ff4c709b11e3901ba8d552918
Signed-off-by: Matus Fabian <matfabia@cisco.com>
5 years agovlib: reset frame flags when frame is reused 42/16042/2
Damjan Marion [Tue, 20 Nov 2018 08:55:10 +0000 (09:55 +0100)]
vlib: reset frame flags when frame is reused

Change-Id: I8f4843e7a961a1e6c3fd057554b31ae49fc9b328
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agovom: Add support for redirect contracts in gbp 13/16013/5
Mohsin Kazmi [Sun, 18 Nov 2018 23:12:11 +0000 (00:12 +0100)]
vom: Add support for redirect contracts in gbp

Change-Id: I18543785166811ddbd628d19065d3dfad3f948e9
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
5 years agovlib: add vlib_buffer_enqueue_to_single_next(...) function 43/16043/2
Damjan Marion [Tue, 20 Nov 2018 08:56:01 +0000 (09:56 +0100)]
vlib: add vlib_buffer_enqueue_to_single_next(...) function

Change-Id: I485dd07ea0fe032bdd5990567578e73e9bcffe1e
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agovppinfra: add 128 and 256 bit vector scatter/gather inlines 44/16044/3
Damjan Marion [Tue, 20 Nov 2018 09:06:57 +0000 (10:06 +0100)]
vppinfra: add 128 and 256 bit vector scatter/gather inlines

Change-Id: If6c65f16c6fba8beb90e189c1443c3d7d67ee02c
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agodhcp4:(VPP-1483) linearize chained packets before handling 59/15759/6
Eyal Bari [Mon, 5 Nov 2018 11:29:25 +0000 (13:29 +0200)]
dhcp4:(VPP-1483) linearize chained packets before handling

dhcp packets might (when flooded) arrive in chains of cloned buffers

Change-Id: Ifddecd656b6a5d6ba8cd94184f5c021684e35548
Signed-off-by: Eyal Bari <ebari@cisco.com>
5 years agoVPP-1498: test/framework.py: AttributeError 10/16010/2
Paul Vinciguerra [Sun, 18 Nov 2018 16:17:34 +0000 (08:17 -0800)]
VPP-1498: test/framework.py: AttributeError

Traceback if .send_keep_alive is called before pipe is configured.

Traceback (most recent call last):
      File "/vpp/test/test_span.py", line 27, in setUpClass
        super(TestSpan, cls).setUpClass()
      File "/vpp/test/framework.py", line 411, in setUpClass
        cls.reporter.send_keep_alive(cls, 'setUpClass')
      File "/vpp/test/framework.py", line 172, in send_keep_alive
        if self.pipe is None:
      File "/vpp/test/framework.py", line 160, in pipe
        return self._pipe
    AttributeError: 'KeepAliveReporter' object has no attribute '_pipe'

Change-Id: I561d2748441702478a84fbb4580a4d2667d70ffd
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
5 years agoImprove feature arc order constraint specification 34/16034/2
Dave Barach [Mon, 19 Nov 2018 14:31:48 +0000 (09:31 -0500)]
Improve feature arc order constraint specification

Add the VNET_FEATURE_ARC_ORDER macro, which allows specification of
bulk order constraints. Here's an example:

VNET_FEATURE_ARC_ORDER(ip4_unicast_arc_order, static) = {
  .arc_name = "ip4-unicast",
  .node_names = VNET_FEATURES ("ip4-flow-classify",
                               "ip4-inacl",
                               "ip4-source-check-via-rx",
                               "ip4-source-check-via-any",
                               "ip4-source-and-port-range-check-rx",
                               "ip4-policer-classify",
                               "ipsec4-input",
                               "vpath-input-ip4",
                               "ip4-vxlan-bypass",
                               "ip4-not-enabled",
                               "ip4-lookup"),
};

Simply list feature nodes in the desired order, and you're
done. Multiple macro instances per are are fine / expected /
tested.

Under the covers: generate "a before b" tuples by chain-dragging
across the ordered list. No need to touch existing per-feature
constraints.

Fixed a long-broken "you lose!" error message.

Change-Id: I259282e426fd305e22c8d65886787c41a1d348d3
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agoNAT44: fix bug in TCP close with output-feature interface (VPP-1493) 98/15998/2
Matus Fabian [Fri, 16 Nov 2018 12:41:31 +0000 (04:41 -0800)]
NAT44: fix bug in TCP close with output-feature interface (VPP-1493)

Change-Id: If8c883d6b1ee58de9a03012d3567ec82211a0225
Signed-off-by: Matus Fabian <matfabia@cisco.com>
5 years agoadd vlib_prefetch_buffer_data(...) macro 12/16012/1
Damjan Marion [Sun, 18 Nov 2018 22:48:43 +0000 (23:48 +0100)]
add vlib_prefetch_buffer_data(...) macro

Change-Id: Iba750a41262cc028ad0363fff78cc219e4a33538
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoEnable l4 checksum offload for ThunderX PMD 66/15966/3
Federico Claramonte [Thu, 15 Nov 2018 12:19:29 +0000 (13:19 +0100)]
Enable l4 checksum offload for ThunderX PMD

Change-Id: I6a6ab6d8d9aeca9df3ba8a3ac519be25aaa796e8
Signed-off-by: Federico Claramonte <fede.claramonte@caviumnetworks.com>
5 years agovcl/session: apps with process workers 17/15917/17
Florin Coras [Tue, 13 Nov 2018 23:52:38 +0000 (15:52 -0800)]
vcl/session: apps with process workers

Allow apps to register child processes as app workers. In particular,
on fork vcl now registers the child process with vpp as a new worker.

Change-Id: I52a65fbc3292962b1f6e1fe0f6153f739e6e0d4a
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoComplain if a client binary API queue is full 11/16011/2
Dave Barach [Sun, 18 Nov 2018 17:03:48 +0000 (12:03 -0500)]
Complain if a client binary API queue is full

Definitely indicates a client binary API queue handling issue. We
can't simply turf the message, or we'll end up with a more subtle
derivative misbehavior.

Change-Id: I6363fda1430b0a9ec33ad69badc1e0072fe20fa8
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agomac_address_t: size to 6 bytes so it represents wire format 00/16000/3
Neale Ranns [Fri, 16 Nov 2018 13:20:36 +0000 (05:20 -0800)]
mac_address_t: size to 6 bytes so it represents wire format

Change-Id: I4d6b505a2b1e0cb960a4145796351ad1bc7e860d
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agopcap-based dispatch tracer 05/16005/2
Dave Barach [Fri, 16 Nov 2018 22:19:00 +0000 (17:19 -0500)]
pcap-based dispatch tracer

To facilitate dispatch trajectory tracing, vlib_buffer_t decoding, etc.
through Wireshark

Change-Id: I31356b9fa1f40cba8830aaf10a86a9fbb7546438
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agoldp: fixes/improvements to select 07/16007/2
Florin Coras [Sat, 17 Nov 2018 02:56:28 +0000 (18:56 -0800)]
ldp: fixes/improvements to select

Change-Id: I3f3e8fce01309da02689c7e9d23cf1b3181e78c9
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoIP-punt: add documentation to the API and fix IP address init 91/15991/2
Neale Ranns [Fri, 16 Nov 2018 08:53:53 +0000 (00:53 -0800)]
IP-punt: add documentation to the API and fix IP address init

Change-Id: I0bdff4dbfd81d67e82211ce9fdc97209a1b23c66
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoVPP-1496 Cleanup stats socket on exit. 71/15971/3
Paul Vinciguerra [Thu, 15 Nov 2018 15:14:27 +0000 (07:14 -0800)]
VPP-1496 Cleanup stats socket on exit.

Stats socket not cleaned up on exit.

vagrant@vpp:/tmp/vpp-failed-unittests/vpp-unittest-VCLCutThruTestCase-clRggF-FAILED$ ls -ltr

total 104

srwxrwxr-x 1 vagrant vagrant     0 Nov 14 18:21 stats.sock

Change-Id: I8126e70da2983222ca430aa280f3b9e45eea7ca4
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
5 years agoVPP-1495: Fix intermittent stat sock test failures. 73/15973/4
Paul Vinciguerra [Thu, 15 Nov 2018 16:13:03 +0000 (08:13 -0800)]
VPP-1495: Fix intermittent stat sock test failures.

Loosen polling loop while waiting for stats socket.

==============================================================================
Classifier IP6 UDP proto Test Case
==============================================================================
connect: No such file or directory
==============================================================================
ERROR: setUpClass (test_ip4.TestIPLoadBalance)
------------------------------------------------------------------------------
Traceback (most recent call last):
  File "/vpp/test/framework.py", line 424, in setUpClass
    cls.statistics = VPPStats(socketname=cls.stats_sock)
  File "build/bdist.linux-x86_64/egg/vpp_papi/vpp_stats.py", line 120, in _init_
    raise IOError()
IOError

Change-Id: I80523122f96eafc41b3ebbf27bee73f6c637d781
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
5 years agoQoS: fix always recoding as IP 53/15953/2
Neale Ranns [Thu, 15 Nov 2018 07:46:12 +0000 (07:46 +0000)]
QoS: fix always recoding as IP

Change-Id: I7a54cdfa26652c04971999ad1f8144566e13c7bf
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoGBP: redirect contracts 07/15807/9
Neale Ranns [Wed, 7 Nov 2018 17:25:54 +0000 (09:25 -0800)]
GBP: redirect contracts

Change-Id: I463b153de93cfec29a9c15e8e84e41f6003d4c5f
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoVPP-1474: fix 2x coverity warnings 46/15946/2
Dave Barach [Wed, 14 Nov 2018 16:42:03 +0000 (11:42 -0500)]
VPP-1474: fix 2x coverity warnings

Change-Id: I441beaf3d7f57886580d7cce35ef592aa0fcca5f
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agoacl-plugin: fix coverity error 188909 in unit-test code 38/15938/2
Andrew Yourtchenko [Wed, 14 Nov 2018 15:39:39 +0000 (16:39 +0100)]
acl-plugin: fix coverity error 188909 in unit-test code

The assignment was redundant with a one just a dozen lines above
in the case of the ACL loaded being non-empty, so its only
apparent purpose in life was make coverity unhappy...
Thus fix by deletion.

Change-Id: I573308cb9c212bdfdca2551aa381720dbbcb006e
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
5 years agoip4-input: fix prefetch data issue for tunnel decap cases 57/15757/4
Zhiyong Yang [Wed, 7 Nov 2018 05:04:28 +0000 (00:04 -0500)]
ip4-input: fix prefetch data issue for tunnel decap cases

There are two reasons to modify the existing code ip4_input_inline.

1. For many tunnel decap cases, inner ip header or its part is possible
in the second cacheline, not first cacheline only after the field "data",
and this will cause data cache miss once the second cacheline is needed
to access. e.g vxlan-gpe.
2. For most of cases, "data" is the starting address of ethernet
header, not IP header. The existing code causes misunderstanding
from code readability perspective.

Change-Id: I43e119b899dbde95803bccbac54259729fd2cddf
Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
Signed-off-by: Yuwei Zhang <yuwei1.zhang@intel.com>
5 years agoipsec: infra for selecting backends 23/15823/10
Klement Sekera [Thu, 8 Nov 2018 12:00:02 +0000 (13:00 +0100)]
ipsec: infra for selecting backends

Change-Id: Ifa6d8391b1b2413a88b7720fc434e0bc849a149a
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
5 years agosession: fix endpt cfg test (VPP-1492) 47/15947/5
Florin Coras [Wed, 14 Nov 2018 17:32:07 +0000 (09:32 -0800)]
session: fix endpt cfg test (VPP-1492)

Change-Id: I0f2266c4727a96b6410a3084dc079bae7bc649ab
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoVXLAN-GBP: c-n-p error in the dual-loop tracing 40/15940/2
Neale Ranns [Wed, 14 Nov 2018 16:18:12 +0000 (08:18 -0800)]
VXLAN-GBP: c-n-p error in the dual-loop tracing

Change-Id: I3722a1850f7a72e4382e351120c1514d7a1759b8
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoVPP-1477: Replace DatatypeConverter.printHexBinary with bytesToHex 33/15933/4
Michal Cmarada [Wed, 14 Nov 2018 13:05:42 +0000 (14:05 +0100)]
VPP-1477: Replace DatatypeConverter.printHexBinary with bytesToHex

As of Java 11 javax.xml.bind.DatatypeConverter is no longer part of
standard Java distribution, therefore it is replaced by equivalent method.

Change-Id: I51726d0d0d02782bd3bb1dbdc54df5bd63bd8f15
Signed-off-by: Michal Cmarada <mcmarada@cisco.com>
5 years agoRemove c-11 memcpy checks from perf-critical code 16/15916/4
Dave Barach [Tue, 13 Nov 2018 21:34:13 +0000 (16:34 -0500)]
Remove c-11 memcpy checks from perf-critical code

Change-Id: Id4f37f5d4a03160572954a416efa1ef9b3d79ad1
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agovcl/ldp: fix poll 18/15918/4
Florin Coras [Wed, 14 Nov 2018 06:44:54 +0000 (22:44 -0800)]
vcl/ldp: fix poll

Change-Id: I8eb5546ff8634d5498d8ce5bbc9407bceb9ae3ef
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agodocs and Config utility, package cloud support 11/15911/2
jdenisco [Tue, 13 Nov 2018 17:40:12 +0000 (12:40 -0500)]
docs and Config utility, package cloud support

Change-Id: I61303242b73e509df42dedba54f2ee5906a7e526
Signed-off-by: jdenisco <jdenisco@cisco.com>
5 years agotcp: cubic improvements 95/15895/3
Florin Coras [Tue, 13 Nov 2018 08:03:43 +0000 (00:03 -0800)]
tcp: cubic improvements

- avoid cwnd excessive increments on threshold changes
- fix K computation when fastconvergence is on

Change-Id: I99c36abc879e63aecc0617f7aed5a2f68430ba71
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agotcp: cubic fast convergence 92/15892/7
Florin Coras [Mon, 12 Nov 2018 17:13:10 +0000 (09:13 -0800)]
tcp: cubic fast convergence

Change-Id: I3a15960fe346763faf13e8728ce36c2f3bf7b05a
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agovlib:remove unused argument 56/15856/2
Eyal Bari [Mon, 12 Nov 2018 14:13:49 +0000 (16:13 +0200)]
vlib:remove unused argument

Change-Id: I88c3d3e516401bb1c84991515cd701c156ae19dd
Signed-off-by: Eyal Bari <ebari@cisco.com>
5 years agoipsec: fix typo 01/15901/4
Klement Sekera [Mon, 12 Nov 2018 13:42:00 +0000 (14:42 +0100)]
ipsec: fix typo

Change-Id: I04c59bbe1780e7289cb27a0a912803812fdc297e
Signed-off-by: Klement Sekera <ksekera@cisco.com>
5 years agojapi: Move Java API binding to cmake 47/15047/9
Mohsin Kazmi [Thu, 13 Sep 2018 07:59:50 +0000 (09:59 +0200)]
japi: Move Java API binding to cmake

Change-Id: I264d547a06e3636d021a74cd26efb8137f629cbc
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Signed-off-by: Michal Cmarada <mcmarada@cisco.com>
5 years agoIGMP: improve CLI debug output 08/15908/2
Neale Ranns [Tue, 13 Nov 2018 13:27:18 +0000 (13:27 +0000)]
IGMP: improve CLI debug output

Change-Id: If88fc3acdba1f73b3e8be94d8014556c5239596c
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoL2 feautre bitmaps output verbose/non-verbose mode 51/15851/2
Neale Ranns [Fri, 9 Nov 2018 16:19:27 +0000 (08:19 -0800)]
L2 feautre bitmaps output verbose/non-verbose mode

Change-Id: I15ff191ee8724a3354c074db590472db05e0652e
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agovlib rename vlib_frame_args(...) to vlib_frame_scalar_args(..) 97/15897/2
Damjan Marion [Sat, 10 Nov 2018 09:23:00 +0000 (10:23 +0100)]
vlib rename vlib_frame_args(...) to vlib_frame_scalar_args(..)

Typically we have scalar_size == 0, so it doesn't matter
but vlib_frame_args was providing pointer to scalar frame
data, not vector data. To avoid future confusion function
is renamed to vlib_frame_scalar_args(...)

Change-Id: I48b75523b46d487feea24f3f3cb10c528dde516f
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agotcp: handle disconnects after enq notifications 45/15845/4
Florin Coras [Fri, 9 Nov 2018 22:34:08 +0000 (14:34 -0800)]
tcp: handle disconnects after enq notifications

Make sure that we notify the app of the data enqueued in the burst
before notifying of disconnect.

Change-Id: I7747a5cbb4c6bc9132007f849c24ce04b7841273
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agodocs: add 1810, including package cloud 43/15843/2
jdenisco [Fri, 9 Nov 2018 20:20:26 +0000 (15:20 -0500)]
docs: add 1810, including package cloud

Change-Id: Ieae5fc7c1e099392bc2a4e5948669d9210f2ebac
Signed-off-by: jdenisco <jdenisco@cisco.com>
5 years agoIPv6: Make link-local configurable per-interface (VPP-1446) 03/15503/4
Juraj Sloboda [Mon, 22 Oct 2018 07:57:13 +0000 (09:57 +0200)]
IPv6: Make link-local configurable per-interface (VPP-1446)

Remove old nonfunctional code for setting link-local addresses.
Use common API for setting all IPv6 addresses.

Change-Id: I562329df86341f81ef2441510a9eefbbf710f6e0
Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
Signed-off-by: Matus Fabian <matfabia@cisco.com>
5 years agoproxy-app: fix active connect 44/15844/3
Florin Coras [Fri, 9 Nov 2018 21:40:02 +0000 (13:40 -0800)]
proxy-app: fix active connect

Change-Id: Ib55684dd3f1d39f5436d6feb2fb105583027493c
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agopmalloc: u32 pp->index leads to va address overrun 47/15847/1
Kingwel Xie [Sat, 10 Nov 2018 07:56:00 +0000 (02:56 -0500)]
pmalloc: u32 pp->index leads to va address overrun

when pagesize is 1G, this pm->base + (pp->index << pm->def_log2_page_sz) would very soon overrun if creating multiple mempools
add a (uword) to it

Change-Id: If769b99d344cc3f547418a242a7497d044071615
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
5 years agoFix logging into multiple files 37/15837/2
juraj.linkes [Fri, 9 Nov 2018 10:58:54 +0000 (11:58 +0100)]
Fix logging into multiple files

When running tests in one process, only one logger was used and each
testcase added its own file handler, which resulted in logs appearing in
multiple files. Fix this by restoring the creation of new loggers
for each testcase and only reuse the stream handler from parent process.

Change-Id: I5b8471e041dc769128fddb433d33812bfcb5ecf6
Signed-off-by: juraj.linkes <juraj.linkes@pantheon.tech>
5 years agodpdk: configure ip4 header checksum rx offload properly 46/15846/1
Damjan Marion [Fri, 9 Nov 2018 22:30:20 +0000 (23:30 +0100)]
dpdk: configure ip4 header checksum rx offload properly

Change-Id: I3daf8d473aa37b4597d130d19913b782cf7b8511
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoGBP: Fix error-strings array in gbp-vxlan4 41/15841/1
Neale Ranns [Fri, 9 Nov 2018 14:45:21 +0000 (06:45 -0800)]
GBP: Fix error-strings array in gbp-vxlan4

Change-Id: I36c2fa33cdc1db9a6af9b48c99e281abd8af1b6e
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agotcp: separate unit and throughput tests 33/15833/4
Florin Coras [Thu, 8 Nov 2018 21:58:19 +0000 (13:58 -0800)]
tcp: separate unit and throughput tests

Change-Id: I249e68874dcf38b07179e0e769f6eb49a43377b7
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agotcp: basic cubic implementation 79/14979/22
Florin Coras [Tue, 25 Sep 2018 21:00:34 +0000 (14:00 -0700)]
tcp: basic cubic implementation

Because the code is not optimized, newreno is still the default
congestion control algorithm.

Change-Id: I7061cc80c5a75fa8e8265901fae4ea2888e35173
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agovnet: remove unused field 30/15830/2
Damjan Marion [Thu, 8 Nov 2018 18:45:27 +0000 (19:45 +0100)]
vnet: remove unused field

It is not used and just confuses people...

Change-Id: Ic731432a785731271531f183b448e4591a1d2a8b
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoCalculate clock rounding constant 11/15811/2
Dave Barach [Wed, 7 Nov 2018 22:40:19 +0000 (17:40 -0500)]
Calculate clock rounding constant

Compute the first power of ten which is greater than 0.1% of the clock
rate. Save the result, and use it to round future results. The
previous constant value - 1e7 - didn't work properly on aarch64.

Change-Id: Ic021e3eb1b90c0d4a7d9f1b6425123f0c8b48b0b
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agovnet: store hw interface speed in kbps instead of using flags 28/15828/4
Damjan Marion [Thu, 8 Nov 2018 14:30:16 +0000 (15:30 +0100)]
vnet: store hw interface speed in kbps instead of using flags

Change-Id: Idd4471a3adf7023e48e85717f00c786b1dde0cca
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoIP load-balance; trace at the end of the node so the flow hash used is displayed 29/15829/2
Neale Ranns [Thu, 8 Nov 2018 15:31:36 +0000 (07:31 -0800)]
IP load-balance; trace at the end of the node so the flow hash used is displayed

Change-Id: Idbce0393fc9e6e8dbb2765ed164ba7f90d1ffccc
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoavf: update virtchnl header file 27/15827/2
Damjan Marion [Thu, 8 Nov 2018 13:55:07 +0000 (14:55 +0100)]
avf: update virtchnl header file

Change-Id: I755525d953605561477eeb2252ef38c60000c70a
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agophysmem: Add physmem map support 06/15806/3
Mohsin Kazmi [Wed, 7 Nov 2018 15:55:18 +0000 (16:55 +0100)]
physmem: Add physmem map support

This patch adds support for mapping the virtual address to physical
address and size of memory allocated.

Change-Id: I7659a1881308e89b215c486fecd7c973076d0773
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
5 years agotlsopenssl: remove unused #include 22/15822/2
Klement Sekera [Thu, 8 Nov 2018 12:06:24 +0000 (13:06 +0100)]
tlsopenssl: remove unused #include

Change-Id: I294e4f93e925c58765d4692337208fcee7d12886
Signed-off-by: Klement Sekera <ksekera@cisco.com>
5 years agomake test: remove unnecessary check 21/15821/2
Klement Sekera [Thu, 8 Nov 2018 12:05:37 +0000 (13:05 +0100)]
make test: remove unnecessary check

Change-Id: I90ee144a5c5a2e753e36d45c0ce98c9a8b477f15
Signed-off-by: Klement Sekera <ksekera@cisco.com>
5 years agomake test: bfd refactor 17/15817/4
Klement Sekera [Thu, 8 Nov 2018 10:52:04 +0000 (11:52 +0100)]
make test: bfd refactor

Change-Id: I14a126521d8c8138904c8b9da05d4144c72c51a5
Signed-off-by: Klement Sekera <ksekera@cisco.com>
5 years agomake test: rename dummy test name 16/15816/2
Klement Sekera [Thu, 8 Nov 2018 10:49:04 +0000 (11:49 +0100)]
make test: rename dummy test name

Change-Id: I5727b08bdc8bdaaf83a9f08d171d76bd6f67564e
Signed-off-by: Klement Sekera <ksekera@cisco.com>
5 years agomake test: p2p ethernet refactor 15/15815/3
Klement Sekera [Thu, 8 Nov 2018 10:24:34 +0000 (11:24 +0100)]
make test: p2p ethernet refactor

Change-Id: I48b4b3eaa84e4174e4d0305594675bf983184fa0
Signed-off-by: Klement Sekera <ksekera@cisco.com>
5 years agotcp: pacer and mrtt estimation improvements 08/15808/8
Florin Coras [Wed, 7 Nov 2018 20:49:19 +0000 (12:49 -0800)]
tcp: pacer and mrtt estimation improvements

- update pacer once per burst
- better estimate initial rtt
- compute smoothed average for higher precision rtt estimate

Change-Id: I06d41a98784cdf861bedfbee2e7d0afc0d0154ef
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agovlib: use index to free suspended frame 12/15812/2
Florin Coras [Thu, 8 Nov 2018 04:46:38 +0000 (20:46 -0800)]
vlib: use index to free suspended frame

Avoids crash if suspended_process_frames grows.

Change-Id: Id26ef0dd0dd001b997c531c4dec004e7e7989670
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoGBP: fix for coverity found errors 14/15814/2
Neale Ranns [Thu, 8 Nov 2018 08:13:58 +0000 (00:13 -0800)]
GBP: fix for coverity found errors

Change-Id: Id69678adb578b323ae18034d1b1fddb7417bcc08
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agopmalloc: fix shared mappings 05/15805/1
Damjan Marion [Wed, 7 Nov 2018 16:55:26 +0000 (17:55 +0100)]
pmalloc: fix shared mappings

Change-Id: I6782544d5ee0a66b1a027874b23574416093ca92
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoVOM: GBP missing header file exports 75/15775/2
Neale Ranns [Wed, 7 Nov 2018 12:03:13 +0000 (04:03 -0800)]
VOM: GBP missing header file exports

Change-Id: I24a894bde170669a05f1a7d58afc70524538f060
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoGBP: Endpoints with VLAN tags and birdges that don't learn 86/15786/2
Neale Ranns [Wed, 7 Nov 2018 12:21:12 +0000 (04:21 -0800)]
GBP: Endpoints with VLAN tags and birdges that don't learn

Change-Id: I20192f3a8f4f01f47e775746f6fde7c685f185ee
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agotcp: consume incoming buffers instead of reusing 33/15733/12
Florin Coras [Mon, 5 Nov 2018 23:57:21 +0000 (15:57 -0800)]
tcp: consume incoming buffers instead of reusing

Instead of reusing buffers for acking, consume all buffers and program
output for (dup)ack generation. This implicitly fixes the drop counters
that were artificially inflated by both data and feedback traffic.

Moreover, the patch also significantly reduces the ack traffic as we now
only generate an ack per frame, unless duplicate acks need to be sent.

Because of the reduced feedback traffic, a sender's rx path and a
receiver's tx path are now significantly less loaded. In particular, a
sender can overwhelm a 40Gbps NIC and generate tx drop bursts for low
rtts. Consequently, tx pacing is now enforced by default.

Change-Id: I619c29a8945bf26c093f8f9e197e3c6d5d43868e
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoOptimize xxx_zero_byte_mask NEON function 56/15756/2
Lijian Zhang [Wed, 31 Oct 2018 05:35:20 +0000 (13:35 +0800)]
Optimize xxx_zero_byte_mask NEON function

Optimize zero byte mask NEON functions below with less intrinsics,
and get their outputs consistent with functions in vector_sse42.h

always_inline u32 u64x2_zero_byte_mask (u64x2 input)
always_inline u32 u32x4_zero_byte_mask (u32x4 input)
always_inline u32 u16x8_zero_byte_mask (u16x8 input)
always_inline u32 u8x16_zero_byte_mask (u8x16 input)
always_inline u32 i64x2_zero_byte_mask (i64x2 input)
always_inline u32 i32x4_zero_byte_mask (i32x4 input)
always_inline u32 i16x8_zero_byte_mask (i16x8 input)
always_inline u32 i8x16_zero_byte_mask (i8x16 input)

Change-Id: I7f485915baeb37fa2dd484699b8769e0136f6574
Signed-off-by: Lijian Zhang <Lijian.Zhang@arm.com>
Reviewed-by: Sirshak Das <Sirshak.Das@arm.com>
5 years agol2: convert l2_patch to new multiarch scheme 40/15740/2
Damjan Marion [Tue, 6 Nov 2018 12:33:27 +0000 (13:33 +0100)]
l2: convert l2_patch to new multiarch scheme

Change-Id: I30487bd736407378fb5a6d313e4eef12bbb262b8
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoGBP Endpoint Learning 23/15223/12
Neale Ranns [Wed, 10 Oct 2018 14:22:51 +0000 (07:22 -0700)]
GBP Endpoint Learning

Learning GBP endpoints over vxlan-gbp tunnels

Change-Id: I1db9fda5a16802d9ad8b4efd4e475614f3b21502
Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
5 years agoNAT44: fix undesired dependency between static mapping and address from the pool... 58/15758/2
Matus Fabian [Wed, 7 Nov 2018 07:17:31 +0000 (23:17 -0800)]
NAT44: fix undesired dependency between static mapping and address from the pool (VPP-1485)

Change-Id: Iaa404361eac2a6612dcdaba3f73bae41a35c5446
Signed-off-by: Matus Fabian <matfabia@cisco.com>
5 years agoUnresolved symbols in libvapiclient 70/15770/1
Neale Ranns [Wed, 7 Nov 2018 10:20:36 +0000 (02:20 -0800)]
Unresolved symbols in libvapiclient

Change-Id: I6d6a73ac62f24928fb51e89948b92a1cb9134c40
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoUpdate the vpp config utility 54/15754/2
jdenisco [Tue, 6 Nov 2018 21:10:04 +0000 (16:10 -0500)]
Update the vpp config utility

Change-Id: If278d7c6dda9e29736f5aa6f1cb04b49da378509
Signed-off-by: jdenisco <jdenisco@cisco.com>
5 years agovmxnet3: reduce calling vmxnet3_reg_write_inline 79/15679/3
Steven [Fri, 2 Nov 2018 23:28:52 +0000 (16:28 -0700)]
vmxnet3: reduce calling vmxnet3_reg_write_inline

In output.c, we buffer the descriptors and call vmxnet3_reg_write_inline
once outside the loop. This change improves the performance dramatically.

When refilling the ring, there is no need to inform the device unless
explicitly specified by the device (ctrl.update_prod == 1)

Change-Id: I7031d58bff0d249e913d14236d416c91eb6ab94a
Signed-off-by: Steven <sluong@cisco.com>
5 years agoVCL: Fix socket_test.sh to build test apps. 55/15755/2
Dave Wallace [Tue, 6 Nov 2018 22:45:32 +0000 (17:45 -0500)]
VCL: Fix socket_test.sh to build test apps.

- Replace autoconf base test app build detection
  with appropriate cmake based incantation.
- Use the dpdk_devbind.py that is in the VPP tree.

Change-Id: I4cdc11d159e2413d6bdb9c5ffcf1ed2d787b1cc5
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
5 years agomarvell: bump musdk version to 18.09.3 53/15753/2
Damjan Marion [Tue, 6 Nov 2018 19:34:07 +0000 (19:34 +0000)]
marvell: bump musdk version to 18.09.3

Change-Id: Ifb841312d4a382547153b24903230b407f649e73
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agodpdk: don't automatically whitelist vmxnet3 PCI interfaces 52/15752/2
Steven [Tue, 6 Nov 2018 20:32:58 +0000 (12:32 -0800)]
dpdk: don't automatically whitelist vmxnet3 PCI interfaces

If no PCI address is specified in dpdk config, the default to automatically
put all PCIs in the whitelist.
For vmxnet3 PCIs, we want to change its default to exclude the vmxnet3 PCIs.
That is to put them in the blacklist instead of whitelist.

Change-Id: I2b7061d6437910eb0e1b16df19a770cab968c602
Signed-off-by: Steven <sluong@cisco.com>
5 years agoBD ARP entry use common API types 94/15494/6
Neale Ranns [Wed, 24 Oct 2018 09:57:49 +0000 (02:57 -0700)]
BD ARP entry use common API types

Change-Id: I29f20dbaf2c2d735faff297cee552ed648f6f61b
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agodocs: Add version and build date 51/15751/2
jdenisco [Tue, 6 Nov 2018 17:32:33 +0000 (12:32 -0500)]
docs: Add version and build date

Change-Id: I6fd53d3ef12e4b6f1af1e5605c09938bce324ec9
Signed-off-by: jdenisco <jdenisco@cisco.com>
5 years agovhost: crash in vhost_user_tx_avx2 85/15685/2
Steven [Sun, 4 Nov 2018 16:20:01 +0000 (08:20 -0800)]
vhost: crash in vhost_user_tx_avx2

(gdb) bt
bt
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
(gdb) frame 5
frame 5
293       if (PREDICT_FALSE (rxvq->last_avail_idx == rxvq->avail->idx))
(gdb) p *rxvq
p *rxvq
$3 = {cacheline0 = 0x7f290bcadd80 "\377\003", qsz_mask = 1023, last_avail_idx = 0, last_used_idx = 0, n_since_last_int = 0, desc = 0x0, avail = 0x0, used = 0x0, int_deadline = 0, started = 1 '\001', enabled = 1 '\001', log_used = 0 '\000', cacheline1 = 0x7f290bcaddc0 "\377\377\377\377\016", errfd = -1, callfd_idx = 14, kickfd_idx = 19, log_guest_addr = 5151049792, mode = 0}

The crash is because we access the null pointer rxvq->avail,
which is supposed to be derived from the mmap informed by the driver.
We fixed a similar issue before in

    https://gerrit.fd.io/r/#/c/14545/

The reason was the driver ummaps the memory without doing the disconnect in
SR-IOV environment. The fixed was applied to the RX path. Now it happens in the
TX path. We just need to apply the same check in the TX path.

Change-Id: I7b1dfc96797cb5b52845bc6cec09a8c5d4325280
Signed-off-by: Steven <sluong@cisco.com>
5 years agodocs: Small changes to plugin, updated the requirements 44/15644/2
jdenisco [Wed, 31 Oct 2018 18:24:31 +0000 (14:24 -0400)]
docs: Small changes to plugin, updated the requirements

Change-Id: I3c05a28991d01e726d4fa8580a720359a2d4ce91
Signed-off-by: jdenisco <jdenisco@cisco.com>
5 years agoIGMP: Improved handling of (*,G) join and leave 49/15749/3
Neale Ranns [Tue, 6 Nov 2018 13:51:58 +0000 (05:51 -0800)]
IGMP: Improved handling of (*,G) join and leave

Change-Id: I48a92035b58d83420eb3eed3f05a75ba283543c2
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoVPP-1481: fixed tlv length checking & added tests 89/15689/5
Filip Varga [Mon, 5 Nov 2018 08:41:56 +0000 (09:41 +0100)]
VPP-1481: fixed tlv length checking & added tests

Change-Id: I9375bca5f5136c84d801dbd635929bb1c37d75b4
Signed-off-by: Filip Varga <filip.varga@pantheon.tech>
5 years agodpdk: format_dpdk_device_name cleanup 37/15737/2
Damjan Marion [Tue, 6 Nov 2018 11:56:47 +0000 (12:56 +0100)]
dpdk: format_dpdk_device_name cleanup

Change-Id: I49a5029d256df8f749ee30d19ff7473147b6516f
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoChange l2_patch from dual-loop to quad-loop 83/15383/4
Yulong Pei [Fri, 19 Oct 2018 15:29:29 +0000 (23:29 +0800)]
Change l2_patch from dual-loop to quad-loop

The change can save 1.1 clocks per packet on Intel Atom C3858 platform,
It downgraded from 2.05e1 to 1.94e1 clocks per packet.

The change can save 0.3 clocks per packet on Intel Xeon CPU E5-2699 v4 @ 2.20GHz,
It downgraded from 1.26e1 to 1.23e1 clocks per packet.

Change-Id: I1ede77fb592a797d86940a8abad9ca291a89f1c7
Signed-off-by: Yulong Pei <yulong.pei@intel.com>
5 years agodpdk: fix device name suffix confusion with failsafe/netvsc 32/15732/2
Stephen Hemminger [Mon, 5 Nov 2018 20:54:16 +0000 (12:54 -0800)]
dpdk: fix device name suffix confusion with failsafe/netvsc

When netvsc or failsafe DPDK device is used, the DPDK port id does not
match the VPP device instance id.  The code that formats the device
name was incorrectly calling DPDK device info using the VPP device
instance id. This causes the VPP interface to be named
"FortyGigabit0/2/0" based on mistakenly finding the PCI device
information of the hidden DPDK port id for the VF device.

Change-Id: I9366232f4b2087076bdcc1a58bf228007c24c084
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
5 years agodpdk: fix pmd device type when using netvsc or failsafe 29/15729/2
Stephen Hemminger [Mon, 5 Nov 2018 19:32:31 +0000 (11:32 -0800)]
dpdk: fix pmd device type when using netvsc or failsafe

The pmd device type show with 'show hardware' is wrong if using failsafe
(or netvsc pmd) because the pmd device type should be based of the VPP device
instance, not the DPDK port id.

Fixes: a059a000f81a ("dpdk: Decoupling the meaning of xd->device_index in dpdk_plugin")
Change-Id: I3880fe674731880c5706a21d8ef3ccf8d569d46d
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
5 years agotcp: dequeue acked only once per burst 28/15728/4
Florin Coras [Mon, 5 Nov 2018 19:06:53 +0000 (11:06 -0800)]
tcp: dequeue acked only once per burst

Avoid dequeuing acked bytes more than once per burst for a connection.
Although the fifos do not use locks, size decrements are atomic, so they
rely on locked instructions.

Change-Id: Id65f4ea40b2c10057461402dfd0393034e6472d5
Signed-off-by: Florin Coras <fcoras@cisco.com>