vpp.git
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>
5 years agoacl-plugin: 5-tuple parse: get rid of memcpy and move to flags vs. bitfields 09/15709/2
Andrew Yourtchenko [Thu, 25 Oct 2018 17:01:49 +0000 (19:01 +0200)]
acl-plugin: 5-tuple parse: get rid of memcpy and move to flags vs. bitfields

Using bitfield struct for 5tuple proved to be fragile from
the performance standpoint - the zeroizing of the entire
structure and then setting the separate pieces of it
triggers increased memory latency. So, move to using
flags byte.

Also, use the direct object copies rather than memcpy.

Change-Id: Iad8faf9de050ff1256e40c950dee212cbd3e5267
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
5 years agovxlan: prefetch extra one cacheline holding external header 88/15688/2
Zhiyong Yang [Mon, 5 Nov 2018 08:45:25 +0000 (03:45 -0500)]
vxlan: prefetch extra one cacheline holding external header

For vxlan_encap, code will touch memory area before the field "data"
in struct vlib_buffer_t, however so far it is not prefetched in cache
yet for this graph node.
After applying the patch, 2~3 cycles per pkt for vxlan4_encap can be
saved on Haswell. It will bring a lot of benefits on DVN platform too.

Change-Id: I26d8c57fb3d2415726be5367117d73eb715e35ad
Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
5 years agodpdk: enable gso when the tap PMD is enabled 19/15619/2
Matthew Smith [Mon, 29 Oct 2018 21:35:30 +0000 (16:35 -0500)]
dpdk: enable gso when the tap PMD is enabled

Setting DPDK_PMD_TAP=y when building will enable the tap PMD
in the build configuration that is generated for DPDK. Enabling
this currently results in a failure during compilation because
rte_gso.h is not found. RTE_LIBRTE_GSO needs to be set to y for
this to work.

Use the setting for the tap PMD to determine the value for
RTE_LIBRTE_GSO.

Change-Id: Ie395417b1c62369a95320856081ad52c674ce9f2
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
5 years agoDon't autodetect plugin path if set on cmdline 41/15641/3
Klement Sekera [Wed, 31 Oct 2018 18:06:54 +0000 (19:06 +0100)]
Don't autodetect plugin path if set on cmdline

Change-Id: Idf79f261a7590038c1813d3996f4644e3d7e0cbe
Signed-off-by: Klement Sekera <ksekera@cisco.com>
5 years agoEnable atomic swap and store macro with acquire and release ordering 18/15618/5
Sirshak Das [Fri, 12 Oct 2018 14:38:27 +0000 (09:38 -0500)]
Enable atomic swap and store macro with acquire and release ordering

Add atomic swap and store macro with acquire and release ordering
respectively.  Variable in question is interupt_pending variable which
is used as guard variable by input nodes to process the device queue.

Atomic Swap is used with Acquire ordering as writes or reads following
this in program order should not be reordered before the swap.

Atomic Store is used with Release ordering, as post store the node is
added to pending list.

Change-Id: I1be49e91a15c58d0bf21ff5ba1bd37d5d7d12f7a
Original-patch-by: Damjan Marion <damarion@cisco.com>
Signed-off-by: Sirshak Das <sirshak.das@arm.com>
Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Reviewed-by: Ola Liljedahl <ola.liljedahl@arm.com>
5 years agoGenric API types format/unformat support for VAT and custom dump 77/15677/2
Neale Ranns [Fri, 2 Nov 2018 16:14:01 +0000 (09:14 -0700)]
Genric API types format/unformat support for VAT and custom dump

Change-Id: I8bc3a991f0ede0605d78b51ba609fbe5889513f2
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoVPP-1450: binary api call for dumping SPD to interface registration 74/15674/5
Filip Varga [Fri, 2 Nov 2018 12:51:44 +0000 (13:51 +0100)]
VPP-1450: binary api call for dumping SPD to interface registration

Change-Id: Idd4a5f8bab5d39e5f33f5c130601175af70a20d4
Signed-off-by: Filip Varga <filip.varga@pantheon.tech>
5 years agotcp: send unsent data in fast recovery 78/15678/10
Florin Coras [Fri, 2 Nov 2018 19:52:10 +0000 (12:52 -0700)]
tcp: send unsent data in fast recovery

Allows sending of unsent data in fast recovery and consolidates logic in
tcp, instead of splitting it between tcp fast retransmit and tcp output
path called by the session layer.

