vpp.git
5 years agoIPSEC-GRE: fixes and API update to common types. 91/17691/14
Neale Ranns [Tue, 19 Feb 2019 15:22:46 +0000 (15:22 +0000)]
IPSEC-GRE: fixes and API update to common types.

Change-Id: Icdcbac7453baa837a9c0c4a2401dff4a6aa6cba0
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agotests: test/vpp_l2.py fix missing name. 82/18582/2
Paul Vinciguerra [Thu, 28 Mar 2019 20:07:00 +0000 (13:07 -0700)]
tests: test/vpp_l2.py fix missing name.

test/vpp_l2.py:213:26: F821 undefined name 'L2_VTR_OP'
        self.itf.set_vtr(L2_VTR_OP.L2_DISABLED)

Move L2_VTR_OP enum to vpp_sub_interface.py where the VTR code is found.

Change-Id: I9eb9a3a2c679813c221ce1d0c4fa8aac6076c443
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
5 years agovls: add pthread check on vls_attr 97/18597/3
Florin Coras [Fri, 29 Mar 2019 15:29:25 +0000 (08:29 -0700)]
vls: add pthread check on vls_attr

Change-Id: I455d108dfe52d45d040167fecb37b33e9d630c3c
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agotests: refactor vpp_object.py 78/18578/3
Paul Vinciguerra [Thu, 28 Mar 2019 16:53:44 +0000 (09:53 -0700)]
tests: refactor vpp_object.py

Move __str__ to super for all subclasses of VppObject
Implement __repr__ in VppObject
Implement __hash__ and __eq__

Change-Id: Ibd4ea37b84b17f499ab86630fb5b9ed9c8b4b1c2
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
5 years agoIntegrate first QUIC protocol implementation 78/18378/11
Nathan Skrzypczak [Tue, 19 Mar 2019 12:57:31 +0000 (13:57 +0100)]
Integrate first QUIC protocol implementation

Currently supports on single stream exposed through standard internal APIs
Based on libquicly & picotls by h2o

Change-Id: I7bc1ec0e399d1fb02bfd1da91aa7410076d08d14
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
5 years agoVOM: recurive route update fix 93/18593/2
Neale Ranns [Fri, 29 Mar 2019 12:59:01 +0000 (05:59 -0700)]
VOM: recurive route update fix

Change-Id: Iff61904804d8218c4e02897521368f696002343d
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoBVI: coverity error fix 89/18589/2
Neale Ranns [Fri, 29 Mar 2019 11:37:59 +0000 (11:37 +0000)]
BVI: coverity error fix

Change-Id: Idc1e1747035638777240b7ea9afcf675b22be7f1
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoUpdate MAINTAINERS 90/18590/1
Dave Barach [Fri, 29 Mar 2019 12:17:20 +0000 (08:17 -0400)]
Update MAINTAINERS

Change-Id: I1b041edb6f20a9f9c867fb243922985398485054
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agoipsec: esp-decrypt rework 38/18538/7
Damjan Marion [Mon, 25 Mar 2019 14:54:40 +0000 (15:54 +0100)]
ipsec: esp-decrypt rework

Change-Id: Icf83c876d0880d1872b84e0a3d34be654b76149f
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoIPSEC: tunnel fragmentation 68/18568/4
Neale Ranns [Thu, 28 Mar 2019 08:56:10 +0000 (08:56 +0000)]
IPSEC: tunnel fragmentation

Change-Id: I63741a22bc82f5f861e1c0f26a93b5569cc52061
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agotcp: remove sent rcv wnd 0 flag 87/18587/2
Florin Coras [Thu, 28 Mar 2019 23:31:52 +0000 (16:31 -0700)]
tcp: remove sent rcv wnd 0 flag

Change-Id: If6c672d1caa8884eb5d819311606a79a3de81200
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agodhcp: only register UDP ports that are needed 54/18554/3
Matthew Smith [Wed, 27 Mar 2019 17:30:29 +0000 (12:30 -0500)]
dhcp: only register UDP ports that are needed

When configuring a DHCP client, both the UDP ports for DHCP client
and server are registered. Packets to the server port end up being
dropped unless you have also configured a DHCP proxy.

This breaks a common home/office gateway use case where the WAN
interface gets configured using a DHCP client and devices attached
to a LAN interface attempt to configure themselves using DHCP. If
you try to punt to an external DHCP daemon to handle the LAN client
requests, the packets never make it to the external daemon because
of the server port being registered.

Modify dhcp_maybe_register_udp_ports() to accept a parameter that
controls which ports get registered. For a DHCP client, only the
client port is registered. For a DHCP proxy, both client and server
ports are registered.

Change-Id: I2182d9827e4c7424b03ebb94952c3d2dc37abdb6
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
5 years agotcp: improve updating of rcv wnd 81/18581/2
Florin Coras [Thu, 28 Mar 2019 20:21:19 +0000 (13:21 -0700)]
tcp: improve updating of rcv wnd

Change-Id: I0b8a311979d3ccd15f3854e7ac44ca9951dc6ce4
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agordma: add option to specify inteface name 86/18586/2
Damjan Marion [Thu, 28 Mar 2019 22:34:56 +0000 (23:34 +0100)]
rdma: add option to specify inteface name

