Eyal Bari [Thu, 31 May 2018 08:30:16 +0000 (11:30 +0300)]
flow:add enabled hw format function
Change-Id: Ide1f76e9207b6022d5258a119f8d59cca85651b5
Signed-off-by: Eyal Bari <ebari@cisco.com>
Florin Coras [Fri, 1 Jun 2018 19:22:23 +0000 (12:22 -0700)]
ip: save fib index for buffer in ip lookup
Avoids recomputing the fib index in ip local for locally delivered
packets and should incur no extra cost when forwarding packets.
Change-Id: Id826ffa8206392087327f154337eabc8a801b4d7
Signed-off-by: Florin Coras <fcoras@cisco.com>
Jerome Tollet [Mon, 4 Jun 2018 07:31:33 +0000 (08:31 +0100)]
fix usage string missing arg
Change-Id: I9710e9ed6ceff6c0b2de0bcf77f355762df88b58
Signed-off-by: Jerome Tollet <jtollet@cisco.com>
Neale Ranns [Mon, 4 Jun 2018 04:21:19 +0000 (21:21 -0700)]
Join the VAC read timeout thread
Change-Id: I5bcbae276f8ac23718c5afc859da222508d07ad7
Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
Signed-off-by: Ole Troan <ot@cisco.com>
Neale Ranns [Fri, 1 Jun 2018 04:03:17 +0000 (00:03 -0400)]
Enable Position Independent Executable for production VPP
Change-Id: I0f81423b854be1dc456df696416e5f3747393208
Signed-off-by: Neale Ranns <nranns@cisco.com>
Damjan Marion [Sun, 3 Jun 2018 12:29:42 +0000 (14:29 +0200)]
dpdk: buffer free optimizations
~5 clocks/packet improvement...
Change-Id: I1a78fa24dcd1b3ab7f45e10b9ded50f79517114a
Signed-off-by: Damjan Marion <damarion@cisco.com>
Damjan Marion [Sat, 2 Jun 2018 18:42:07 +0000 (20:42 +0200)]
dpdk: improve buffer alloc perfomance
This is ~50% improvement in buffer alloc performance.
For a 256 buffer allocation, it was ~10 clocks/buffer, now is < 5 clocks.
Change-Id: I97590e240a79a42bcab5eb26587fc2d11e6eb163
Signed-off-by: Damjan Marion <damarion@cisco.com>
Neale Ranns [Fri, 1 Jun 2018 04:23:37 +0000 (21:23 -0700)]
Interface Tag: memset field in VOM, clear the tag in VPP on interface delete
Change-Id: Id97de732b5952d5d86202e7749c9e81cf8dbed87
Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
Damjan Marion [Wed, 30 May 2018 10:49:32 +0000 (12:49 +0200)]
AVF input node rework
Change-Id: Ib121b24935d5c706cfba6e4b6d321086a38cad91
Signed-off-by: Damjan Marion <damarion@cisco.com>
Andrew Yourtchenko [Wed, 30 May 2018 20:29:29 +0000 (22:29 +0200)]
acl-plugin: multicore: session management fixes
- implement a 1us purgatory for the session structures
by adding a special connection list, where all connections
about to be deleted go.
- add per-list-head timeouts updated upon the list enqueue/dequeue
for connection idle management
- add a "unused" session list with list ID#0, which should
never be used unless there is a logic error. Use this ID
to initialize the sessions.
- improve the maintainability of the session linked list
structures by using symbolic bogus index name instead of ~0
- change the ordering of session creations - first reverse, then
local. To minimize the potential for two workers competing for
the same session in the corner case of the two packets
on different workers creating the same logical session
- reduce the maximum session count to keep the memory usage the same
- add extra log/debug/trace to session cleaning logic
- be more aggressive with cleaning up sessions - wind up the
interrupts from the workers to themselves if there is more
work to do
Change-Id: I3aa1c91a925a08e83793467cb15bda178c21e426
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Florin Coras [Fri, 1 Jun 2018 00:14:10 +0000 (17:14 -0700)]
session: improve disconnect handling
If the caller is the session owning thread or the main thread with a
worker barrier sync (cli/api) add an event to the pending disconnects
vector in the session node and entirely avoid using the event queue.
Useful for bursts of disconnects (like an app detach).
If disconnects come from a processes, be willing to retry enqueueing the
disconnect to the event queue multiple times.
Change-Id: Ieece1f1091b713f94c41c703b6e805bc8498816a
Signed-off-by: Florin Coras <fcoras@cisco.com>
John Lo [Thu, 31 May 2018 14:25:18 +0000 (10:25 -0400)]
Improve L2FIB delete entry handling and "show l2fib" CLI options
Improve deletion of L2FIB MAC entry using l2fib_add_del API. If
sw_if_index param specified in th API is non-zero, check that its
value match that of the MAC entry to proceed with deletion.
Improve "show l2fib" CLI to allow display of all entries, learned
entries only, or added ovia CLI/API entries only. For added entry,
show "no" under the age column to indicate entry does not age.
Change-Id: I0bd2582c2b6bac268e551e4f8ca6dab2be4400ad
Signed-off-by: John Lo <loj@cisco.com>
Rui Cai [Fri, 11 May 2018 22:55:33 +0000 (22:55 +0000)]
dpdk: Decoupling the meaning of xd->device_index in dpdk_plugin
Prior to the change, dpdk plugin assumes xd->device_index is
used both as index for internal dpdk_main->devices array
and DPDK port index to call into DPDK APIs.
However, when running on top of Failsafe PMDs,
DPDK port index range may no longer be contiguous (as noted:
http://dpdk.org/ml/archives/dev/2018-March/092375.html
for related changes in DPDK). Because this, dpdk plugin can
no longer iterate through all available DPDK ports
with a for 0->rte_eth_dev_count() loop and the assumption of
device_index no longer holds.
This is part of initial effort to enable vpp running over
dpdk on failsafe PMD in Microsoft Azure(3/4).
Change-Id: I416fd80f2d40e12e139f8f3492814da98343eae7
Signed-off-by: Rui Cai <rucai@microsoft.com>
Ping Yu [Thu, 31 May 2018 18:01:04 +0000 (14:01 -0400)]
Fix TLS issue to load certification and key
Change-Id: If1ef2d4bc6f90a4d4b6a345c63723117834c6504
Signed-off-by: Ping Yu <ping.yu@intel.com>
qchang [Wed, 30 May 2018 18:44:18 +0000 (11:44 -0700)]
fix socket send() return size check
Change-Id: I098c671607c75cb34d04f421b4d16b73f7b47392
Signed-off-by: qchang <qing.chang1@huawei.com>
Zhiyong Yang [Thu, 31 May 2018 02:12:57 +0000 (22:12 -0400)]
fix missing void pointer explicit type cast
Change-Id: I5098e5d966abc44db045783883424b63083f08ee
Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
Ole Troan [Wed, 30 May 2018 20:43:25 +0000 (22:43 +0200)]
VPP-1299: Reset uid/gid on shared memory segment if client starts first.
Change-Id: I2b5bc7d864f8829e1dff63fec3c9484078601309
Signed-off-by: Ole Troan <ot@cisco.com>
Damjan Marion [Wed, 30 May 2018 07:55:05 +0000 (09:55 +0200)]
Add src/vlib/config.h.in template
Change-Id: I9b81dcb9250cab09b88f161366da9475a7ee5dd6
Signed-off-by: Damjan Marion <damarion@cisco.com>
Sirshak Das [Wed, 30 May 2018 02:21:02 +0000 (21:21 -0500)]
Fix clang compilation on aarch64: value size does not match register size.
Fixes clang error: value size does not match register size specified
by the constraint and modifier
Change-Id: I83e69445eacd6570607334e086a8582addb5bdfc
Signed-off-by: Sirshak Das <sirshak.das@arm.com>
Reviewed-by: Brian Brooks <brian.brooks@arm.com>
Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Klement Sekera [Wed, 30 May 2018 08:32:21 +0000 (10:32 +0200)]
make test: VPP-1288 fix bogus sw_if_index values
Change-Id: I9a61538f4c832f09269c6ddfcd55f909003b8694
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Damjan Marion [Wed, 30 May 2018 07:26:11 +0000 (09:26 +0200)]
vppinfra: explicitely state for signed types that they are signed
This fixes some compilation warnings with clang on AArch64.
Change-Id: Idb941944e3f199f483c80e143a9e5163a031c4aa
Signed-off-by: Damjan Marion <damarion@cisco.com>
Damjan Marion [Wed, 30 May 2018 09:14:10 +0000 (11:14 +0200)]
dpdk: rename port_id to *_instance_num
port_id be used for dpdk port_id
Change-Id: Ia7d8cdc5dec2ad658c11f9c0f3ef8005a470ac3c
Signed-off-by: Damjan Marion <damarion@cisco.com>
Sirshak Das [Wed, 30 May 2018 02:13:21 +0000 (21:13 -0500)]
Fix clang compilation on aarch64: sizeof operator error.
Fixes clang error: argument to 'sizeof' in 'memcpy' call is the same
pointer type 'unformat_input_t *' (aka 'struct _unformat_input_t *')
as the source; expected 'unformat_input_t' (aka 'struct
_unformat_input_t') or an explicit length.
Change-Id: If00303343b10fe1732e477549727a41445edf410
Signed-off-by: Sirshak Das <sirshak.das@arm.com>
Reviewed-by: Brian Brooks <brian.brooks@arm.com>
Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Sirshak Das [Wed, 30 May 2018 02:06:28 +0000 (21:06 -0500)]
Fix clang compilation on aarch64: replace -pie with -fPIE for dpdk compilation.
Fixes clang error: argument unused during compilation: '-pie'
by replacing it with -fPIE
Change-Id: Ic89a5e325e019d4d794d35556a07ebcf0b718dd3
Signed-off-by: Sirshak Das <sirshak.das@arm.com>
Reviewed-by: Brian Brooks <brian.brooks@arm.com>
Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Neale Ranns [Wed, 30 May 2018 06:08:32 +0000 (02:08 -0400)]
IPv6 for-us/receive multicast routes fix
Change-Id: I5e29e16b4d45411b1a7c177b8d7156c5baefe6a1
Signed-off-by: Neale Ranns <nranns@cisco.com>
Florin Coras [Wed, 30 May 2018 04:15:38 +0000 (21:15 -0700)]
session: fix v6 unbinds that use uri api
This api only supports default tables but v6 and v4 default tables are
different.
Change-Id: I7fe39251af99082278e84d7411511bdeca34e609
Signed-off-by: Florin Coras <fcoras@cisco.com>
Florin Coras [Tue, 29 May 2018 08:03:16 +0000 (01:03 -0700)]
session: fix session table retrieval
Change-Id: If37d644a26132c42a04927f612eec5e891066451
Signed-off-by: Florin Coras <fcoras@cisco.com>
Damjan Marion [Tue, 29 May 2018 22:03:34 +0000 (00:03 +0200)]
bonding: fix packet trace in bond-input
Change-Id: I00fc4a4553dabed7ef099227b8253ed4916ea5e4
Signed-off-by: Damjan Marion <damarion@cisco.com>
Damjan Marion [Tue, 29 May 2018 20:46:50 +0000 (22:46 +0200)]
Revert "dpdk: set dmamap iova address value according to eal_iova_mode"
This breaks VFIO operation.
This reverts commit
d3b3baa4f8e9e4d95264aff16fe85434ef8061bd.
Change-Id: I2482e0da2d1ebfc365d13668c4b992b040f561b4
Signed-off-by: Damjan Marion <damarion@cisco.com>
Damjan Marion [Mon, 28 May 2018 19:26:47 +0000 (21:26 +0200)]
Add VLIB_NODE_FN() macro to simplify multiversioning of node functions
Change-Id: Ibab5e27277f618ceb2d543b9d6a1a5f191e7d1db
Signed-off-by: Damjan Marion <damarion@cisco.com>
Mohsin Kazmi [Mon, 28 May 2018 16:55:37 +0000 (18:55 +0200)]
af_packet: Add support for dump interfaces
Change-Id: I8d8ecc80edb7665125ba625a3ce7b30d2dea88f0
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
chuhong yao [Tue, 29 May 2018 09:50:58 +0000 (17:50 +0800)]
fix Check style err
Change-Id: Ic7fd4d0f154a311d09409be2a6603e8460099efe
Signed-off-by: chuhong yao <ych@panath.cn>
chuhong yao [Tue, 29 May 2018 08:31:48 +0000 (16:31 +0800)]
dpdk: Add PMD type for Cavium LiquidIO II CN23XX
1、Adding PMD type for support Cavium LiquidIO II CN23XX NIC;
2、Our company is using VPP + DPDK +Cavium LiquidIO II CN23XX NIC,
Unfortunately, the latest VPP code does not support
Cavium LiquidIO II CN23XX pci.
So I increased the PMD type to support LiquidIO NIC,
and can run normally, we most subsequent projects are
based on VPP + DPDK + Cavium LiquidIO II CN23XX NIC model,
so I hope VPP team can adopt this requirement, thanks a lot.
Change-Id: I604ae444d69b37c2e26962bfe4ccdfe983b75041
Signed-off-by: chuhong yao <ych@panath.cn>
Yoann Desmouceaux [Tue, 29 May 2018 11:38:44 +0000 (13:38 +0200)]
Fixed vlib_buffer_clone with stale chained buffers
When calling vlib_buffer_clone() on a source vlib_buffer with no next
buffer but whose total_length_not_including_first_buffer hadn't been
properly zeroed out, the total_length_not_including_first_buffer of
the clone was set to a wrong value.
(see https://lists.fd.io/g/vpp-dev/topic/
19869395)
Change-Id: I4b503ece804e3933bb259be4c2148f84dafbea3e
Signed-off-by: Yoann Desmouceaux <ydesmouc@cisco.com>
Sachin Saxena [Mon, 28 May 2018 09:15:34 +0000 (14:45 +0530)]
dpdk: mempool priv intialization must be done before releasing buffers to pool
- Currently mempool priv size is getting initialized after releasing buffers
to pool. This is causing mismatch in expected & real metadata size value
and buffers are getting released with wrong offset. (when metadata offset
is in use for a given platform)
- Since private data size is 0 initially, metadata size don't include space
for VLIB_BUFFER_HDR.
Change-Id: I780c4d518104631a3dcf192185bacf58b3598e65
Signed-off-by: Sachin Saxena <sachin.saxena@nxp.com>
Radu Nicolau [Tue, 29 May 2018 10:42:33 +0000 (11:42 +0100)]
ipsec: fix IKEv2 crash when rsa cert is used for authentication
Cause: EVP_MD_CTX object used but not initialized.
Change-Id: I390b2acf580f16415685563fa52e56717efc7be7
Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Matus Fabian [Mon, 28 May 2018 11:09:52 +0000 (04:09 -0700)]
NAT44: code cleanup and refactor (VPP-1285)
Change-Id: I088163f10ae5515d7a9115781cc13ef563fafed5
Signed-off-by: Matus Fabian <matfabia@cisco.com>
Damjan Marion [Mon, 28 May 2018 14:22:14 +0000 (16:22 +0200)]
Change optimizaton level from tree-vectorize to O3
Change-Id: Ia1b49d7fd5f32d9a5139df5df636b46264003a63
Signed-off-by: Damjan Marion <damarion@cisco.com>
Andrey "Zed" Zaikin [Fri, 25 May 2018 15:09:58 +0000 (18:09 +0300)]
add missing lb_put_writer_lock() to lb_vip_add() invalid args cases
Change-Id: I9343672c5765a5a4cb56c99fa5de176ddcac62c7
Signed-off-by: Andrey "Zed" Zaikin <zed.0xff@gmail.com>
Pierre Pfister [Mon, 28 May 2018 11:56:04 +0000 (13:56 +0200)]
Fix flowhash size computation for very large hash tables
Change-Id: Ieae4ff6429fc5bdcf0e243db40ab7ec00c30730a
Signed-off-by: Pierre Pfister <ppfister@cisco.com>
Andrew Yourtchenko [Sat, 26 May 2018 18:43:00 +0000 (20:43 +0200)]
acl-plugin: move to per-frame buffer pointer calculations and enqueue to next nodes
Use the new frame-at-once functions vlib_get_buffers() and vlib_buffer_enqueue_to_next()
to calculate the buffer pointers and to dispatch the packets after the processing.
This simplifies the dataplane node processing loop.
Change-Id: I454308f847aac76a199f8dd7490c1e176414bde7
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Sachin Saxena [Mon, 28 May 2018 04:15:12 +0000 (09:45 +0530)]
VPP-1284: Fix for TLS corruption on ARM platforms
- The issue is appearing on ARM platofrms where DPDK drivers are also using
__thread TLS vairables.
- The issue was only appearing with dpdk as plgin to VPP and not if used
as statically link with VPP.
- Using traditional TLS scheme resolved the issue.
Change-Id: Ifb4c667fdd217c2b1d79be8a541a2c983222d95a
Signed-off-by: Sachin Saxena <sachin.saxena@nxp.com>
Sachin Saxena [Mon, 28 May 2018 09:24:47 +0000 (14:54 +0530)]
dpdk: set dmamap iova address value according to eal_iova_mode
- Fix the issue where eal iova mode is Virtual Address (RTE_IOVA_VA) but
setting DMA iova address to Physical address value always.
Change-Id: Ib1e9c1596d95885c7eff11723338121627203e61
Signed-off-by: Sachin Saxena <sachin.saxena@nxp.com>
Mohsin Kazmi [Thu, 17 May 2018 13:42:27 +0000 (15:42 +0200)]
af-packet: Add support for logging
Change-Id: I4cc6a20b69cce2aa52768a27c5d455eb098224c8
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Mohsin Kazmi [Wed, 25 Apr 2018 13:58:05 +0000 (15:58 +0200)]
itf: Fix admin up down for AF_PACKET and vhost-user
Change-Id: I84327197d59c72d0d046dd2cb4071bf74af6fc28
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
John Lo [Tue, 22 May 2018 07:35:06 +0000 (03:35 -0400)]
Fix IP neighbor/arp pool full and static entry handling
Move handling of IP neighbor pool full into main thread on entry
creation and make sure static entriesare not deleted for reuse.
Fix IPv6 neighbor handling on interface down and up so that static
entries are not deleted.
Change-Id: I073794949a41a5b86201e519ebe479febfc506c8
Signed-off-by: John Lo <loj@cisco.com>
Marek Gradzki [Fri, 25 May 2018 13:50:05 +0000 (15:50 +0200)]
proxy_arp: remove unused is_add
Change-Id: I1773d962b373693a737d39c0c97e8c53eb91545a
Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
Damjan Marion [Sat, 26 May 2018 16:53:34 +0000 (18:53 +0200)]
ip4-input node rework
Gain is around 6 clocks per packet (22 to 16).
Change-Id: Ia6f4293ea9062368a9a6b235c650591dbc0707d0
Signed-off-by: Damjan Marion <damarion@cisco.com>
Sirshak Das [Fri, 18 May 2018 18:14:52 +0000 (13:14 -0500)]
Fixes make test errors with clang compiler on aarch64
(VAPI_*BIN).d targets didnt have fake.api.vapi.h* as dependencies
this causes the compilation to proceed before the python script
generates the header files.
Explicit linking of stdc++ is required for clang as errors like
undefined reference to 'new operator' pop up.
Change-Id: I3ca0ef048f392c4a032160ce0e4f7ae759f4c79d
Signed-off-by: Sirshak Das <sirshak.das@arm.com>
Reviewed-by: Brian Brooks <brian.brooks@arm.com>
Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Damjan Marion [Fri, 25 May 2018 22:50:39 +0000 (00:50 +0200)]
bond-input performance optimization
Old code ~25 clocks/packet, new ~10.
Change-Id: I202cd6cbafb1ab2296939634d674f7ffd28253fc
Signed-off-by: Damjan Marion <damarion@cisco.com>
Andrew Yourtchenko [Sat, 26 May 2018 17:02:34 +0000 (19:02 +0200)]
acl-plugin: use clib_bihash_search_inline_2_40_8 rather than clib_bihash_search_40_8 for session lookups
Use inline version rather than calling the function, this gives slightly better performance.
The straighforward diff uncovered an interesting problem: the stateful ACL IPv4 unit tests would fail
for the "make test" but succeed in "make test-debug". Also, they would succeed even in "make test",
if before calling the clib_bihash_search_inline_2_40_8 we would change the code
to store the key in a temporary variable.
Debugging revealed that the generated optimized code is not what one would expect:
the zeroing of the u64s overlaying the memcpy into ipv4 value of ip46_address_t
made the optimizer not notice the latter, and think that those fields should be
always zero in the bihash, thus generating incorrect assembly for the bihash key
comparison for the ipv4 nodes.
Changing the zeroing to be non-overlapping by zeroing only the pad fields resulted
in the optimizer generating the correct code and the tests pass.
Change-Id: Ib0f55cef2b5fe70c931d17ca4dc32a5755d160cd
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Dave Barach [Sat, 26 May 2018 14:48:55 +0000 (10:48 -0400)]
VPP-1294: add missing feature arc constraint
the ip4-dhcp-client-detect feature MUST run prior to nat44-out2in, or
inbound dhcp broadcast packets will be dropped. Certain dhcp servers
answer lease renewal dhcp-request packets with broadcast dhcp-acks, leading
to unrecoverable lease loss.
In detail, this constraint:
VNET_FEATURE_INIT (ip4_snat_out2in, static) = {
.arc_name = "ip4-unicast",
.node_name = "nat44-out2in",
.runs_after = VNET_FEATURES ("acl-plugin-in-ip4-fa"),
};
doesn't get the job done:
ip4-unicast:
[17] nat44-out2in
[23] ip4-dhcp-client-detect
[26] ip4-not-enabled
Add a proper constraint:
VNET_FEATURE_INIT (ip4_snat_out2in, static) = {
.arc_name = "ip4-unicast",
.node_name = "nat44-out2in",
.runs_after = VNET_FEATURES ("acl-plugin-in-ip4-fa",
"ip4-dhcp-client-detect"),
};
and the interface feature order is OK, at least in this regard:
ip4-unicast:
[17] ip4-dhcp-client-detect
[18] nat44-out2in
[26] ip4-not-enabled
We need to carefully audit (especially) the ip4-unicast feature arc,
which has [gasp] 37 features on it!
Change-Id: I5e749ead7ab2a25d80839a331de6261e112977ad
Signed-off-by: Dave Barach <dave@barachs.net>
John Lo [Sat, 26 May 2018 01:10:23 +0000 (21:10 -0400)]
Fix interface-rx-dpo-l2 node to setup l2_len in vnet buffer
Change-Id: Ic1fab1f3aba92bbdbfd281459562d1f9697ab465
Signed-off-by: John Lo <loj@cisco.com>
Zhiyong Yang [Thu, 24 May 2018 09:24:29 +0000 (05:24 -0400)]
dpdk: enable RX for no-multi-seg
The option no-multi-seg doesn't take effect for RX since MTU
which is too large is passed to DPDK lib, Which causes PMDs
are running XXX_scattered_rx function. The patch fixes the issue.
Change-Id: I91a6fb23fd118e872c8a52a6c35c36a86cb2c02b
Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
Florin Coras [Thu, 24 May 2018 04:01:30 +0000 (21:01 -0700)]
tcp: loss recovery improvements/fixes
- fix newreno cwnd computation
- reset snd_una_max on entering recovery
- accept acks beyond snd_nxt but less than snd_congestion when in
recovery
- avoid entering fast recovery multiple times when using sacks
- avoid as much as possible sending small segments when doing fast
retransmit
- more event logging
Change-Id: I19dd151d7704e39d4eae06de3a26f5e124875366
Signed-off-by: Florin Coras <fcoras@cisco.com>
Andrew Yourtchenko [Thu, 24 May 2018 14:53:27 +0000 (16:53 +0200)]
acl-plugin: create forward and return sessions in lieu of making a special per-packet session key
Using a separate session key has proven to be tricky for the following reasons:
- it's a lot of storage to have what looks to be nearly identical to 5tuple,
just maybe with some fields swapped
- shuffling the fields from 5tuple adds to memory pressure
- the fact that the fields do not coincide with the packet memory
means for any staged processing we need to use up a lot of memory
Thus, just add two entries into the bihash table pointing to
the same session entry, so we could match the packets from either
direction.
With this we have the key layout of L3 info (which takes up
the majority of space for IPv6 case) the same as in the packet,
thus, opening up the possibility for other optimizations.
Not having to create and store a separate session key
should also give us a small performance win in itself.
Also, add the routine to show the session bihash in a better
way than a bunch of numbers.
Alas, the memory usage in the bihash obviously doubles.
Change-Id: I8fd2ed4714ad7fc447c4fa224d209bc0b736b371
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Dave Barach [Fri, 25 May 2018 21:36:05 +0000 (17:36 -0400)]
Add interface rx pcap tracing
Should cost at most 1 clock per frame when not enabled.
Add "pcap rx trace..." debug CLI, refactored "pcap tx trace" debug CLI
to avoid duplicating code.
Change-Id: I19ac75d1cf94a6a24c98facbf0753381d37963ea
Signed-off-by: Dave Barach <dbarach@cisco.com>
Juraj Sloboda [Tue, 15 May 2018 09:43:56 +0000 (11:43 +0200)]
Fix possible null pointer dereference
Replace clib_warning with vlib_log_warn
Change-Id: I6d0b8d97048b75f4418609264af0c14e19fad79b
Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
Florin Coras [Thu, 24 May 2018 03:44:12 +0000 (20:44 -0700)]
tcp: handle acks in close wait
Thanks to Ning Li <muziding001@163.com> for reporting.
Change-Id: I758bc6760ec5a9ec688172bc162a1873f96ab4f3
Signed-off-by: Florin Coras <fcoras@cisco.com>
Jakub Grajciar [Tue, 22 May 2018 08:21:57 +0000 (10:21 +0200)]
memif: Add support for logging
Change-Id: I0fe60a639c7589dc842d85db092c81c1a7441cb7
Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
Steven [Fri, 11 May 2018 18:06:23 +0000 (11:06 -0700)]
bond: performance harvesting
- hash is great. But it is a bit too slow for the DP. Use direct array indexing
to quickly retrieve the slave interface.
- the algorithm used by flow hash is great. But it is a bit too slow for the DP.
Use l2_hash_hash() extracted from lb_hash.h which ECMP is using. It makes use
of intrinsic crc32 instruction set.
- shortcut modulo arithmetic when the operand is 2**x (where x up to 4) to
avoid division instruction.
- special case for link count == 1 in bond_tx_fn()
- use clib_mem_unaligned to access data for the packet to avoid alignment error
- Fix some typos for packet tracing.
Change-Id: I8eae3ad497061c5473aa675ba894ee0211120d25
Signed-off-by: Steven <sluong@cisco.com>
Neale Ranns [Tue, 22 May 2018 15:40:52 +0000 (08:40 -0700)]
ARP proxy dumps
Change-Id: I8335ebf266becf2f42bb3f28a17dfed8d9b08f97
Signed-off-by: Neale Ranns <nranns@cisco.com>
Bin Huang [Thu, 24 May 2018 08:43:19 +0000 (16:43 +0800)]
Fix VPP DPDK build failure with Mellanox NIC on aarch64
This compile issue was first reported by Sirshak Das in following thread:
https://lists.fd.io/g/vpp-dev/message/8384
The issue was caused by auto-config shell script auto-config-h.sh regard
quotation mark "" as $CROSS prefix for $CC when CROSS is empty.
Change-Id: Ied535c6d18c4dffacbddabc3ad2087dffe19438d
Signed-off-by: Bin Huang <huangbin.mails@gmail.com>
Damjan Marion [Wed, 23 May 2018 18:21:51 +0000 (20:21 +0200)]
Vectorized bihash_{48,40,24,16}_8 key compare
bihash_48_8 case:
Scalar code: 6 clocks
SSE4.2 code: 3 clocks
AVX2 code: 2.27 clocks
AVX512 code: 1.5 clocks
Change-Id: I40700175835a1e7321276e47eadbf9771d3c5a68
Signed-off-by: Damjan Marion <damarion@cisco.com>
Ole Troan [Thu, 24 May 2018 11:21:43 +0000 (13:21 +0200)]
VPP-1277: IPIP - Copy TOS/TC from inner packet to outer.
Add support for either copying TOS/TC from inner packet to outer,
or set to fixed value.
Change-Id: I716a95f875349acec94317b266c8cf9f2f81a785
Signed-off-by: Ole Troan <ot@cisco.com>
Dave Barach [Thu, 24 May 2018 21:32:00 +0000 (17:32 -0400)]
VPP-1286: close the fd after mmap-ing svm segments
Broken for years. Duh.
Change-Id: Ie5fb8e802f143aacd3301c45b136b24a8d4f6d74
Signed-off-by: Dave Barach <dave@barachs.net>
Damjan Marion [Tue, 15 May 2018 17:51:38 +0000 (19:51 +0200)]
Rewrite of l2-output node
Change-Id: I8cbd1eac80ae4aeb173d02786e9ccf3b4877304d
Signed-off-by: Damjan Marion <damarion@cisco.com>
Klement Sekera [Wed, 23 May 2018 18:22:20 +0000 (20:22 +0200)]
make test: VPP-1288 fix from sw_if_index values
Change-Id: I80297e78d93d8cf0d347863e4d2fdb12ea9294ac
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Ole Troan [Wed, 23 May 2018 09:21:42 +0000 (11:21 +0200)]
VPP-1283: IPv6 PMTU missing MTU value in ICMP6 message.
Fix GRE/IPv6 setting of ip->payload_length (which has never worked).
Change-Id: Ie68f1cc7bbb70489d6ec97356132c783f2345e1e
Signed-off-by: Ole Troan <ot@cisco.com>
Ole Troan [Fri, 18 May 2018 09:01:31 +0000 (11:01 +0200)]
VPP-1283: IPv4 PMTU missing MTU value in ICMP4 message.
Change-Id: I7a4133c59ff45b0744b48e246a049d9f015026fc
Signed-off-by: Ole Troan <ot@cisco.com>
Ole Troan [Tue, 24 Apr 2018 04:02:37 +0000 (00:02 -0400)]
VPPAPIGEN: Add union and enum support and IP4/IP6 address type.
Note: The Python, Java and C/C++ bindings must be updated before ip/ip_types.api can be used.
ip_types.api:
typedef ip4_address {
u8 address[4];
};
typedef ip6_address {
u8 address[16];
};
enum address_family {
ADDRESS_IP4 = 0,
ADDRESS_IP6,
};
union address_union {
vl_api_ip4_address_t ip4;
vl_api_ip6_address_t ip6;
};
typedef address {
vl_api_address_family_t af;
vl_api_address_union_t un;
};
Change-Id: I22f67092f24db5bd650a03c6f446a84cd9fd1074
Signed-off-by: Ole Troan <ot@cisco.com>
Eyal Bari [Thu, 17 May 2018 13:26:34 +0000 (16:26 +0300)]
dpdk:flow add vxlan flow support
Change-Id: Ic9f98c022e32715af395c9ed618589434eb0e526
Signed-off-by: Eyal Bari <ebari@cisco.com>
Florin Coras [Tue, 22 May 2018 18:39:59 +0000 (11:39 -0700)]
tcp: cc improvements and fixes
Change-Id: I6615bb612bcc3f795b5f822ea55209bb30ef35b5
Signed-off-by: Florin Coras <fcoras@cisco.com>
Jakub Grajciar [Mon, 21 May 2018 10:39:03 +0000 (12:39 +0200)]
avf plugin: add support for logging
Change-Id: Ic8c5b527395fc99f1e1a72e51f8d41c9b4f415df
Signed-off-by: Jakub Grajciar <jgrajcia@cisco.com>
Andrew Yourtchenko [Fri, 18 May 2018 16:48:00 +0000 (18:48 +0200)]
acl-plugin: refactor to introduce multiarch dataplane functions
This commit splits the functions from fa_node.c
into the pure dataplane node functions (which are multiarch-compiled),
session management node functions (which are compiled only once),
and session find/add/delete functions which are split out into the inlines.
As part of the refactoring:
- get rid of BV() macros in the affected chunk of code,
rather use the explicit bihash function names.
- add the magic trailer to the new files to
ensure make checkstyle watches them.
- move the bihash_template.c include for 40_8 bihash into acl.c
Change-Id: I4d781e9ec4307ea84e92af93c09470ea2bd0c375
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Damjan Marion [Tue, 22 May 2018 12:07:47 +0000 (14:07 +0200)]
vppinfra: add clib_count_equal_uXX and clib_memset_uXX functions
Change-Id: I56782652d8ef10304900cc293cfc0502689d800e
Signed-off-by: Damjan Marion <damarion@cisco.com>
Radu Nicolau [Mon, 12 Mar 2018 13:52:41 +0000 (13:52 +0000)]
CSIT-928 dpdk/ipsec: performance improvement
Replace hash with a vector to improve performance.
Plus other minor performance improvements.
Change-Id: I3f0ebd909782ce3727f6360ce5ff5ddd131f8574
Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Florin Coras [Thu, 17 May 2018 20:28:34 +0000 (13:28 -0700)]
tcp: unlock link-local adjacencies on connection cleanup
Change-Id: I37705fb572045f42be4c2dabbd8460c8f8872167
Signed-off-by: Florin Coras <fcoras@cisco.com>
Eyal Bari [Wed, 16 May 2018 08:30:23 +0000 (11:30 +0300)]
dpdk:enable flow director perfect mode
when flows are enabled on the device
Change-Id: I971764988d5a9e7078468f627205b3fa60736263
Signed-off-by: Eyal Bari <ebari@cisco.com>
Damjan Marion [Fri, 18 May 2018 22:04:23 +0000 (00:04 +0200)]
vector functions cleanup and improvements
Remove functions which have native C equivalent (i.e. _is_equal can be
replaced with ==, _add with +)
Add SSE4.2, AVX-512 implementations of splat, load_unaligned, store_unaligned,
is_all_zero, is_equal, is_all_equal
Change-Id: Ie80b0e482e7a76248ad79399c2576468532354cd
Signed-off-by: Damjan Marion <damarion@cisco.com>
Igor Mikhailov (imichail) [Sat, 19 May 2018 03:08:26 +0000 (20:08 -0700)]
MLX DPDK glue: exclude dependency on OFED libraries
MLX DPDK mlx5_glue.so, compiled under RTE_LIBRTE_MLX5_DLOPEN_DEPS,
provides a run-time check for OFED libraries.
To do so, it links with -libverbs -lmlx5 so that the binding could
occur or fail at runtime (see DPDK
59b91be and VPP
59b91be).
However RPM install fails on systems without OFED installed since
RPM spec has an entry "Requires: libmlx5".
To overcome this, exclude such requirement from the spec.
Same applies to mlx4_glue.so, compiled under RTE_LIBRTE_MLX4_DLOPEN_DEPS
Change-Id: I0ff6efc49581104743cc7e5b1f7cdbc1665ce9ba
Signed-off-by: Igor Mikhailov (imichail) <imichail@cisco.com>
Mohsin Kazmi [Fri, 18 May 2018 14:27:26 +0000 (16:27 +0200)]
log: Validate the size of vec in vlib_log
Change-Id: I6d1218c17ee055275596b9a49767f15994aa1b2b
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Damjan Marion [Sat, 19 May 2018 08:27:10 +0000 (10:27 +0200)]
Disable vector code in vlib_buffer_enqueue_to_next if no msb mask function
This fixes ARM64 build where we dont have defined u16x8_msb_mask(...)
Change-Id: I864f5134a0d951601810c800f587d173b3b7ef41
Signed-off-by: Damjan Marion <damarion@cisco.com>
Florin Coras [Fri, 18 May 2018 07:41:55 +0000 (00:41 -0700)]
tcp_echo: support multiple connections
Change-Id: I6d8e1351e088728f7363550a0fc117256cae2841
Signed-off-by: Florin Coras <fcoras@cisco.com>
Neale Ranns [Fri, 18 May 2018 09:27:10 +0000 (02:27 -0700)]
IP unnumbered dump
Change-Id: I4f245fd225bcc563fafee2696cd039477d661c57
Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
Damjan Marion [Thu, 17 May 2018 19:12:13 +0000 (21:12 +0200)]
Add vlib_buffer_enqueue_to_next inline function
Change-Id: I1042c0fe179b57a00ce99c8d62cb1bdbe24d9184
Signed-off-by: Damjan Marion <damarion@cisco.com>
Neale Ranns [Thu, 17 May 2018 13:34:24 +0000 (06:34 -0700)]
IP table bind allowed only if table exists
Change-Id: If01400e3434b25b2da36ba28ceb8444b216d0e38
Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
Jon Loeliger [Thu, 17 May 2018 20:55:00 +0000 (15:55 -0500)]
ARP: Ensure STATIC and DYANMIC ARP flags are mutually exclusive.
Change-Id: I44278dea2ee1daa147b0928bfe26e861907a209f
Signed-off-by: Jon Loeliger <jdl@netgate.com>
Neale Ranns [Thu, 17 May 2018 16:38:13 +0000 (09:38 -0700)]
IP address dump - don't send subnets for unnumbered interfaces
Change-Id: I8c64a0d2f757d96ffa7fd042c23b0d814217c215
Signed-off-by: Neale Ranns <neale.ranns@cisco.com>
Dave Wallace [Thu, 17 May 2018 16:06:27 +0000 (12:06 -0400)]
18.01.2 Release Notes
Change-Id: I17ba98b48409d907081a0fd8d7db35adf45192ef
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Florin Coras [Thu, 17 May 2018 02:28:24 +0000 (19:28 -0700)]
session: add session process node
Add a session process node that handles main thread tx and retransmit in
order to avoid having a polling input node.
Change-Id: I3357e987c023a84b533b32793e37ab4204420f64
Signed-off-by: Florin Coras <fcoras@cisco.com>
Mohsin Kazmi [Thu, 17 May 2018 15:21:39 +0000 (17:21 +0200)]
tap: remove the local vlib_log_info definition
Change-Id: Idff55a19d27fed0d57e222f38d2e16c5367911cb
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Hongjun Ni [Tue, 6 Feb 2018 15:00:22 +0000 (23:00 +0800)]
Rework kube-proxy into LB plugin
Add support of NAT66
Change-Id: Ie6aa79078a3835f989829b9a597c448dfd2f9ea3
Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
Damjan Marion [Thu, 17 May 2018 10:44:00 +0000 (12:44 +0200)]
Add buffer pointer-to-index and index-to-pointer array functions
Change-Id: Ib3fcc3ceb7f315389bcdecbb7d9632540a5dd6ba
Signed-off-by: Damjan Marion <damarion@cisco.com>
Mohsin Kazmi [Thu, 17 May 2018 14:47:08 +0000 (16:47 +0200)]
vlib: Fix WARN-ING macro in function
Change-Id: I238106c2afc46904fb0eb17164f30dbd1378892e
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Matthew Smith [Tue, 15 May 2018 20:51:30 +0000 (15:51 -0500)]
Fix failure during enable/disable of features
vnet_feature_enable_disable_with_index() checks the
return status of vnet_config_{add,del}_feature().
If the config string heap index returned is the same
index that was in use prior to the add/delete, it is
concluded that a failure occurred and processing of
the feature stops.
Sometimes the config index that is returned
can legitimately be the same index that was in used
before the add/delete. The old list of features can
have its heap entry deallocated before a new entry for
the new list is allocated. The heap entry for the new
list can be the entry that was deallocated while
deleting the old one.
Make vnet_config_{add,del}_feature() return ~0 on
failure. Look for that return value as an indication
that an error occurred in
vnet_enable_disable_feature_by_index().
Change-Id: I88bb3ff88a76971c1b5e5ece74784ce8ba78373c
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
Marco Varlese [Thu, 17 May 2018 13:46:13 +0000 (15:46 +0200)]
Allow openSUSE tumbleweed
Change-Id: I2ab7f5d2a30620b12bd345d6102a3d381ee5d5ec
Signed-off-by: Marco Varlese <marco.varlese@suse.com>
Juraj Sloboda [Thu, 17 May 2018 10:05:27 +0000 (12:05 +0200)]
Fixes in IPv6 RD control plane
Add default route to the VRF table in which the interface is bound.
Add missing pool_put.
Change-Id: Id76c7dbfbf9bcf18357f372f3eee9b931df1995e
Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
Eyal Bari [Wed, 16 May 2018 09:15:32 +0000 (12:15 +0300)]
flow:redirect to node
Change-Id: I4b6577b496c56f27f07dd0066fcfdfd0cebb6f1a
Signed-off-by: Eyal Bari <ebari@cisco.com>
Matus Fabian [Mon, 14 May 2018 13:20:28 +0000 (06:20 -0700)]
NAT44: nat44_del_session and nat44_user_session_details API update (VPP-1271)
Change-Id: I484d79000c1bbd87ff83847cf567bf3414a719d3
Signed-off-by: Matus Fabian <matfabia@cisco.com>