Change-Id: I9b12cdf2aa2ac50b9f25e46856fed037163501fe
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoProvide return value for PAPI disconnect() 89/15489/4
Igor Mikhailov (imichail) [Wed, 24 Oct 2018 00:58:14 +0000 (17:58 -0700)]
Provide return value for PAPI disconnect()

Change-Id: I209f570634636725ce8fda5f61e900a71227b888
Signed-off-by: Igor Mikhailov (imichail) <imichail@cisco.com>
5 years agoAlter logging semantics for VPP PAPI object 17/15617/2
Igor Mikhailov (imichail) [Tue, 30 Oct 2018 19:17:49 +0000 (12:17 -0700)]
Alter logging semantics for VPP PAPI object

Restore parts of commit d0e812f wiped out by a7564e80

The full description of the change is in d0e812f

Change-Id: I632476cb10678a725396462f90f9b0bea9e572fa
Signed-off-by: Igor Mikhailov (imichail) <imichail@cisco.com>
5 years agotcp: coverity fixes 76/15676/2
Florin Coras [Fri, 2 Nov 2018 15:23:58 +0000 (08:23 -0700)]
tcp: coverity fixes

Change-Id: Ib15d629c5fde7849bfa3307f42659e920eb0f463
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agocdp scapy protocol & cdp unit tests 22/15622/6
Filip Varga [Wed, 31 Oct 2018 06:58:05 +0000 (07:58 +0100)]
cdp scapy protocol & cdp unit tests

Change-Id: Ieb362523f81f7ae3e1a9dceb341c499ff1f402c8
Signed-off-by: Filip Varga <fivarga@cisco.com>
5 years agovnet: ping: rewrite for maintainability and multicore support 57/15557/11
Andrew Yourtchenko [Fri, 26 Oct 2018 13:13:56 +0000 (15:13 +0200)]
vnet: ping: rewrite for maintainability and multicore support

Refactor most of the ping code to be address-family agnostic,
and add support for chained buffers (thus, sending
the payloads bigger than 2K).

Change-Id: I749c302ca2f3390e0d1f84046fc72da5cf13e3ef
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
5 years agovlib: define minimum chained buffer segment size 28/15628/4
Damjan Marion [Wed, 31 Oct 2018 09:59:02 +0000 (10:59 +0100)]
vlib: define minimum chained buffer segment size

Change-Id: I9b5f7b264f9978e3dd97b2d1eb103b7d10ac3170
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agodpdk: restore special handling for failsafe driver 64/15664/2
Stephen Hemminger [Thu, 1 Nov 2018 21:17:14 +0000 (14:17 -0700)]
dpdk: restore special handling for failsafe driver

The failsafe driver is unique because it shares device with underlying
pci device. This confuses name generation. Without this fix, the name
is wrong and multiple devices get created with same name.

Fixes: 3901a038edf4 ("dpdk: only look at PCI information on PCI devices")
Change-Id: I13796d03baf6c76dafe3667c83bea4a1ae30c48f
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
5 years agosession: measure dispatch period only if under load 68/15668/7
Florin Coras [Thu, 1 Nov 2018 23:30:54 +0000 (16:30 -0700)]
session: measure dispatch period only if under load

Also reset pacer on tcp retransmit timeout

Change-Id: I5a9edee4c00d1d169248d79587a9b10437c2bd87
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agotcp: minimize use of tls 63/15663/7
Florin Coras [Thu, 1 Nov 2018 18:23:03 +0000 (11:23 -0700)]
tcp: minimize use of tls

Also propagate tcp worker context instead of retrieving it multiple
times.

Change-Id: I7b273b981826b37783566d0172a64cd6957f3b33
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoarp:add error counters for all failure cases 30/15630/3
Eyal Bari [Wed, 31 Oct 2018 11:19:11 +0000 (13:19 +0200)]
arp:add error counters for all failure cases

Change-Id: Ided6c661edc9e2035fd7b472c312e2380d3f9c0b
Signed-off-by: Eyal Bari <ebari@cisco.com>
5 years agotcp: fast retransmit pacing 58/15658/4
Florin Coras [Thu, 1 Nov 2018 06:09:22 +0000 (23:09 -0700)]
tcp: fast retransmit pacing

Force pacing for fast retransmit to avoid bursts of retransmitted
packets.

Change-Id: I2ff42c328899b36322c4de557b1f7d853dba8fe2
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoMove RPC calls off the binary API input queue 60/15660/2
Dave Barach [Thu, 1 Nov 2018 12:12:52 +0000 (08:12 -0400)]
Move RPC calls off the binary API input queue