Change-Id: Ic6244511b88bdd42756f74e3163a70b8014e8547
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agocrypto: add vnet_crypto_op_init (...) 83/18583/3
Damjan Marion [Thu, 28 Mar 2019 20:40:48 +0000 (21:40 +0100)]
crypto: add vnet_crypto_op_init (...)

Change-Id: I2018d8367bb010e1ab30d9c7c23d9501fc38a2e5
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoipsec: USE_EXTENDED_SEQ_NUM -> USE_ESN 66/18566/6
Damjan Marion [Thu, 28 Mar 2019 09:58:59 +0000 (10:58 +0100)]
ipsec: USE_EXTENDED_SEQ_NUM -> USE_ESN

Change-Id: Ib828ea5106f3ae280e4ce233f2462dee363580b7
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agocmake: add vpp_plugin_find_library macro 80/18580/2
Damjan Marion [Thu, 28 Mar 2019 19:54:47 +0000 (20:54 +0100)]
cmake: add vpp_plugin_find_library macro

Change-Id: I0b996460e05c40e74766563fb2a94c62a65063ce
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoPunt Infra 48/15148/15
Neale Ranns [Fri, 28 Sep 2018 15:16:14 +0000 (15:16 +0000)]
Punt Infra

A punt/exception path that provides:
 1) clients that use the infra
 2) clients can create punt reasons
 3) clients can register to recieve packets that are punted
    for a given reason to be sent to the desired node.
 4) nodes which punt packets fill in the {reason,protocol} of the
    buffere (in the meta-data) and send to the new node "punt-dispatch"
 5) punt-dispatch sends packets to the registered nodes or drops

Change-Id: Ia4f144337f1387cbe585b4f375d0842aefffcde5
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoipsec: anti-replay code cleanup 77/18577/3
Damjan Marion [Thu, 28 Mar 2019 18:19:31 +0000 (19:19 +0100)]
ipsec: anti-replay code cleanup

Change-Id: Ib73352d6be26d639a7f9d47ca0570a1248bff04a
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agosession: remove unused tx context field 73/18573/2
Florin Coras [Thu, 28 Mar 2019 15:34:25 +0000 (08:34 -0700)]
session: remove unused tx context field

Change-Id: I4a119937842eb188f5e5a7706cbe70e91ae4def8
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoAdd RDMA ibverb driver plugin 43/17643/11
Benoît Ganne [Mon, 25 Mar 2019 10:41:34 +0000 (11:41 +0100)]
Add RDMA ibverb driver plugin

RDMA ibverb is a userspace API to efficiently rx/tx packets. This is an
initial, unoptimized driver targeting Mellanox cards.
Next steps should include batching, multiqueue and additional cards.

Change-Id: I0309c7a543f75f2f9317eaf63ca502ac7a093ef9
Signed-off-by: Benoît Ganne <bganne@cisco.com>
5 years agosession: cap max burst to a constant 57/18557/4
Florin Coras [Thu, 28 Mar 2019 01:55:11 +0000 (18:55 -0700)]
session: cap max burst to a constant

Change-Id: I1919d3844936486f04f2bfde24dc7e0d9121927a
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoAvoid overwrite in clib_memcpy_le{32,64} 71/18571/2
Damjan Marion [Thu, 28 Mar 2019 15:19:24 +0000 (16:19 +0100)]
Avoid overwrite in clib_memcpy_le{32,64}

Change-Id: Id4a8b6a31fc3e88af2f075cb97c85d3f9b738d9e
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoVXLAN-GBP: format flags in encap trace 70/18570/2
Neale Ranns [Thu, 28 Mar 2019 15:01:47 +0000 (08:01 -0700)]
VXLAN-GBP: format flags in encap trace

Change-Id: I561fd187b4865345f3bff86b3d6e67b0f0e97557
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agotcp: remove unused buffer flags 74/18574/1
Florin Coras [Thu, 28 Mar 2019 15:39:01 +0000 (08:39 -0700)]
tcp: remove unused buffer flags

Change-Id: I86e71f32dee3cc48f680e6432a96caef0a7f66a1
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoIPSEC: 4o6 and 6o4 for tunnel interfaces 60/18560/2
Neale Ranns [Wed, 27 Mar 2019 13:40:35 +0000 (13:40 +0000)]
IPSEC: 4o6 and 6o4 for tunnel interfaces

Change-Id: I4d3ba18ab5205317219989de55b6e50d3b1d8a79
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoIPSEC: fix build breakage from ships in the night merges 61/18561/1
Neale Ranns [Thu, 28 Mar 2019 08:59:12 +0000 (08:59 +0000)]
IPSEC: fix build breakage from ships in the night merges

Change-Id: Iec7da9adc970d005cd7d3d42839b5e51b0b5f5c3
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agovat:ignore SIGWINCH signal 24/18524/4
ezkexma [Tue, 26 Mar 2019 14:24:38 +0000 (10:24 -0400)]
vat:ignore SIGWINCH signal

