Commit Graph

2178 Commits

Author SHA1 Message Date
b5c13fdf47 Validate ip6 interface fib tables early on
This should avoid random crashes due to reception of packets (multicast
in particular) before ip6 addresses are configured on the interfaces.

Change-Id: Ibcf1a5a2ae2fa75f8b57da1b2f09f32c081210d7
Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-11 15:10:30 +00:00
6a5be214b9 dpdk: bump to dpdk 17.05
Change-Id: I19744387859129c6b8dc104041af158bf5f1d988
Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-11 14:28:05 +00:00
11c0549fee Handle RST of TCP connections in SYN-RCVD state, VPP-822
Change-Id: Ieb0c1e690d6ae082cfedb276252a31fab480e561
Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-11 13:28:08 +00:00
cd6cb986ed make test: support coverage for out-of-tree plugins
Change-Id: Ibd7828b1e1c699630ff450122d8aa317b1c9da26
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-05-11 06:55:32 +02:00
460ba3d859 Allow to override the build date
using the SOURCE_DATE_EPOCH env var
to make vpp package builds reproducible.

See https://reproducible-builds.org/ for why this is good
and https://reproducible-builds.org/specs/source-date-epoch/
for the definition of this variable.

Change-Id: Iae0935c9bb4ccdfdb65600be543945a88f2e137f
Signed-off-by: Bernhard M. Wiedemann <bwiedemann@suse.de>
2017-05-10 22:08:53 +00:00
abce509aff vnet: introduce error state for sw interfaces
Interfaces with error state are not allowed to go admin up

Change-Id: I09fc09a5b28130aead219dccbc2e0f30ea7414cf
Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-10 22:02:22 +00:00
f55f9b851f completelly deprecate os_get_cpu_number, replace new occurences
Change-Id: I82c663bc0866c6c68ba354104b0bb059387f4b9d
Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-10 22:01:15 +00:00
e5f1d27695 Multi-thread enablement for the debug cli http server
Change-Id: Iec1f739fe24c722d0db6c10cc81b5e8333067ea1
Signed-off-by: Dave Barach <dbarach@cisco.com>
2017-05-10 20:41:04 +00:00
3335693cc1 doxygen: Fix some paths
- Add missing src dir.
- Exclude 'src/examples' from siphon processing so that example cli commands
  don't end up in user documentation.

Change-Id: I46a6ad759fa8220d305b007a9506956365fc79bd
Signed-off-by: Chris Luke <chrisy@flirble.org>
2017-05-10 17:46:49 +00:00
c83c8ed1db L2BD/TEST:fix l2bd multiinstance test
Change-Id: If864182ec656cc6c6353be642e22910a4fc89870
Signed-off-by: Eyal Bari <ebari@cisco.com>
2017-05-10 17:06:44 +00:00
0f68c79a9d Add crc32c inline function, allows compilation on 32-bit systems
32-bit code still can use crc32c instructions, but it operates
on 32 registers

Change-Id: I9bb6b0b59635d6ea6a753584676ebcf59c8f6584
Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-10 16:47:10 +00:00
4fb27eed7e dpdk: refactor interface speed detection
- Adds VirtualFucntionEthernet for VFs
- Enables MLX4 driver

Change-Id: I163300e68edbe033227f641bdfcfe5918cbe58cf
Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-10 16:17:49 +00:00
df82ec8fe7 Make reproducible build possible
For downstream consumption is important to have a way to specify the date or
the user or the hostname to particular values so to have reproducible builds
and/or packages.

Change-Id: I134288662b6cfbbe26bba7d8bc6be8511b34360c
Signed-off-by: Marco Varlese <marco.varlese@suse.com>
2017-05-10 15:53:39 +00:00
e3a395c840 device: Add callback for set interface rx-mode
- When the interface rx-mode is changed via CLI, the corresponding device
may want to know about it and to reset the driver. This patch is to add
the callback.

- In the function vnet_hw_interface_set_rx_mode, it appears it is missing
a line
  hw->rx_mode_by_queue[queue_id] = mode

because the function is checking if the new mode is the same as
hw->rx_mode_by_queue which is initialized to POLLING. So if the function is
called to change the mode to interrupt, it just returns without doing
anything. This is the check that I am talking about in the same function.

  if (hw->rx_mode_by_queue[queue_id] == mode)
    return 0;

Change-Id: Iaca2651c43e0ae3fda6fd8dc128e247b0851cc65
Signed-off-by: Steven <sluong@cisco.com>
2017-05-10 15:49:27 +00:00
cfe0fc95f2 SNAT: move API code to separate file
Move API source code from snat.c to snat_api.c

Change-Id: I1c4439eb5d2e3f43695ecc4d300eccd148105c15
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2017-05-10 07:05:04 -07:00
bde55230fd vppinfra: optimize and simplify splat inline functions
Example for u32x4 case:
Old code generates 2 instructions:

vmovd  %edi,%xmm0
vpunpckldq %xmm0,%xmm0,%xmm0
vpunpcklqdq %xmm0,%xmm0,%xmm0