Change-Id: I2476e3e916a42b41d1e66bfc1ec4f8c4264c1720
Signed-off-by: Dave Barach <dbarach@cisco.com>
5 years agoFix API name_crc format stored in msg_api_table 53/15653/2
Igor Mikhailov (imichail) [Wed, 31 Oct 2018 21:20:04 +0000 (14:20 -0700)]
Fix API name_crc format stored in msg_api_table

Change-Id: I716d025beb8f649060238c2bd388357943643621
Signed-off-by: Igor Mikhailov (imichail) <imichail@cisco.com>
5 years agovom: Add igmp 'host' support in vom 15/15615/6
Mohsin Kazmi [Tue, 30 Oct 2018 18:24:34 +0000 (19:24 +0100)]
vom: Add igmp 'host' support in vom

Change-Id: Ibdb19d21b8ec7fb340a057e32df207b7723dba9b
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
5 years agosession: fix sh session cli 45/15645/2
Florin Coras [Wed, 31 Oct 2018 19:25:38 +0000 (12:25 -0700)]
session: fix sh session cli

Change-Id: Idbc7b61393c6d0e3b8ea950397a89d21b1cf3a42
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoMakefile: support both RHEL and CentOS in install-dep 43/15643/1
Yichen Wang [Wed, 31 Oct 2018 05:52:15 +0000 (22:52 -0700)]
Makefile: support both RHEL and CentOS in install-dep

Change-Id: I31fd8700bfac462944b7621947edd3710fd247b9
Signed-off-by: Yichen Wang <yicwang@cisco.com>
5 years agomake-test: Fix the vapi test 40/15640/1
Mohsin Kazmi [Wed, 31 Oct 2018 15:45:19 +0000 (16:45 +0100)]
make-test: Fix the vapi test

Change-Id: I5a4dc3894818f92368d6c906ff43e093c16c1d19
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
5 years agoEMACS-LISP-ONLY: fix names of xxx_main_t pointers 39/15639/1
Dave Barach [Wed, 31 Oct 2018 13:54:34 +0000 (09:54 -0400)]
EMACS-LISP-ONLY: fix names of xxx_main_t pointers

main_t pointer: <first-letter-of-plugin-name> + "mp"
test_main_t pointer: <first-letter-of-plugin-name> + "mp"

AKA: (setq main-p (concat (substring plugin-name 0 1) "mp")) etc.

Change-Id: Ie1b38fb62485183bbe00f649683492aa82a21376
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agoEMACS-LISP-ONLY: fix boilerplate compile error 38/15638/1
Dave Barach [Wed, 31 Oct 2018 13:23:35 +0000 (09:23 -0400)]
EMACS-LISP-ONLY: fix boilerplate compile error

Change-Id: I81defe6465219e23a44608fcf0570a058ab3f59e
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agoAdd and enable msb mask vector intrinsic for aarch64. 06/15606/4
Lijian Zhang [Thu, 25 Oct 2018 10:50:33 +0000 (18:50 +0800)]
Add and enable msb mask vector intrinsic for aarch64.

This patch enables the use of this function for enqueuing frames to the next graph node.

Change-Id: I4003110db59870f7106e0d13942d6ff7bc54b46d
Signed-off-by: Lijian Zhang <Lijian.Zhang@arm.com>
Reviewed-by: Sirshak Das <Sirshak.Das@arm.com>
Reviewed-by: Honnappa Nagarahalli <Honnappa.Nagarahalli@arm.com>
Reviewed-by: Steve Capper <Steve.Capper@arm.com>
5 years agol2fib:remove unused bucket arg in lookup functions 27/15627/1
Eyal Bari [Wed, 31 Oct 2018 08:55:33 +0000 (10:55 +0200)]
l2fib:remove unused bucket arg in lookup functions

Change-Id: Ib138b6e2eac47acc16e81bc88358ae7947420134
Signed-off-by: Eyal Bari <ebari@cisco.com>
5 years agosession: prioritize postponed sessions 14/15614/5
Florin Coras [Tue, 30 Oct 2018 17:21:59 +0000 (10:21 -0700)]
session: prioritize postponed sessions

If sessions cannot be handled during the current dispatch loop
iteration, ensure that they are first to be handled in the next.

Change-Id: Ifc6215900f8cfd530d4886b58641189f0ccf9bb7
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agosession: add wrk context 16/15616/5
Florin Coras [Tue, 30 Oct 2018 19:01:48 +0000 (12:01 -0700)]
session: add wrk context