vpp/src/vat/main.c
When change the window size,the vat will get the SIGWINCH signal and then exit.
It is not a exit action,so we can ignore it.

Change-Id: If796762216910e23cace09406d413331f505d990
Signed-off-by: ezkexma <maqi.z.ke@ericsson.com>
5 years agoAppImage packaging 95/18495/3
Dave Barach [Sun, 24 Mar 2019 20:25:03 +0000 (16:25 -0400)]
AppImage packaging

Disabled by default. To kick the the tires:

wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage
sudo mv linuxdeploy-x86_64.AppImage /usr/local/bin/linuxdeploy
sudo chmod +x linuxdeploy-x86_64.AppImage

Enable VPP_BUILD_APPIMAGE e.g. in ccmake
make build | make build-release

The vpp AppImage lands in .../install-xxx-native/VPP-x86_64.AppImage. To run it:

./VPP-x86_64.AppImage vpp unix interactive

To run it (as root) and inhale the usual startup.conf:

sudo ./VPP-x86_64.AppImage \${HERE}/bin/vpp -c \${HERE}/etc/vpp/startup.conf

To run vppctl, or any of the usual vpp binaries:

./VPP-x86_64.AppImage vppctl [etc]

Change-Id: Ide8cf4658cbb56f1d36a1ce7fc8f7338f8d38278
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agoIPSEC: run encrpyt as a feautre on the tunnel 37/18537/3
Neale Ranns [Fri, 22 Mar 2019 08:12:48 +0000 (08:12 +0000)]
IPSEC: run encrpyt as a feautre on the tunnel

Change-Id: I6527e3fd8bbbca2d5f728621fc66b3856b39d505
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoTypos. A bunch of typos I've been collecting. 56/18556/3
Paul Vinciguerra [Wed, 27 Mar 2019 18:25:48 +0000 (11:25 -0700)]
Typos.  A bunch of typos I've been collecting.

Change-Id: I53ab8d17914e6563110354e4052109ac02bf8f3b
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
5 years agomake-test: fix ValueError raised by hook in python3 55/18555/2
Naveen Joy [Wed, 27 Mar 2019 21:28:50 +0000 (14:28 -0700)]
make-test: fix ValueError raised by hook in python3

Without this patch, the hook module raises a ValueError
when tests are run using python3. This patch updates the
exception being caught by ipaddress to ValueError.

Change-Id: I5e11e292a05ddf350fc04ebaf19cfd7dad2bd9d0
Signed-off-by: Naveen Joy <najoy@cisco.com>
5 years agoVOM: routes support multipath so set is_multipath in route update 48/18548/2
Neale Ranns [Wed, 27 Mar 2019 12:32:03 +0000 (05:32 -0700)]
VOM: routes support multipath so set is_multipath in route update

Change-Id: Ib0249aec00c8a8306f2cf25394d39b4b7850d8f7
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoGBP: fixes for l3-out routing 47/18547/3
Neale Ranns [Wed, 27 Mar 2019 12:06:47 +0000 (05:06 -0700)]
GBP: fixes for l3-out routing

Change-Id: I4d73b712da911588d511a8401b73cdc3c66346fe
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoipsec: compress ipsec_sa_t so data used by dataplane code fits in cacheline 31/18531/3
Damjan Marion [Tue, 26 Mar 2019 12:16:42 +0000 (13:16 +0100)]
ipsec: compress ipsec_sa_t so data used by dataplane code fits in cacheline

Change-Id: I81ecdf9fdcfcb017117b47dc031f93208e004d7c
Signed-off-by: Damjan Marion <damarion@cisco.com>
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agotcp: add cc algo lookup table 40/18540/2
Florin Coras [Tue, 26 Mar 2019 21:05:38 +0000 (14:05 -0700)]
tcp: add cc algo lookup table

Change-Id: Ie7be0136c182cdc35193e47dd3249153c2f8d65e
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agovom: Add support for BVI interface 18/18518/3
Mohsin Kazmi [Mon, 25 Mar 2019 15:41:01 +0000 (16:41 +0100)]
vom: Add support for BVI interface

Change-Id: Ie93f3a2107df0452f7a7436b78c337f482904899
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
5 years agoFIB: do debug before remvoing last source 35/18535/2
Neale Ranns [Tue, 26 Mar 2019 14:25:11 +0000 (07:25 -0700)]
FIB: do debug before remvoing last source

Change-Id: I4e1cde754eb4d6406cd6cd51f37d89552bdb6a53
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoGBP: missing L3-out type coversion 36/18536/2
Neale Ranns [Tue, 26 Mar 2019 15:54:32 +0000 (08:54 -0700)]
GBP: missing L3-out type coversion

Change-Id: Ic6455a930fcb21b055bcf093359bc8328f88140a
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoAdd missing OpenSUSE Leap 15.0 build deps 30/18530/2
Benoît Ganne [Tue, 26 Mar 2019 09:27:57 +0000 (10:27 +0100)]
Add missing OpenSUSE Leap 15.0 build deps

Fresh OpenSUSE Leap 15.0 containers are missing build dependencies.