New code uses only one instruction:
mov    %edi,-0x4(%rsp)
vbroadcastss -0x4(%rsp),%xmm0

Change-Id: I989dc3025f5fe3f6c880972389ded11f31e2f3f6
Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-10 14:03:08 +00:00
db84e579ef Improve TCP option handling, VPP-757
Change-Id: Ica634536387d1196366ec96c52770287fcab0768
Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-10 14:02:51 +00:00
1015a1ef13 Builtin debug cli http server
Visit http://<vpp-ip>/show/interface or similar.

Change-Id: I076b4661cf19d1b94bb01efdadb5849446be915e
Signed-off-by: Dave Barach <dave@barachs.net>
2017-05-10 13:03:07 +00:00
dc629cd95f Ignore data in RST segments, VPP-723
Change-Id: I01650b3b10b79ec549be0d5eceb0e318c06fcb50
Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-10 12:44:08 +00:00
4aa586fb94 Produce vpp_papi*.egg for virtual environments
Produce vpp_papi*.egg so that virtual environments (e.g. virtualenv)
could install vpp_papi inside them.

Change-Id: I9664d119a64f4968de44a7a430aec4879ed02b16
Signed-off-by: Igor Mikhailov (imichail) <imichail@cisco.com>
2017-05-10 10:45:04 +00:00
ee29dd2811 Generate test paths for lib and lib64 subdirectories
wildcard produces empty paths when 'make test' is run
from a clean tree: install-<tag>-native directories
don't exist yet.

Change-Id: I3b3bbd86cf7eda18f2c698f85b834f82b1a19065
Signed-off-by: Igor Mikhailov (imichail) <imichail@cisco.com>
2017-05-09 23:27:14 -07:00
e6c5941b98 dpdk: refactor setup, start, stop code
Change-Id: I0fec86914ec027383ff511b7092beac2363f55f7
Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-09 17:52:57 +00:00
7bee80c823 Fix remaining 32-bit compile issues
Change-Id: I9664214652229b663c3e3ba7406b4ede96bfb123
Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-09 17:52:43 +00:00
b0972cbb35 API support for IPsec tunnel interface creation
Change-Id: I8c9f886cb95e92adbe1c646844789ca0a6bb6140
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2017-05-09 16:02:59 +00:00
229a6b7a3c Add missing format_ip6_address() functions to plugin_api.
Specifically, the ACL plugin needed format_ip6_address()
and the ip46 variant as well.

Change-Id: Iec35b8acd4cab4bcbc73053dcca2ee91bd9c72cd
Signed-off-by: Jon Loeliger <jdl@netgate.com>
2017-05-09 15:25:42 +00:00
f6d68ed2db Add support for tcp/session buffer chains
Change-Id: I01c6e3dc3a1b2785df37bb66b19c4b5cbb8f3211
Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-09 14:38:56 +00:00
1ea82dfe5d dpdk: use speed_capa to detect i40e device speed
Change-Id: I1decca6fb5ce6de74ccbcd5a262ebd3db6f55cdc
Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-08 20:29:40 +00:00
3c785e09a0 vlib: do not unbind devices already bound to vfio-pci
Change-Id: I739bed5b9d9504d18ee88206e29ebc4ba1b47d28
Signed-off-by: Damjan Marion <damarion@cisco.com>
2017-05-08 18:37:54 +02:00
7537e717d1 L2FIB:CLI/API to flush all non-static entries
added CLI l2fib flush-mac all
added API l2fib_flush_all
flushes all non static l2fib entries on all valid BDs

Change-Id: Ic963c88f4bed56308c03ab43106033132a0e87be
Signed-off-by: Eyal Bari <ebari@cisco.com>
2017-05-08 12:33:17 +00:00
57d7dbc8bf Avoid active connection prevent timeout of idle conns after it
Fix a logic error related to timing out of the connections
following the active one. To avoid this class of issue in
the future, create corresponding testcases, as well as some
trivial sanity testcases for both IPv4 and IPv6.

Since these tests are timing-dependent and take up time,
mark them as extended tests.

Change-Id: I2c72bad5efda7db8aa9cb05801fe47928dc47927
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
2017-05-07 14:31:07 +00:00
9e79be2b20 Remove L2 GPE interface from bridge when deleting, VPP-833
Change-Id: I32725006e9235a02cada5b0ad8974bfc4274339f
Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-07 14:29:29 +00:00
c8343412ee Include TCP options in segment size computation
Ensure that TCP data plus options does not exceed peer's advertised MSS.

Change-Id: I0de824cb3619346f0394dd694942fc1cf33a82b7
Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-07 12:38:39 +00:00
3af90fceb6 Fix TCP loss recovery, VPP-745
Allows pure loss recovery retransmits only on timeout.