Change-Id: I66ca0ddea872948507d078e405eb90f9f3a0e897
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoADJ: init MTU to interface default 05/15605/2
Neale Ranns [Tue, 30 Oct 2018 13:34:25 +0000 (06:34 -0700)]
ADJ: init MTU to interface default

Change-Id: Iaecf8c060e1337d8c362ad9a9be2bb9701664397
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoDOC-ONLY: document packet intialization from scratch 10/15610/2
Dave Barach [Tue, 30 Oct 2018 14:24:17 +0000 (10:24 -0400)]
DOC-ONLY: document packet intialization from scratch

Minor clean-up in the home gateway use-case documentation

Change-Id: I7d3aaea8cec62248daf7814b21a8acb574ac12a1
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agochange mac address functions take const mac 00/15600/2
Neale Ranns [Tue, 30 Oct 2018 10:47:20 +0000 (03:47 -0700)]
change mac address functions take const mac

Change-Id: Ia68db22b917e9af1394c00e5a6b3df134bfd1568
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agodocs: Add VPP with iperf and trex 04/15604/2
jdenisco [Tue, 30 Oct 2018 12:46:02 +0000 (08:46 -0400)]
docs: Add VPP with iperf and trex

Change-Id: I9f238b6092bc072fd875facfee5262c6b155043e
Signed-off-by: jdenisco <jdenisco@cisco.com>
5 years agoDOC-ONLY: upgrade the "requests" package 03/15603/2
Dave Barach [Tue, 30 Oct 2018 12:35:06 +0000 (08:35 -0400)]
DOC-ONLY: upgrade the "requests" package

requests 2.18.4 is the subject of a security alert

Change-Id: Id1e9338d86bced8c0bb065db7b3dc7f02aa41afc
Signed-off-by: Dave Barach <dave@barachs.net>
5 years agovppinfra: fix bug in default_socket_sendmsg 01/15601/1
Damjan Marion [Tue, 30 Oct 2018 12:04:19 +0000 (13:04 +0100)]
vppinfra: fix bug in default_socket_sendmsg

Change-Id: Ia9b74761ce511d218bb5319c7c9b5e58be3e2e8a
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agodpdk: .function should be removed for mutiarch nodes 99/15599/1
Damjan Marion [Tue, 30 Oct 2018 09:04:53 +0000 (10:04 +0100)]
dpdk: .function should be removed for mutiarch nodes

Fixes debug build crash.

Change-Id: Ia5c5da82beda5992f9e67456af9a4676b9b82722
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agomigrate ipsec to new multiarch infra 20/15420/5
Klement Sekera [Mon, 29 Oct 2018 12:38:19 +0000 (13:38 +0100)]
migrate ipsec to new multiarch infra

Change-Id: Ibef46e068cd72415af28920b0146adf48105bf68
Signed-off-by: Klement Sekera <ksekera@cisco.com>
5 years agoUse throttle_t for ND throttling 48/15548/5
Neale Ranns [Fri, 31 Aug 2018 09:51:45 +0000 (02:51 -0700)]
Use throttle_t for ND throttling

Change-Id: I93c6b7bccd1a1ab71625ae29c99c974581186c4d
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agointerface-flags; fix coverity error found in conversion 79/15579/2
Neale Ranns [Mon, 29 Oct 2018 08:55:24 +0000 (01:55 -0700)]
interface-flags; fix coverity error found in conversion

Change-Id: I2eafac4ce810fe53454b729d81161ec80d036db7
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agoFixing Exclusive dpo path issues added when via rpath 42/15542/6
Vijayabhaskar Katamreddy [Thu, 25 Oct 2018 20:28:12 +0000 (13:28 -0700)]
Fixing Exclusive dpo path issues added when via rpath

Change-Id: I7531a64d7072d85514ca579827b6ea0e9cef6f08
Signed-off-by: Vijayabhaskar Katamreddy <vkatamre@cisco.com>
5 years agosession: move test to unittest plugin 78/15578/2
Florin Coras [Mon, 29 Oct 2018 03:33:29 +0000 (20:33 -0700)]
session: move test to unittest plugin

Change-Id: I4921054b4e42bac3442d399681b21b613ce8b681
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agobond: problem switching from l2 to l3 77/15577/3
Steven [Sun, 28 Oct 2018 20:36:45 +0000 (13:36 -0700)]
bond: problem switching from l2 to l3

when the last interface is removed from l2 in the bonding group, we should
invoke ethernet_set_rx_direct to allow ip packets to go directly to
ip4-input.