Change-Id: I9b62f36c658862d8f32db5547d2176e6f56df4ea
Signed-off-by: Benoît Ganne <bganne@cisco.com>
5 years agoADJ: midchain delegate to performing stacking 26/18526/4
Neale Ranns [Tue, 26 Mar 2019 07:02:58 +0000 (07:02 +0000)]
ADJ: midchain delegate to performing stacking

this can be used by e.g. tunnels so it doesn't need to be
implemented for each tunnel type.

Change-Id: I0790f89aa49f83421612b35108cce67693285999
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoIPSEC: more expressive API errors 27/18527/3
Neale Ranns [Tue, 26 Mar 2019 08:21:25 +0000 (08:21 +0000)]
IPSEC: more expressive API errors

Change-Id: I517a7bdae03abfea58451819e7854974397d77f8
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agonode: vector must be checked with vec_header 72/18172/2
Kingwel Xie [Mon, 11 Mar 2019 07:53:48 +0000 (03:53 -0400)]
node: vector must be checked with vec_header

see register_node, node-name might be a vector

Change-Id: I883ec51c1fa9aa4da4ba6cba415a39bb6a4331e1
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
5 years agoVPP-1508: Tests: Update version of syslog_rfc5424_parser. 02/18402/2
Paul Vinciguerra [Wed, 20 Mar 2019 01:58:35 +0000 (18:58 -0700)]
VPP-1508: Tests: Update version of syslog_rfc5424_parser.

Bump to version v0.3.1.
Fixes an issue with stdlib enum imports under python3.5.

Change-Id: I7d8cb9e8ae9321beb4cb2ba052b08e776590c75d
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
5 years agocrypto: add set crypto handler CLI 19/18519/4
Filip Tehlar [Mon, 25 Mar 2019 16:04:41 +0000 (09:04 -0700)]
crypto: add set crypto handler CLI

Change-Id: I40124f8d6e529256b1ccc6eb78dda9c5119b8951
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
5 years agoperfmon: fix pmc hw indices out-dated when multiple pmc 47/18447/2
Su Wang [Thu, 21 Mar 2019 04:14:14 +0000 (00:14 -0400)]
perfmon: fix pmc hw indices out-dated when multiple pmc

When adding two or more events using a single "set pmc",
the pmc hardware indices might be out-dated due to kernel
reschdeduling the perf_event hardware counters.
E.g. set pmc cpu-cycles cache-misses

Solution:
Open and enable all the events first, then aquire the
indices from the kernel.

Change-Id: I6913a871ab169e3b2855ac6159f527a1fca343e9
Signed-off-by: Su Wang <su.z.wang@ericsson.com>
5 years agoip6-rewrite: bug fix buffer->error in dual loop 08/18408/3
Kingwel Xie [Wed, 20 Mar 2019 07:45:47 +0000 (03:45 -0400)]
ip6-rewrite: bug fix buffer->error in dual loop

error should be recorded in buffer so that
process-error-punt can handle them correctly

Per Damjan's comments, move counter to under
else clause of last error0==NONE check. Both
v4 and v6 are changed.

Change-Id: I707c7877ccb12589337155173fc4a5200b42ee93
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
5 years agoipsec: esp-encrypt rework 98/18398/18
Damjan Marion [Tue, 19 Mar 2019 14:38:40 +0000 (15:38 +0100)]
ipsec: esp-encrypt rework

Change-Id: Ibe7f806b9d600994e83c9f1be526fdb0a1ef1833
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoConvert GRE nodes to new buffer APIs and multiarch 66/17966/5
Benoît Ganne [Fri, 1 Mar 2019 13:19:55 +0000 (14:19 +0100)]
Convert GRE nodes to new buffer APIs and multiarch

Change-Id: I3b3c8333287bb704ac7b0bbc81b3dbb059e8d2ac
Signed-off-by: Benoît Ganne <bganne@cisco.com>
5 years agoSimplify adjacency rewrite code 68/17968/4
Benoît Ganne [Fri, 1 Mar 2019 13:14:10 +0000 (14:14 +0100)]
Simplify adjacency rewrite code

Using memcpy instead of complex specific copy logic. This simplify
the implementation and also improve perf slightly.
Also move adjacency data from tail to head of buffer, which improves
cache locality (header and data share the same cacheline)
Finally, fix VxLAN which used to workaround vnet_rewrite logic.

Change-Id: I770ddad9846f7ee505aa99ad417e6a61d5cbbefa
Signed-off-by: Benoît Ganne <bganne@cisco.com>
5 years agoIPSEC: improved policy delete 28/18528/1
Neale Ranns [Tue, 26 Mar 2019 08:26:39 +0000 (08:26 +0000)]
IPSEC: improved policy delete

Change-Id: Icdf51b094c34725c079d2e4acbb955744434302d
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoVCL: add TLS opt to socket_test.sh 23/18523/1
Dave Wallace [Mon, 25 Mar 2019 23:34:50 +0000 (19:34 -0400)]
VCL: add TLS opt to socket_test.sh

- add TLS transport opt to socket_test.sh
- resolve clash in vcl_test* args with
  socket_test.sh opts