Change-Id: I563cdbf9e7b890a6569350bdbda4f746ace0544e
Signed-off-by: Florin Coras <fcoras@cisco.com>
2017-05-07 12:38:12 +00:00
1989bce006 lcov is an EPEL rpm (at least for Centos)
Change-Id: I064a78df6a2cf734bb7c54f80682690c203a0a98
Signed-off-by: Igor Mikhailov (imichail) <imichail@cisco.com>
2017-05-06 01:46:42 +00:00
9e3e361eb1 Fix mac check issue for vitual tunnel interface with no mac address
Change-Id: I6ce21317fcaa25781199f4329be815f076ab8b09
Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2017-05-06 01:30:07 +00:00
d48c8eb735 Fix L2FIB learn counter and memory cleanup of mac_by_ip6 hash table
Fix global_learn_count to be incremented or decremented by add and
deletion of non-static MAC entries from L2FIB only. Without this fix,
the counter may reach the threshold of 1M and stop MAC leanring even
though number of MAC entries in L2FIB is less than the threshold.

Cleanup indirect hash key memory used by mac_by_ip6 hash table on
BD deletion.

Change-Id: I13986c4e6304c7956122520dd3f83d6bb6e65a15
Signed-off-by: John Lo <loj@cisco.com>
2017-05-05 19:27:53 +00:00
b1291e259c ip6_to_ip4.h coverity fix
Change-Id: Ia11fa42d1f2b21a6195e7dc890f958830f83d3a7
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2017-05-05 04:57:16 -07:00
406eb1df44 SNAT: Additional tests for SNAT interfaces without a configured ip address
Change-Id: I7edea5d7b105ba66e0e04d509968b92cfb64c84a
Signed-off-by: Martin Gálik <magalik@cisco.com>
2017-05-05 11:43:17 +00:00
5d73eecd63 First commit SR MPLS
Change-Id: I961685a2a0e4c314049444c64eb6ccf877c278dd
Signed-off-by: Pablo Camarillo <pcamaril@cisco.com>
2017-05-05 11:38:39 +00:00
a774b53623 NAT64: Move IPv6-IPv4 virtual reassembly code from MAP-T to common library (VPP-708)
Change-Id: I9ad636f80bf109ffac9ca1b6d80d5f2c31f2076a
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2017-05-05 09:04:44 +00:00
da7567c022 Fixes and improvements in session hashtable keys
Fix in v6 keys :
* The copy of the keys was only partial

A few suggestions are applied in this commit :
* Since there are not so many unused fields, we avoid to memset 0 and prefer
  setting the unused fields to 0.
* By using a cast, it seems painless to avoid allocating a structure for the
  keys creation.

Change-Id: Iaee6f036f2a979cceaeb297d98ce6c307a5ac029
Signed-off-by: Clement Durand <clement.durand@polytechnique.edu>
2017-05-04 15:43:06 +00:00
68c74fc71b Fix coverity issue
Change-Id: I8110b2a1d7bf8a818c7e9b6f95c3f60324e8ccab
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2017-05-04 14:52:42 +02:00
cf121c8313 LISP: group mapping records in map-register message
Change-Id: I546c761acfbf880717163a035aa691b04337b7bf
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2017-05-04 07:26:08 +00:00
342089672d Fix RPM_DEPENDS for all rpm distros after 28ea251
Change-Id: I58ffdf75f361ff830c2b0c6400ccd012a4d16d3d
Signed-off-by: Igor Mikhailov (imichail) <imichail@cisco.com>
2017-05-04 01:19:15 +00:00
816f437d94 Fix vnet unit tests
Change-Id: Ibe55e4399c6b78d83268d7c49ed498cab7bfdb43
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2017-05-03 15:19:23 +00:00
afc47aa36f L2FIB:flush interface learned macs on down
Change-Id: I80a723f55fcf2ecc3209a35e8297c88b45b1abfb
Signed-off-by: Eyal Bari <ebari@cisco.com>
2017-05-03 13:48:11 +00:00
e72be39cd0 A sprinkling of const in vlibmemory/api.h and friends
Change-Id: I953ebb37eeec7de0c4a6b00258c3c67a83cbc020
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-03 12:35:05 +00:00
9e355523f3 change ip4_drop_node node register coding format
Change-Id: Id4fdf2abf3bae3b14cdc6489ca16d2007da78d07
Signed-off-by: flyingeagle23 <wang.hui56@zte.com.cn>
2017-05-03 11:29:53 +08:00
1c7d485836 Prevent Bridge Domain operations on BD 0.
The default bridge domain, 0, is created automatically
with static features.  It should be modified by neither
the CLI nor the API.  So add tests for, and reject any
operation on BD 0.  The new API error message BD_NOT_MODIFIABLE
is returned in such cases.

Change-Id: Iaf3dd80c4f43cf41689ca55756a0a3525420cd12
Signed-off-by: Jon Loeliger <jdl@netgate.com>
2017-05-02 23:26:33 +00:00
41da54f501 Use per-protocol default flow-hash config when the FIB table index is not known
Change-Id: If088e75801831befc6bddb77ea20abe9288b93c4
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-05-02 21:53:54 +00:00