Change-Id: I43b3cd64e2c119762edd0c295bb9348732adab45
Signed-off-by: Steven <sluong@cisco.com>
5 years agophysmem: coverity issues 49/15549/4
Damjan Marion [Fri, 26 Oct 2018 08:29:35 +0000 (10:29 +0200)]
physmem: coverity issues

Change-Id: I34cc55d8292a69fb451ed0031484994f51d3537a
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agosession: extend connect api for internal apps 46/15546/11
Florin Coras [Fri, 26 Oct 2018 01:03:45 +0000 (18:03 -0700)]
session: extend connect api for internal apps

Change-Id: Ie4c5cfc4c97acb321a46b4df589dc44de1b616ba
Signed-off-by: Florin Coras <fcoras@cisco.com>
5 years agoFIB: Sources must be keep in priority order, so re-sort after a vec_del 51/15551/4
Neale Ranns [Fri, 26 Oct 2018 11:17:54 +0000 (04:17 -0700)]
FIB: Sources must be keep in priority order, so re-sort after a vec_del

Change-Id: I77af4f3a7e826ea5c1a23ee8b348faefe9f2facc
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agopg: icmp4 & tcp4 ip length issue 74/15574/2
Kingwel Xie [Sat, 27 Oct 2018 03:26:06 +0000 (23:26 -0400)]
pg: icmp4 & tcp4 ip length issue

length in ip4 header could be 0, when the length edit is fixed
this happens if length is not specified or size is specified as, f.g., 100-100
As a result, tcp and icmp would get a negative value for checksum calculation

Change-Id: I55fa1f5e95717ea4149cb3b8c9b73caf88ae7f98
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
5 years agopg: incrementing len should be truncated by 76/15576/2
Kingwel Xie [Sat, 27 Oct 2018 03:55:47 +0000 (23:55 -0400)]
pg: incrementing len should be truncated by
stream->max_packet_bytes

This length is the payload length, and will impact the ip length
when ip length is not specified. iplen = header_len + payload_len
SO, better to make it comply with max_packet_bytes

Change-Id: I8b0f7485e29fcaccae656f2d03b3b5e614300fb8
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
5 years agopg: allow creating pg for udp based protocols 75/15575/2
Kingwel Xie [Sat, 27 Oct 2018 03:42:15 +0000 (23:42 -0400)]
pg: allow creating pg for udp based protocols

f.g., gtpu4/6

Change-Id: I8bb1dc5fd2fba89ff17ec069a9816bafb9684190
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
5 years agoEnumify interface flags 55/15555/4
Neale Ranns [Fri, 26 Oct 2018 12:17:03 +0000 (05:17 -0700)]
Enumify interface flags

clang will emit a warning when the wrong enum type is passed to a
function whose arguments are an enum type. free bug finding...

Change-Id: I62215d8ef22c7527a31272e31f5d190e4e762e53
Signed-off-by: Neale Ranns <nranns@cisco.com>
5 years agovmxnet3: add logging support to the control plane [VPP-1470] 73/15573/2
Steven [Sat, 27 Oct 2018 03:10:49 +0000 (20:10 -0700)]
vmxnet3: add logging support to the control plane [VPP-1470]

There are different flavors of vmxnet3 device, esxi server, vm fusion, vmware
workstation, and vmware player, that we need to communicate with. Each of
them also has different versions. We really need the control plane logging
to debug when things don't work as expected.

Change-Id: I53c23cf10958bfbc06abb1c252d368003563cd04
Signed-off-by: Steven <sluong@cisco.com>
5 years agovirtio: remove the extra return call 69/15569/3
Mohsin Kazmi [Fri, 26 Oct 2018 17:36:55 +0000 (19:36 +0200)]
virtio: remove the extra return call

Change-Id: I6e43953a6ad1bd672e69d8377d18bd9614b469d8
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
5 years agodpdk: fix mlx5 build on SUSE 44/15544/4
Stephen Hemminger [Thu, 25 Oct 2018 21:40:24 +0000 (14:40 -0700)]
dpdk: fix mlx5 build on SUSE

Current mlx5 requires libmnl, and SUSE has a bug which
installs the header file in incorrect location.

Workaround (from upstream) is to use pkg-config.

Change-Id: Iadfd2dc0df211876258c31da028af2e8934483b3
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
5 years agocj: cj dump crash 29/15229/2
Steven [Wed, 10 Oct 2018 21:48:32 +0000 (14:48 -0700)]
cj: cj dump crash