Change-Id: I952d5b64942664bc3af1098f67445e0f4b93ab32
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
5 years agotls: make first segment and fifo size configurable 17/18517/2
Florin Coras [Mon, 25 Mar 2019 15:30:53 +0000 (08:30 -0700)]
tls: make first segment and fifo size configurable

Change-Id: I6169ebdd3ac2d5d77fd2e12068c8aab6d8072c03
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoIPSEC tests fnd fix or Extended Sequence Numbers 10/18510/5
Neale Ranns [Thu, 21 Mar 2019 14:34:09 +0000 (14:34 +0000)]
IPSEC tests fnd fix or Extended Sequence Numbers

Change-Id: Iad6c4b867961ec8036110a4e15a829ddb93193ed
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoUDP: Fix session registration in lookup table 01/18501/2
Aloys Augustin [Mon, 25 Mar 2019 10:29:17 +0000 (11:29 +0100)]
UDP: Fix session registration in lookup table

This fixes a bug where packets could be sent but not received when opening an UDP connection.

Change-Id: I0993dd806b277374232d551167970ab13a62dbf9
Signed-off-by: Aloys Augustin <aloaugus@cisco.com>
5 years agoadd api trace print 48/18448/5
ezkexma [Thu, 21 Mar 2019 11:38:19 +0000 (07:38 -0400)]
add api trace print

/vpp/src/vlibapi/api_shared.c
after "set api-trace debug on",api trace will be print ontime when clients send msg to vpp.

Change-Id: Ib2e504afb9e674c5cdfa6dc5c522c7af0396d687
Signed-off-by: ezkexma <maqi.z.ke@ericsson.com>
5 years agoFix unformat proto UDPC / UDP conflict 99/18499/2
Nathan Skrzypczak [Mon, 25 Mar 2019 09:20:56 +0000 (10:20 +0100)]
Fix unformat proto UDPC / UDP conflict

Change-Id: I9161959536c37f6f730650c9c0058a41af8e7001
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
5 years agovxlan-gbp: Add api custom-dump 15/18215/3
Mohsin Kazmi [Tue, 12 Mar 2019 15:40:47 +0000 (16:40 +0100)]
vxlan-gbp: Add api custom-dump

Change-Id: I1cb391c56463a770d874b2bfc8a0b7f6909ba55a
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
5 years agotcp: make default mtu configurable 86/18486/2
Florin Coras [Fri, 22 Mar 2019 22:42:18 +0000 (15:42 -0700)]
tcp: make default mtu configurable

Change-Id: I56d8d8d67d5590e24c1ddb54b0c63a2cb03798e1
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoDOC-ONLY: improve multi-arch documentation 85/18485/1
Dave Barach [Fri, 22 Mar 2019 19:49:45 +0000 (15:49 -0400)]
DOC-ONLY: improve multi-arch documentation

Document CLIB_MARCH_FN and CLIB_MARCH_FN_SELECT

Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: I661ba2af79db8205d70fa87203d40a2e31b795e4

5 years agoacl-plugin: get rid of doubly-linked list fields in hash applied ACEs 80/18480/2
Andrew Yourtchenko [Wed, 20 Mar 2019 16:47:03 +0000 (17:47 +0100)]
acl-plugin: get rid of doubly-linked list fields in hash applied ACEs

With collision match vector, the doubly-linked list is not needed anymore.

Change-Id: Iaf667ebe6ce0bdd78306bec31d3949e6acb8d401
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
5 years agoacl-plugin: tuplemerge: fix a crash during soak test with split partition 79/18479/2
Andrew Yourtchenko [Wed, 20 Mar 2019 16:44:14 +0000 (17:44 +0100)]
acl-plugin: tuplemerge: fix a crash during soak test with split partition

Reload the hash-ready ACE vector pointer during the partition split
with each iteration, since the ACL# may change.

Change-Id: I1b001e06b52ff02ef59ca1d890f8462ca99e6634
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
5 years agoacl-plugin: get rid of a separate "count" field in the linear acl struct 15/18415/2
Andrew Yourtchenko [Wed, 20 Mar 2019 10:11:19 +0000 (11:11 +0100)]
acl-plugin: get rid of a separate "count" field in the linear acl struct

Long time ago, the linear array of rules in the ACL structure was not
a vector. Now it is, so get rid of the extraneous "count" member.
Do so in a manner that would ease potential the MP-safe manipulation of
ACL rules in the future.

Change-Id: Ib9c0731e4f21723c9ec4d7f00c3e5ead8e1e97bd
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
5 years agocrypto: implement rfc4231 test cases 16/18416/3
Filip Tehlar [Wed, 20 Mar 2019 09:43:20 +0000 (02:43 -0700)]
crypto: implement rfc4231 test cases

Change-Id: I540241672a20f687d20bb70adbf2b33200f34167
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
5 years agoipv6: vectorized ext header check 83/18483/2
Damjan Marion [Fri, 22 Mar 2019 12:58:08 +0000 (13:58 +0100)]
ipv6: vectorized ext header check

Change-Id: I454bb01153d1d0536c4a6fe36103e7721aad8cd1
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoADJ: more thorough link up check 97/18297/4
Neale Ranns [Thu, 14 Mar 2019 16:21:02 +0000 (09:21 -0700)]
ADJ: more thorough link up check

Change-Id: I04dbfb914706b25fcc3bd6ee0d19cfdc810234ae
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agotcp: improve handling of snd_nxt 27/18227/15
Florin Coras [Wed, 13 Mar 2019 01:58:54 +0000 (18:58 -0700)]
tcp: improve handling of snd_nxt

- avoid changing snd_nxt when doing fast retransmits
- use snd_una_max only to keep track of the max seq number sent
- simplify future ack testing

Change-Id: I3580ad3aefe30128486c3375d0ac3f3f62c04c5e
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agosvm/atomics: add clib_atomic_swap_rel_n 73/18473/2
Florin Coras [Fri, 22 Mar 2019 04:17:43 +0000 (21:17 -0700)]
svm/atomics: add clib_atomic_swap_rel_n

Change-Id: Iea2c173000570043beafef58ca923463ce76d872
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoadd a "make test-gcov" target 81/18481/2
Dave Barach [Fri, 22 Mar 2019 12:50:29 +0000 (08:50 -0400)]
add a "make test-gcov" target

add a line to "make help"

Change-Id: I94c9e54832e959f35ee28adc1b37091c1473f687
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agoipsec: fix esn handling 58/18458/3
Damjan Marion [Wed, 20 Mar 2019 15:30:54 +0000 (16:30 +0100)]
ipsec: fix esn handling

Change-Id: I27f24095309082363ba0d0ba4bd69e2c0741dc1c
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoIPSEC: test for packet drop on sequence number wrap 61/18461/2
Neale Ranns [Thu, 21 Mar 2019 16:36:28 +0000 (16:36 +0000)]
IPSEC: test for packet drop on sequence number wrap

Change-Id: Id546c56a4904d13d4278055f3c5a5e4548e2efd0
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agodpdk: do not enable VLAN stripping on Cisco VIC adapters by default 75/18475/2
Hyong Youb Kim [Thu, 21 Mar 2019 15:33:28 +0000 (08:33 -0700)]
dpdk: do not enable VLAN stripping on Cisco VIC adapters by default

With the following local patch, VIC adapters remove default vlan tags
from ingress packets. So, it is no longer necessary to enable VLAN
stripping by default. This change also allows VLAN sub interfaces to
work with VIC adapters.

patches/dpdk_19.02/0001-net-enic-untag-default-vlan-by-default.patch

Change-Id: I2e7d62c62120c351c27d827d90de4a8335efa044
Signed-off-by: Hyong Youb Kim <hyonkim@cisco.com>
5 years agodpdk: add ENIC PMD patch to untag default vlan 74/18474/2
Hyong Youb Kim [Thu, 21 Mar 2019 15:21:26 +0000 (08:21 -0700)]
dpdk: add ENIC PMD patch to untag default vlan

The ingress vlan rewrite mode affects the vlan header of ingress
packet. The enic driver currently uses the 'passthrough' mode, which
leaves the vlan header intact. As all packets in UCS network are
tagged, this default mode leads to tagged ingress packets in the
following cases where VPP expects untagged packets.

1. Trunk-mode vNIC on UCS standalone server.
A remote device sends an untagged packet to the server. This packet is
ultimately tagged with vlan 0 as it reaches the driver, and VPP sees
an ingress packet tagged with vlan 0.

2. Access-mode vNIC on UCS blade or standalone server.
A remote device sends a packet on the vNIC's default vlan (e.g. 200)
to the server. This tag is untouched, and VPP sees an ingress packet
tagged with the default vlan (e.g. 200).

In both cases, VPP expects to see untagged packets. To work around the
issue, VPP currently enables vlan stripping on VIC interfaces, which
breaks vlan sub-interface features.

To avoid the current workaround, use the "untag default vlan" rewrite
mode. With this mode, the VIC adapter removes the vlan header if it
matches the default vlan. In the cases described above, VPP would see
untagged packets. Packets tagged with non-default vlan (e.g. non-0 for
case 1 and non-200 for case 2) are received with their tags intact, so
VPP sees tagged packets as expected.

The driver currently has no programmatic way to change the rewrite
mode after rte_eal_init. So use this patch to change the mode for the
time being.

Change-Id: Iff6408275363ed52d6016e7516d745214d6b30d4
Signed-off-by: Hyong Youb Kim <hyonkim@cisco.com>
5 years agovppapigen: allow for enum size other than u32 79/18379/3
Andrew Yourtchenko [Tue, 19 Mar 2019 13:52:29 +0000 (14:52 +0100)]
vppapigen: allow for enum size other than u32

Change-Id: If20d2fbab9b854b7db276c81918fdff6abcb8385
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
5 years agotests: update test_lb.py to use api call lb_conf. 96/18396/4
Paul Vinciguerra [Tue, 19 Mar 2019 18:54:39 +0000 (11:54 -0700)]
tests: update test_lb.py to use api call lb_conf.