Thread 1 "vpp_main" received signal SIGSEGV, Segmentation fault.
0x00007ffff670da53 in cj_dump_one_record (r=0x7ffff50f0fec)
    at /home/sluong/vpp3/vpp/src/vlib/unix/cj.c:138
138    (long long unsigned int) r->data[1]);

(gdb) p *cjm
$1 = {tail = 58645908, records = 0x7fffb64646ec, num_records = 512,
  enable = 1, vlib_main = 0x7ffff6953240 <vlib_global_main>}
(gdb) p /x cjm
$2 = 0x7ffff6953880
(gdb) p /x *cjm
$3 = {tail = 0x37edd94, records = 0x7fffb64646ec, num_records = 0x200,
  enable = 0x1, vlib_main = 0x7ffff6953240}
(gdb)

cjm->tail is a 64 bit counter, not the total number of records. Dumping from
0 to cjm->tail can be a very large number of records which go beyond the
limit. I believe we meant to dump from 0 to index. index has been set  by
this statement
  index = (cjm->tail + 1) & (cjm->num_records - 1);

Change-Id: Ie1a8ba757598de9757accc1488577c15aa49726b
Signed-off-by: Steven <sluong@cisco.com>
5 years agovxlan-gbp: On demand udp ports registration 96/15496/4
Mohsin Kazmi [Wed, 24 Oct 2018 10:17:50 +0000 (12:17 +0200)]
vxlan-gbp: On demand udp ports registration

Change-Id: I3a47c71ad3e35df47d11fed6db95019a45f3015f
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
5 years agoacl-plugin: fix the node multiarch function selection 36/15536/3
Andrew Yourtchenko [Thu, 25 Oct 2018 16:21:33 +0000 (18:21 +0200)]
acl-plugin: fix the node multiarch function selection

Thanks to Damjan for rewriting my previous patch into
not-to-be-deprecated soon form!

Change-Id: I595a13c44ed07d4c6d60e2aef0f0bd807a76cbba
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
5 years agodpdk: ENA PMD patch for failure on port restart 35/15535/2
Matthew Smith [Thu, 25 Oct 2018 13:46:53 +0000 (08:46 -0500)]
dpdk: ENA PMD patch for failure on port restart

Patch to fix a bug in the ENA PMD on starting a port that
had previously been started and stopped. There was a
failure to allocate descriptors on start because they had
been allocated during the initial start and not released
when the port was stopped.

Issue reported/tracked at
https://github.com/amzn/amzn-drivers/issues/86

Change-Id: Id9c8d598929f0561788b985011fe5dea8f4a21a5
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
5 years agoTrivial: Fix Makefile typo 53/15553/2
Paul Vinciguerra [Fri, 26 Oct 2018 11:42:31 +0000 (04:42 -0700)]
Trivial: Fix Makefile typo

Change-Id: Ia108b0359cb2dc4ba2e773117ee7134274a98056
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
5 years agoextras/scripts: update vfctl script 54/15554/2
Damjan Marion [Fri, 26 Oct 2018 11:43:43 +0000 (13:43 +0200)]
extras/scripts: update vfctl script

Change-Id: I49cb5863237e4f9d2ac94879577d5d011e3bfe97
Signed-off-by: Damjan Marion <damarion@cisco.com>
5 years agodocs: add useful debug CLI Review Updates 63/15563/3
Scott Keeler [Fri, 26 Oct 2018 13:12:15 +0000 (09:12 -0400)]
docs: add useful debug CLI Review Updates

Change-Id: I4ebd977672090f2a7fc08bb139832df39614564a
Signed-off-by: Scott Keeler <skeeler@cisco.com>
5 years agovmxnet3: enable promiscuous mode 38/15538/2
Steven [Thu, 25 Oct 2018 18:04:42 +0000 (11:04 -0700)]
vmxnet3: enable promiscuous mode

Some L2 traffic requires promiscuous mode enable on the interface

Change-Id: Icbb2792aaf0d9d1c51373e46ae5049ff0d986863
Signed-off-by: Steven <sluong@cisco.com>
5 years agoRevert "Keep RPC traffic off the shared-memory API queue" 40/15540/2
Florin Coras [Thu, 25 Oct 2018 19:03:46 +0000 (19:03 +0000)]
Revert "Keep RPC traffic off the shared-memory API queue"

This reverts commit 71615399e194847d7833b744caedab9b841733e5.

There seems to be an issue with ARPs when running with multiple workers.

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