Change-Id: I96a1d4b2b3ae22cf164c0acd6db9b323cd70f51a
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
5 years agoMAP: Crush Coverity Complaint 62/18462/2
Jon Loeliger [Thu, 21 Mar 2019 15:57:51 +0000 (10:57 -0500)]
MAP: Crush Coverity Complaint

Change-Id: I965229f5bf8fcde9176357536a23ba8056542919
Signed-off-by: Jon Loeliger <jdl@netgate.com>
5 years agoIgnore SIGTERM during the vpp boot sequence 69/18469/2
Dave Barach [Thu, 21 Mar 2019 22:01:48 +0000 (18:01 -0400)]
Ignore SIGTERM during the vpp boot sequence

Call setjmp and mark the setjmp context valid just prior to entering the
vpp main loop.

Change-Id: I26d5cd6a624cb2a497d81eb85a62365621b3b469
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agovec: use memset in vec_resize_allocate_memory 50/18450/2
Florin Coras [Thu, 21 Mar 2019 06:16:15 +0000 (23:16 -0700)]
vec: use memset in vec_resize_allocate_memory

Change-Id: I0ed28846060a774b1f6cdc1e4e5974a7e16f9f16
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agosession/fifo: make event unset atomic 68/18468/1
Florin Coras [Thu, 21 Mar 2019 20:54:53 +0000 (13:54 -0700)]
session/fifo: make event unset atomic

Ensures that fifo cursize loads cannot be speculated to before the event
unset.

Change-Id: Ia7c20c510d58f26a8e9b82d3982c6d4143a3a4d6
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoBVI Interface 16/18316/8
Neale Ranns [Fri, 15 Mar 2019 09:16:20 +0000 (02:16 -0700)]
BVI Interface

a new dedicated BVI interface as opposed to [re]using a loopback.

benefits:
 - removes ambiguity over the purpose of a loopback interface
 - TX node dedicated to BVI only functions.

Change-Id: I749d6b38440d450ac5b909a28053c75ec9df946a
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agodocs: break up long lines in vmxnet3.rst to avoid line wrap 99/18399/3
Steven Luong [Tue, 19 Mar 2019 21:35:29 +0000 (14:35 -0700)]
docs: break up long lines in vmxnet3.rst to avoid line wrap

Although it does not make a difference for the formatter with long lines, it
is easier to view and read the raw text with conventional editor when there no
line wrap. Just break up the long lines to 80 characters or less.

Change-Id: Ia916638e974abd19b8d19aee4dd72ff6a243ca48
Signed-off-by: Steven Luong <sluong@cisco.com>
5 years agoerror-drop; print interface by name 54/18454/2
Neale Ranns [Thu, 21 Mar 2019 10:20:15 +0000 (10:20 +0000)]
error-drop; print interface by name

Change-Id: I19736180c1e7e1d13dbb74bcd8f1dfae762b1d25
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoIPSEC: Mutli-tunnel tests 42/18442/4
Neale Ranns [Wed, 20 Mar 2019 18:24:43 +0000 (18:24 +0000)]
IPSEC: Mutli-tunnel tests

Change-Id: I46f1db6579835c6613fdbb2b726246cc62b135fe
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoapi trace: cli bug fix 10/18410/2
ezkexma [Wed, 20 Mar 2019 16:02:33 +0000 (12:02 -0400)]
api trace: cli bug fix

vpp/src/vlibmemory/vlib_api_cli.c
Fixing the help string for the "set api-trace" command.

Change-Id: I70f85a4f55466d2cc01018c4ad8cbe8332dbb925
Signed-off-by: ezkexma <maqi.z.ke@ericsson.com>
5 years agoicmp: bug fix of buffer->error 45/18445/4
Kingwel Xie [Thu, 21 Mar 2019 01:47:17 +0000 (21:47 -0400)]
icmp: bug fix of buffer->error

Recent changes in icmp4/6 choose to free the original
buffer, and make a copy for sending icmp reply back.
However, buffer->error will be ignored when the buffer
is freed unconditionally.

A quick fix can be moving the counter increment code to icmp,
but I prefert to enqueue all buffers to 'error-drop' so that
they can be handled in a batch

rebase, using vlib_buffer_enqueue_to_single_next

Change-Id: I9f3028b55f1d5f634763e2410cd91e17f368195e
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
5 years agoipsec: add ipv6 support for ipsec tunnel interface 18/18418/4
Kingwel Xie [Wed, 20 Mar 2019 11:21:58 +0000 (07:21 -0400)]
ipsec: add ipv6 support for ipsec tunnel interface

Change-Id: I6a76907dc7bed2a81282b63669bea2219d6903c9
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
5 years agovcl: mark app state as failed if attach fails 40/18440/3
Florin Coras [Wed, 20 Mar 2019 15:33:10 +0000 (08:33 -0700)]
vcl: mark app state as failed if attach fails

Change-Id: If6c3b9a9136390fb740e5c00fd270b7962a1c4ab
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agocrypto: add hmac truncate option 38/18438/3
Damjan Marion [Wed, 20 Mar 2019 15:30:54 +0000 (16:30 +0100)]
crypto: add hmac truncate option

This reverts commit 785368e559dbdf50676f74f43f13423c817abb52.

Change-Id: I782ac2be4e161790c73ccd4b08492e2188a6d79d
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agocrypto_openssl: call EVP_EncryptFinal_ex only if needed 39/18439/2
Damjan Marion [Wed, 20 Mar 2019 15:28:51 +0000 (16:28 +0100)]
crypto_openssl: call EVP_EncryptFinal_ex only if needed

Change-Id: I4dc6749a67c0726bae20b8204a5171676308b909
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoIPSEC: Tunnel SA not deleted 26/18426/2
Neale Ranns [Wed, 20 Mar 2019 14:10:23 +0000 (14:10 +0000)]
IPSEC: Tunnel SA not deleted

p is overwritten by hash_unset so an incorrect value is passed to
ipsec_sa_del

Change-Id: I97300dd4421c62d7cfa47b8e7e9789becb2370e9
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoipsec: keep crypto data inside SA 37/18437/2
Damjan Marion [Wed, 20 Mar 2019 15:07:09 +0000 (16:07 +0100)]
ipsec: keep crypto data inside SA

Change-Id: Ie8986bd3652d25c4befe681cea77df95aba37ebc
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoipsec: bug fix ipsec-init sequence 76/18376/3
Kingwel Xie [Tue, 19 Mar 2019 11:57:52 +0000 (07:57 -0400)]
ipsec: bug fix ipsec-init sequence

ipsec_tunnel_if_init might be called before ipsec_init
this memset in ipsec-init therefore zero the memory
allocated by ipsec_tunnel_if_init

Change-Id: Ie889f1bf624c76842ef77e5a51ed1d41fed4758d
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
5 years agocpu: fix rtype for fn selected by CLIB_MARCH_FN 36/18436/2
Florin Coras [Wed, 20 Mar 2019 15:11:14 +0000 (08:11 -0700)]
cpu: fix rtype for fn selected by CLIB_MARCH_FN

Change-Id: I79f65d7bd19af035442dca48b7be6c94de20c167
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agotcp: disable cc elog debugging 03/18403/4
Florin Coras [Wed, 20 Mar 2019 02:36:07 +0000 (19:36 -0700)]
tcp: disable cc elog debugging

Change-Id: Iffed748a15b9f01b985f9a6a9574a7bc42ab55aa
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoperfmon: python to C parser for intel CPUs 10/17110/7
Damjan Marion [Mon, 28 Jan 2019 12:27:31 +0000 (13:27 +0100)]
perfmon: python to C parser for intel CPUs

EXAMPLE:
src/plugins/perfmon/intel_json_to_c.py \
  -i skylakex_core_v1.12.json \
  -o src/plugins/perfmon/perfmon_intel_skx.c \
  -m 0x55,0 \
  -m 0x55,1 \
  -m 0x55,2 \
  -m 0x55,3

Change-Id: I16ce059e231d340ecfcb6f6638e29c5b46304683
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agoldp: force exit if constructor init fails 04/18404/2
Florin Coras [Wed, 20 Mar 2019 02:44:51 +0000 (19:44 -0700)]
ldp: force exit if constructor init fails

Change-Id: I0c4659b9e413cf7291ec9e3b5a67de8ad8028cd3
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoRe-enable aarch64 neon instruction in vlib_buffer_free_inline 05/18405/2
Lijian.Zhang [Tue, 12 Mar 2019 10:32:39 +0000 (18:32 +0800)]
Re-enable aarch64 neon instruction in vlib_buffer_free_inline

int vaddvq_u8 (uint8x16_t __a) is not appropriate to implement xxx_is_all_zero,
as there may be overflow causing incorrect return value.

Here's an example.
u8x16 x = {0 <repeats 12 times>, 1, 255, 0, 0};

Change-Id: Ia6a10bdf8da360dec12db902d028751a1a77e9a4
Signed-off-by: Lijian Zhang <Lijian.Zhang@arm.com>
Reviewed-by: Sirshak Das <Sirshak.Das@arm.com>
5 years agotests: implement crypto tests per RFC2202 95/18395/2
Filip Tehlar [Tue, 19 Mar 2019 17:37:06 +0000 (10:37 -0700)]
tests: implement crypto tests per RFC2202

Change-Id: I18b30d5ee8aa60c34d52b7716b5feb7225cb0d59
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
5 years agotests: cdp plugin. Replace cdp enable cli command with API call. 77/18377/2
Paul Vinciguerra [Tue, 19 Mar 2019 12:44:16 +0000 (05:44 -0700)]
tests: cdp plugin. Replace cdp enable cli command with API call.

Change-Id: Ic2d21b535a58c1c618ec9e652d30858ad45a7d43
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
5 years agovpp_papi: Expose the list of field attributes to the client. 00/18400/2
Paul Vinciguerra [Tue, 19 Mar 2019 22:04:17 +0000 (15:04 -0700)]
vpp_papi: Expose the list of field attributes to the client.

Change-Id: I7aba1760f68798fc5bea1244ce798e4b528a4df4
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>