dpdk.git
6 years agotest/table: fix memory leak
Anatoly Burakov [Tue, 6 Feb 2018 13:35:41 +0000 (13:35 +0000)]
test/table: fix memory leak

Always deallocate allocated resources after the test is done.

Fixes: 5205954791cb ("app/test: packet framework unit tests")
Cc: stable@dpdk.org
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
6 years agotest/ring_perf: fix memory leak
Anatoly Burakov [Tue, 6 Feb 2018 13:35:40 +0000 (13:35 +0000)]
test/ring_perf: fix memory leak

Fixes: ac3fb3019c52 ("app: rework ring tests")
Cc: stable@dpdk.org
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
6 years agotest/ring: fix memory leak
Anatoly Burakov [Tue, 6 Feb 2018 13:35:39 +0000 (13:35 +0000)]
test/ring: fix memory leak

Get rid of global static ring variable and don't reuse rings
between test runs.

Acked-by: Olivier Matz <olivier.matz@6wind.com>
Fixes: 4e32101f9b01 ("ring: support freeing")
Cc: stable@dpdk.org
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
6 years agotest/reorder: fix memory leak
Anatoly Burakov [Tue, 6 Feb 2018 13:35:38 +0000 (13:35 +0000)]
test/reorder: fix memory leak

Add a teardown function that frees allocated resources.

Fixes: d0c9b58d7156 ("app/test: new reorder unit test")
Cc: stable@dpdk.org
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
6 years agotest/bitmap: fix memory leak
Anatoly Burakov [Tue, 6 Feb 2018 13:35:37 +0000 (13:35 +0000)]
test/bitmap: fix memory leak

Fixes: c7e4a134e769 ("test: verify bitmap operations")
Cc: stable@dpdk.org
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
6 years agoexamples/ip_pipeline: fix timer period unit
Bao-Long Tran [Wed, 31 Jan 2018 08:48:16 +0000 (15:48 +0700)]
examples/ip_pipeline: fix timer period unit

The timer_period option specified by users via config file
should have unit of 1 millisecond. However timer_period is
internally converted to unit of 10 millisecond.

Fixes: 4e14069328fc ("examples/ip_pipeline: measure CPU utilization")
Cc: stable@dpdk.org
Signed-off-by: Bao-Long Tran <longtb5@viettel.com.vn>
Reviewed-by: Jasvinder Singh <jasvinder.singh@intel.com>
6 years agoexamples/l2fwd: check if user portmask is valid
Vipin Varghese [Thu, 1 Feb 2018 18:58:42 +0000 (00:28 +0530)]
examples/l2fwd: check if user portmask is valid

User can pass portmask with any value, even invalid mask. The code
checks against actual portmask.

Signed-off-by: Vipin Varghese <vipin.varghese@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
6 years agobbdev: fix exported dynamic log type
Amr Mokhtar [Tue, 6 Feb 2018 13:29:30 +0000 (13:29 +0000)]
bbdev: fix exported dynamic log type

This patch fixes shared library compilation due to undefined
reference to an exported variable 'bbdev_logtype'.

Fixes: 4935e1e9f76e ("bbdev: introduce wireless base band device lib")
Fixes: b8cfe2c9aed2 ("bb/turbo_sw: add software turbo driver")
Fixes: 7dc2b1589440 ("bb/null: add null base band device driver")

Signed-off-by: Amr Mokhtar <amr.mokhtar@intel.com>
6 years agoethdev: fix stats query for lowest xstat id
Bruce Richardson [Tue, 6 Feb 2018 16:06:59 +0000 (16:06 +0000)]
ethdev: fix stats query for lowest xstat id

When querying either the name or the value of a stat using the xstats
APIs, a check is done to see if the regular stats API or the xstats APIs
for the driver need to be used. However, the id of the stat requested is
checked to see if it is greater than the number of basic stats, rather
than checking for greater-or-equal, meaning that the xstat with the lowest
id gets incorrectly treated as a basic stat.

This problem manifests itself when you call proc_info using "--xstats-id"
for the first xstat, you get no name of the stat printed, and a random(ish)
stat value.

Fixes: 4773152f850b ("ethdev: optimize xstats by ids APIs")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
6 years agobus/dpaa: fix default IOVA mode
Pavan Nikhilesh [Tue, 6 Feb 2018 17:22:48 +0000 (22:52 +0530)]
bus/dpaa: fix default IOVA mode

Fix dpaa bus returning IOVA as PA even when it is not running on dpaa
platform.

Fixes: 1ee9569576f6 ("config: enable dpaaX drivers for generic ARMv8")
Fixes: d5a4e3a00c4a ("bus/dpaa: set IOVA mode as physical")
Cc: stable@dpdk.org
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
6 years agobus/fslmc: fix build with latest glibc
Jerin Jacob [Tue, 6 Feb 2018 17:14:55 +0000 (22:44 +0530)]
bus/fslmc: fix build with latest glibc

Fix the following build error with latest glibc-headers(
Part of aarch64-linux-gnu-gcc-7.3.0 toolchain)

In file included from drivers/bus/fslmc/mc/fsl_mc_sys.h:30:0,
                 from drivers/bus/fslmc/mc/dpmng.c:7:
/usr/aarch64-linux-gnu/usr/include/libio.h:21:2: error:
  #warning "<libio.h> is deprecated; use <stdio.h> instead." [-Werror=cpp]

Fixes: 3af733ba8da8 ("bus/fslmc: introduce MC object functions")
Cc: stable@dpdk.org
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
6 years agoapp/testpmd: rework simple forward config
Matan Azrad [Mon, 5 Feb 2018 14:09:23 +0000 (14:09 +0000)]
app/testpmd: rework simple forward config

A new function was added to get a Tx port index as a function of the
topology mode and the Rx port index.

Use this function to get the Tx port index of simple stream.

Signed-off-by: Matan Azrad <matan@mellanox.com>
6 years agoapp/testpmd: fix port topology in RSS forward config
Matan Azrad [Mon, 5 Feb 2018 14:09:22 +0000 (14:09 +0000)]
app/testpmd: fix port topology in RSS forward config

The testpmd user can configure port topology mode to define the port
topology between the testpmd forward ports(paired, chained and loop).

When multi-queue ports are configured by the user, the testpmd
streams are created by rss_fwd_config_setup() function, this function
doesn't take into account the chained topology mode and configures the
forward streams with paired topology mode in this case.

Configure the stream Tx port by dedicated function which calculates
a valid Tx port index as a function of the topology mode and the Rx
port index.

Fixes: af75078 ("first public release")
Cc: stable@dpdk.org
Signed-off-by: Matan Azrad <matan@mellanox.com>
6 years agoapp/testpmd: fix port index in RSS forward config
Matan Azrad [Mon, 5 Feb 2018 14:09:21 +0000 (14:09 +0000)]
app/testpmd: fix port index in RSS forward config

When multi-queue ports are configured by the user, the testpmd streams
are created by rss_fwd_config_setup() function.

This function may configure to the streams either invalid Rx ports or
invalid Tx ports.

An invalid Tx port is configured when the number of ports is odd.
In this case, the last Tx port will be always invalid.

An invalid Rx port is configured when NUMA support is configured by the
user and the number of forward ports is much smaller than the number of
all ports. In this case, also the Tx port is invalid.

Change calculations to get valid ports.

Fixes: af75078 ("first public release")
Cc: stable@dpdk.org
Signed-off-by: Matan Azrad <matan@mellanox.com>
6 years agodoc: fix release note for rawdev library
Shreyansh Jain [Thu, 1 Feb 2018 10:19:22 +0000 (15:49 +0530)]
doc: fix release note for rawdev library

'+' sign was missing from librawdev library which is added
in this release.

Fixes: a9bb0c44c775 ("doc: add rawdev library guide and doxygen page")

Signed-off-by: Shreyansh Jain <shreyansh.jain@nxp.com>
Acked-by: Marko Kovacevic <marko.kovacevic@intel.com>
6 years agoraw/skeleton: fix device start test
Shreyansh Jain [Tue, 6 Feb 2018 06:43:38 +0000 (12:13 +0530)]
raw/skeleton: fix device start test

Device can only be started if firmware is loaded, as per Skeleton
rawdev driver semantics. This patch fixes original implementation
which attempted to start the device without loading firmware.

Fixes: 55ca1b0f2151 ("raw/skeleton: add test cases")
Cc: shreyansh.jain@nxp.com
Signed-off-by: Shreyansh Jain <shreyansh.jain@nxp.com>
6 years agobuild: add more implementers IDs and PNs for ARM
Herbert Guan [Wed, 31 Jan 2018 07:39:19 +0000 (15:39 +0800)]
build: add more implementers IDs and PNs for ARM

1) Add native PN option '-march=native' to allow automatic detection.
   Set 'arm_force_native_march' to 'true' in config/arm/meson.build
   to use native PN option.
2) Add implementer_pn option for part num selection in cross compile
3) Add known Arm cortex PN support
4) Add known implementers' IDs (use generic flags/archs by default)
5) Sync build options with config/common_armv8a_linuxapp

Signed-off-by: Herbert Guan <herbert.guan@arm.com>
Acked-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
6 years agodoc: update flow filtering example guide
Wei Zhao [Wed, 31 Jan 2018 02:12:27 +0000 (10:12 +0800)]
doc: update flow filtering example guide

This patch updates the user guidance of example application of
flow_filtering, with more details of Tx queues configuration.

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Reviewed-by: Ori Kam <orika@mellanox.com>
6 years agonet/mlx5: fix UAR remapping on non configured queues
Nélio Laranjeiro [Tue, 6 Feb 2018 09:26:21 +0000 (10:26 +0100)]
net/mlx5: fix UAR remapping on non configured queues

priv_tx_uar_remap() is wrongly considering the queue is already configured
and thus present in the queue array of the device.

Fixes: f8b9a3bad467 ("net/mlx5: install a socket to exchange a file descriptor")
Cc: stable@dpdk.org
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
6 years agonet/mlx5: fix flow RSS configuration
Nélio Laranjeiro [Tue, 6 Feb 2018 09:22:15 +0000 (10:22 +0100)]
net/mlx5: fix flow RSS configuration

An RSS configuration without a key is valid according to the
rte_eth_rss_conf API definition.

Fixes: 8086cf08b2f0 ("net/mlx5: handle RSS hash configuration in RSS flow")
Cc: stable@dpdk.org
Reported-by: Yuanhan Liu <yliu@fridaylinux.org>
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
6 years agonet/mlx: make rdma-core glue path configurable
Adrien Mazarguil [Fri, 2 Feb 2018 16:46:18 +0000 (17:46 +0100)]
net/mlx: make rdma-core glue path configurable

Since rdma-core glue libraries are intrinsically tied to their respective
PMDs and used as internal plug-ins, their presence in the default search
path among other system libraries for the dynamic linker is not necessarily
desired.

This commit enables their installation and subsequent look-up at run time
in RTE_EAL_PMD_PATH if configured to a nonempty string. This path can also
be overridden by environment variables MLX[45]_GLUE_PATH.

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/mlx: version rdma-core glue libraries
Adrien Mazarguil [Fri, 2 Feb 2018 16:46:16 +0000 (17:46 +0100)]
net/mlx: version rdma-core glue libraries

When built as separate objects, these libraries do not have unique names.
Since they do not maintain a stable ABI, loading an incompatible library
may result in a crash (e.g. in case multiple versions are installed).

This patch addresses the above by versioning glue libraries, both on the
file system (version suffix) and by comparing a dedicated version field
member in glue structures.

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/mlx: fix missing includes for rdma-core glue
Adrien Mazarguil [Fri, 2 Feb 2018 16:46:14 +0000 (17:46 +0100)]
net/mlx: fix missing includes for rdma-core glue

For consistency since these includes are already pulled by others.

Fixes: 4eba244b78ec ("net/mlx4: move rdma-core calls to separate file")
Fixes: 0e83b8e536c1 ("net/mlx5: move rdma-core calls to separate file")

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/mlx: add debug checks to glue structure
Adrien Mazarguil [Fri, 2 Feb 2018 16:46:12 +0000 (17:46 +0100)]
net/mlx: add debug checks to glue structure

This code should catch mistakes early if a glue structure member is added
without a corresponding implementation in the library.

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/bnxt: fix missing timestamp flag in mbuf
Somnath Kotur [Tue, 6 Feb 2018 02:52:03 +0000 (08:22 +0530)]
net/bnxt: fix missing timestamp flag in mbuf

The timestamp flag needs to be set in the offload flags
for the received pkt in case of PTP offload.

Fixes: b11cceb83a34 ("net/bnxt: support timesync")

Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
6 years agonet/mlx4: fix Rx offload non-fragmented indication
Moti Haimovsky [Tue, 30 Jan 2018 17:02:51 +0000 (19:02 +0200)]
net/mlx4: fix Rx offload non-fragmented indication

This patch fixes the missing RTE_PTYPE_L4_NONFRAG on non-fragmented
IP packets with unrecognized payload type.

Fixes: aee4a03fee4f ("net/mlx4: enhance Rx packet type offloads")
Cc: stable@dpdk.org
Signed-off-by: Moti Haimovsky <motih@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/virtio: fix crash while freeing mbufs
David Harton [Sat, 3 Feb 2018 14:55:23 +0000 (09:55 -0500)]
net/virtio: fix crash while freeing mbufs

virtio_dev_free_mbufs was recently modified to free the
virtqueues but failed to check whether the array was
allocated.  Added a check to ensure vqs was non-null.

Fixes: bdb32afbb610 ("net/virtio: rationalize queue flushing")

Signed-off-by: David Harton <dharton@cisco.com>
Reviewed-by: Olivier Matz <olivier.matz@6wind.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
6 years agodoc: remove TUN from TAP PMD guide
Vipin Varghese [Tue, 23 Jan 2018 14:29:26 +0000 (14:29 +0000)]
doc: remove TUN from TAP PMD guide

TUN PMD is not supported, removing the references
from Network Interface Controller Driver Tun/Tap
Poll Mode Driver section

Signed-off-by: Vipin Varghese <vipin.varghese@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
6 years agonet/tap: fix eBPF handling of non-RSS flows
Ophir Munk [Mon, 5 Feb 2018 14:40:42 +0000 (14:40 +0000)]
net/tap: fix eBPF handling of non-RSS flows

The eBPF classifier (section "cls_q" in tap_bpf_program.c) is tracing
marked packets in which skb->cb[1] contains an RSS queue number, and
redirects those packets to the matched queue.
It is expected that skb->cb[1] has been previously set with a valid RSS
queue number during an eBPF action (section "l3_l4" in tap_bpf_program.c).
However, for non-RSS flows, skb->cb[1] may contain a random unset value,
which could falsely be interpreted as a valid RSS queue.
To avoid this potential error, tap_bpf_program.c has been updated as
follows:
1. After calculating the RSS queue number, it is added a unique offset in
order to uniquely identify it as a valid RSS queue number.
2. After matching an RSS queue to a packet, skb->cb[1] is set to 0.

Fixes: cdc07e83bb24 ("net/tap: add eBPF program file")
Fixes: aabe70df73a3 ("net/tap: add eBPF bytes code")

Signed-off-by: Ophir Munk <ophirmu@mellanox.com>
Acked-by: Pascal Mazon <pascal.mazon@6wind.com>
6 years agonet/tap: fix multi segments capability
Ophir Munk [Mon, 5 Feb 2018 10:59:08 +0000 (10:59 +0000)]
net/tap: fix multi segments capability

TAP device is supporting multi segments Tx, however this capability is
not reported when querying the TAP device.
This commit adds this capability report.

Fixes: 818fe14a9891 ("net/tap: use new Tx offloads API")
Cc: stable@dpdk.org
Signed-off-by: Ophir Munk <ophirmu@mellanox.com>
Acked-by: Pascal Mazon <pascal.mazon@6wind.com>
6 years agovhost: remove pending IOTLB entry if miss request failed
Maxime Coquelin [Mon, 5 Feb 2018 15:04:57 +0000 (16:04 +0100)]
vhost: remove pending IOTLB entry if miss request failed

In case vhost_user_iotlb_miss returns an error, the pending IOTLB
entry has to be removed from the list as no IOTLB update will be
received.

Fixes: fed67a20ac94 ("vhost: introduce guest IOVA to backend VA helper")
Cc: stable@dpdk.org
Suggested-by: Tiwei Bie <tiwei.bie@intel.com>
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
6 years agovhost: fix IOTLB pool out-of-memory handling
Maxime Coquelin [Mon, 5 Feb 2018 15:04:56 +0000 (16:04 +0100)]
vhost: fix IOTLB pool out-of-memory handling

In the unlikely case the IOTLB memory pool runs out of memory,
an issue may happen if all entries are used by the IOTLB cache,
and an IOTLB miss happen. If the iotlb pending list is empty,
then no memory is freed and allocation fails a second time.

This patch fixes this by doing an IOTLB cache random evict if
the IOTLB pending list is empty, ensuring the second allocation
try will succeed.

In the same spirit, the opposite is done when inserting an
IOTLB entry in the IOTLB cache fails due to out of memory. In
this case, the IOTLB pending is flushed if the IOTLB cache is
empty to ensure the new entry can be inserted.

Fixes: d012d1f293f4 ("vhost: add IOTLB helper functions")
Fixes: f72c2ad63aeb ("vhost: add pending IOTLB miss request list and helpers")
Cc: stable@dpdk.org
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
6 years agodoc: update mlx required OFED version
Shahaf Shuler [Mon, 5 Feb 2018 12:31:12 +0000 (14:31 +0200)]
doc: update mlx required OFED version

Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agodoc: update mlx PMD release notes
Shahaf Shuler [Mon, 5 Feb 2018 12:31:11 +0000 (14:31 +0200)]
doc: update mlx PMD release notes

Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/failsafe: fix default Tx offloads capabilities
Ophir Munk [Mon, 5 Feb 2018 16:02:06 +0000 (16:02 +0000)]
net/failsafe: fix default Tx offloads capabilities

Failsafe reported Tx offloads capabilities are the AND result of its
default capabilities and those of its sub-devices.
In the corrupted code failsafe default Tx capabilities were set to 0.
As a result when running testpmd with "--tx-offloads=0x8000" parameter
(request for multi segments offload) - an error was returned:

PMD: net_failsafe:
Some Tx offloads are not supported, requested 0x8000 supported 0x0

To fix this, failsafe default Tx offload capabilities are set to
DEV_TX_OFFLOAD_MULTI_SEGS |
DEV_TX_OFFLOAD_IPV4_CKSUM |
DEV_TX_OFFLOAD_UDP_CKSUM |
DEV_TX_OFFLOAD_TCP_CKSUM,

Fixes: a46f8d584eb8 ("net/failsafe: add fail-safe PMD")
Cc: stable@dpdk.org
Signed-off-by: Ophir Munk <ophirmu@mellanox.com>
Acked-by: Gaetan Rivet <gaetan.rivet@6wind.com>
6 years agonet/vdev_netvsc: fix device detection error check
Matan Azrad [Mon, 5 Feb 2018 12:48:22 +0000 (12:48 +0000)]
net/vdev_netvsc: fix device detection error check

The vdev_netvsc driver does periodic detection of PCI devices matched
to the netvsc existed interfaces.

When it finds a match, the PCI address is written to the pipe of the
associated fail-safe PMD instance and a positive value is returned to
the periodic check which is wrongly considered as error.

Change the check to consider only a negative value as error.

Fixes: e7dc5d7becc5 ("net/vdev_netvsc: implement core functionality")

Signed-off-by: Matan Azrad <matan@mellanox.com>
6 years agodoc: align qede dynamic log names with standard
Rasesh Mody [Sat, 3 Feb 2018 06:03:19 +0000 (22:03 -0800)]
doc: align qede dynamic log names with standard

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede: fix few log messages
Rasesh Mody [Sat, 3 Feb 2018 06:03:18 +0000 (22:03 -0800)]
net/qede: fix few log messages

Fixes: 9e334305178f ("net/qede: fix MTU set and max Rx length")
Fixes: 22d07d939c3c ("net/qede/base: update")
Cc: stable@dpdk.org
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede: fix VF port creation sequence
Harish Patil [Sat, 3 Feb 2018 06:03:17 +0000 (22:03 -0800)]
net/qede: fix VF port creation sequence

Few adjustments are required to effectively handle VF vport create/delete
sequence. The problem is exposed by recent ethdev TX offload changes
which requires port to be in down state before applying TX offloads.

 - Move vport creation from dev_init() to dev_configure()
 - Force to stop vport if it was already started due to previous run
   (restart case)
 - Move link state enable/disable to dev_init() and dev_close()
   respectively.
 - For MTU change, recreate vport with new MTU value and restore old
   config. This is necessary since VF MTU value can be changed only upon
   vport creation.

Fixes: ec94dbc57362 ("qede: add base driver")
Cc: stable@dpdk.org
Signed-off-by: Harish Patil <harish.patil@cavium.com>
6 years agonet/octeontx: register fpa as platform HW mempool
Pavan Nikhilesh [Mon, 5 Feb 2018 10:55:57 +0000 (16:25 +0530)]
net/octeontx: register fpa as platform HW mempool

Register octeontx-fpavf as platform HW mempool when net/octeontx pmd is
used.

Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
6 years agonet/bonding: check error of MAC address setting
Radu Nicolau [Thu, 1 Feb 2018 17:21:26 +0000 (17:21 +0000)]
net/bonding: check error of MAC address setting

Coverity issue: 260405
Fixes: 2efb58cbab6e ("bond: new link bonding library")
Cc: stable@dpdk.org
Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
6 years agonet/ena: fix jumbo support in Rx offloads flags
Rafal Kozik [Thu, 1 Feb 2018 13:06:36 +0000 (14:06 +0100)]
net/ena: fix jumbo support in Rx offloads flags

ENA device supports Rx jumbo frames and such information needs to
be provided in the offloads flags.

Fixes: 7369f88f88c0 ("net/ena: convert to new Rx offloads API")

Signed-off-by: Rafal Kozik <rk@semihalf.com>
Acked-by: Michal Krawczyk <mk@semihalf.com>
6 years agonet/failsafe: fix error string after ownership call
Gaetan Rivet [Thu, 1 Feb 2018 10:59:30 +0000 (11:59 +0100)]
net/failsafe: fix error string after ownership call

Ownership API returns a negative value, strerror expects a valid errno
value, thus positive.

Coverity issue: 260401
Fixes: dcd0c9c32b8d ("net/failsafe: use ownership mechanism for slaves")

Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
6 years agotest/bonding: assign non-zero MAC to null devices
Radu Nicolau [Thu, 1 Feb 2018 11:06:18 +0000 (11:06 +0000)]
test/bonding: assign non-zero MAC to null devices

Prevent failure in rte_eth_dev_default_mac_addr_set() that
results in bonding add slave failure.

Fixes: aa7791ba8de0 ("net/bonding: fix setting slave MAC addresses")

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
6 years agotest/virtual_pmd: add MAC address setting fake op
Radu Nicolau [Thu, 1 Feb 2018 10:48:57 +0000 (10:48 +0000)]
test/virtual_pmd: add MAC address setting fake op

Needed if used with net/bonding

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
6 years agonet/null: add MAC address setting fake operation
Radu Nicolau [Thu, 1 Feb 2018 10:47:07 +0000 (10:47 +0000)]
net/null: add MAC address setting fake operation

Needed if used with net/bonding

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
6 years agoexamples/vhost_scsi: drop unimplemented event index feature
Stefan Hajnoczi [Wed, 31 Jan 2018 17:48:28 +0000 (17:48 +0000)]
examples/vhost_scsi: drop unimplemented event index feature

The vhost_scsi example application negotiates the
VIRTIO_RING_F_EVENT_IDX feature bit but does not honor it when accessing
vrings.

In particular, commit e37ff954405addb8ea422426a2d162d00dcad196 ("vhost:
support virtqueue interrupt/notification suppression") broke vring call
because vq->last_used_idx is never updated by vhost_scsi.  The
vq->last_used_idx field is not even available via the librte_vhost
public API, so VIRTIO_RING_F_EVENT_IDX is currently only usable by the
built-in virtio_net.c driver in librte_vhost.

This patch drops VIRTIO_RING_F_EVENT_IDX from vhost_scsi so that vring
call works again.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Acked-by: Yuanhan Liu <yliu@fridaylinux.org>
6 years agovhost: drop virtqueues only with built-in virtio driver
Stefan Hajnoczi [Wed, 31 Jan 2018 17:46:51 +0000 (17:46 +0000)]
vhost: drop virtqueues only with built-in virtio driver

Commit e29109323595beb3884da58126ebb3b878cb66f5 ("vhost: destroy unused
virtqueues when multiqueue not negotiated") broke vhost-scsi by removing
virtqueues when the virtio-net-specific VIRTIO_NET_F_MQ feature bit is
missing.

The vhost_user.c code shouldn't assume all devices are vhost net device
backends.  Use the new VIRTIO_DEV_BUILTIN_VIRTIO_NET flag to check
whether virtio_net.c is being used.

This fixes examples/vhost_scsi.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Acked-by: Yuanhan Liu <yliu@fridaylinux.org>
6 years agovhost: add flag for built-in virtio driver
Stefan Hajnoczi [Wed, 31 Jan 2018 17:46:50 +0000 (17:46 +0000)]
vhost: add flag for built-in virtio driver

The librte_vhost API is used in two ways:
1. As a vhost net device backend via rte_vhost_enqueue/dequeue_burst().
2. As a library for implementing vhost device backends.

There is no distinction between the two at the API level or in the
librte_vhost implementation.  For example, device state is kept in
"struct virtio_net" regardless of whether this is actually a net device
backend or whether the built-in virtio_net.c driver is in use.

The virtio_net.c driver should be a librte_vhost API client just like
the vhost-scsi code and have no special access to vhost.h internals.
Unfortunately, fixing this requires significant librte_vhost API
changes.

This patch takes a different approach: keep the librte_vhost API
unchanged but track whether the built-in virtio_net.c driver is in use.
See the next patch for a bug fix that requires knowledge of whether
virtio_net.c is in use.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Acked-by: Yuanhan Liu <yliu@fridaylinux.org>
6 years agonet/mlx5: fix CRC strip capability query
Shahaf Shuler [Thu, 1 Feb 2018 18:53:53 +0000 (20:53 +0200)]
net/mlx5: fix CRC strip capability query

IBV_WQ_FLAGS_SCATTER_FCS is a WQ flag to be used to configure the CRC
strip on a queue upon creation.

Using IBV_RAW_PACKET_CAP_SCATTER_FCS instead to query to capability.
Even though this is RAW_QP capability, it is being used by rdma-core to
indicate for both RAW_QP and WQ.

Fixes: 43e9d9794cde ("net/mlx5: support upstream rdma-core")
Cc: stable@dpdk.org
Reported-by: Alex Rosenbaum <alexr@mellanox.com>
Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
Acked-by: Yongseok Koh <yskoh@mellanox.com>
6 years agonet/mlx5: fix flow priority on queue action
Nélio Laranjeiro [Wed, 31 Jan 2018 16:13:54 +0000 (17:13 +0100)]
net/mlx5: fix flow priority on queue action

A single queue should have the same verbs priority as an RSS one.

Fixes: 8086cf08b2f0 ("net/mlx5: handle RSS hash configuration in RSS flow")
Cc: stable@dpdk.org
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Yongseok Koh <yskoh@mellanox.com>
6 years agonet/mlx5: fix port stop by verify flows are still present
Nélio Laranjeiro [Tue, 30 Jan 2018 13:36:52 +0000 (14:36 +0100)]
net/mlx5: fix port stop by verify flows are still present

priv_flow_stop() may be called several times, in such situation flows are
already removed from the NIC and thus all associated objects are no present
in the flow object (ibv_flow, indirection tables, ....).

Fixes: 8086cf08b2f0 ("net/mlx5: handle RSS hash configuration in RSS flow")
Cc: stable@dpdk.org
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
6 years agonet/mlx4: fix drop flow resources leak
Adrien Mazarguil [Wed, 31 Jan 2018 15:33:06 +0000 (16:33 +0100)]
net/mlx4: fix drop flow resources leak

Resources allocated for drop flow rules are not freed properly. This causes
a memory leak and triggers an assertion failure on a reference counter when
compiled in debug mode.

This issue can be reproduced with testpmd by entering the following
commands:

 flow create 0 ingress pattern eth / end actions drop / end
 port start all
 port stop all
 port start all
 port stop all
 quit

The reason is additional references are taken when re-enabling existing
flow rules, a common occurrence when rehashing configuration.

Fixes: d3a7e09234e4 ("net/mlx4: allocate drop flow resources on demand")
Cc: stable@dpdk.org
Reported-by: Moti Haimovsky <motih@mellanox.com>
Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agodoc: fix DDP usage in testpmd
Kirill Rybalchenko [Wed, 31 Jan 2018 11:15:06 +0000 (11:15 +0000)]
doc: fix DDP usage in testpmd

Documentation and help string more clear describe meaning of
arguments for DDP add del function.

Fixes: 856ceb331b0a ("app/testpmd: enable DDP remove profile feature")
Cc: stable@dpdk.org
Signed-off-by: Kirill Rybalchenko <kirill.rybalchenko@intel.com>
Acked-by: John McNamara <john.mcnamara@intel.com>
6 years agonet/i40e: fix interrupt conflict with multi-driver
Beilei Xing [Fri, 2 Feb 2018 12:05:52 +0000 (20:05 +0800)]
net/i40e: fix interrupt conflict with multi-driver

There's interrupt conflict when using DPDK and Linux i40e
on different ports of the same Ethernet controller, this
patch fixes it by switching from IntN to Int0 if multiple
drivers are used.

Fixes: be6c228d4da3 ("i40e: support Rx interrupt")
Cc: stable@dpdk.org
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
6 years agonet/i40e: fix multiple driver support
Beilei Xing [Fri, 2 Feb 2018 12:05:51 +0000 (20:05 +0800)]
net/i40e: fix multiple driver support

This patch provides the option to disable writing some global registers
in PMD, in order to avoid affecting other drivers, when multiple drivers
run on the same NIC and control different physical ports. Because there
are few global resources shared among different physical ports.

Fixes: ec246eeb5da1 ("i40e: use default filter input set on init")
Fixes: 98f055707685 ("i40e: configure input fields for RSS or flow director")
Fixes: f05ec7d77e41 ("i40e: initialize flow director flexible payload setting")
Fixes: e536c2e32883 ("net/i40e: fix parsing QinQ packets type")
Fixes: 19b16e2f6442 ("ethdev: add vlan type when setting ether type")
Cc: stable@dpdk.org
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
6 years agonet/i40e: add debug logs when writing global registers
Beilei Xing [Fri, 2 Feb 2018 12:05:50 +0000 (20:05 +0800)]
net/i40e: add debug logs when writing global registers

Add debug logs when writing global registers.

Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
6 years agonet/i40e: warn when writing global registers
Beilei Xing [Fri, 2 Feb 2018 12:05:49 +0000 (20:05 +0800)]
net/i40e: warn when writing global registers

Add warnings when writing global registers.

Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
6 years agonet/i40e: fix CRC strip enabling
Xiaoyun Li [Fri, 2 Feb 2018 05:45:16 +0000 (13:45 +0800)]
net/i40e: fix CRC strip enabling

New testpmd will get CRC strip offload from rx_offload_capa. I40evf
cannot disable CRC strip. And in fact, it is enabled by PF. This
patch solves the issue by adding CRC strip flag into rx_offload_capa
in i40e and i40evf.

Fixes: 8b9bd0efe0b6 ("app/testpmd: disable Rx VLAN offloads by default")

Signed-off-by: Xiaoyun Li <xiaoyun.li@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
6 years agonet/i40e: update Rx checksum offload
Beilei Xing [Wed, 31 Jan 2018 03:34:13 +0000 (11:34 +0800)]
net/i40e: update Rx checksum offload

HW supports outer IP Rx checksum offload, this patch updates Rx
checksum offload for both PF and VF.

Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
6 years agonet/sfc: support meson build
Ivan Malov [Sat, 3 Feb 2018 13:46:34 +0000 (13:46 +0000)]
net/sfc: support meson build

Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
6 years agonet/sfc: rename version map file
Ivan Malov [Sat, 3 Feb 2018 13:46:33 +0000 (13:46 +0000)]
net/sfc: rename version map file

The version map filename does not comply with the format
used by meson build rules for drivers (i.e. on the upper
level) and needs to be revisited. This patch removes efx
postfix from the driver title in the filename.

Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
6 years agotest/kni: fix dependency for BSD meson build
Bruce Richardson [Thu, 1 Feb 2018 14:20:11 +0000 (14:20 +0000)]
test/kni: fix dependency for BSD meson build

The KNI library is not built on FreeBSD, so it needs to be an
optional rather than a mandatory dependency for building the autotest
binary.

Fixes: b5dc795a8a55 ("test: build app with meson as dpdk-test")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
6 years agotest/power: fix dependency for BSD meson build
Bruce Richardson [Thu, 1 Feb 2018 14:20:10 +0000 (14:20 +0000)]
test/power: fix dependency for BSD meson build

The power library is not built on FreeBSD, so it needs to be an
optional rather than a mandatory dependency for building the autotest
binary.

Fixes: b5dc795a8a55 ("test: build app with meson as dpdk-test")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
6 years agotest: skip when required lib not available
Bruce Richardson [Thu, 1 Feb 2018 14:20:09 +0000 (14:20 +0000)]
test: skip when required lib not available

The power management and KNI libraries are not compiled on a FreeBSD
platform, which means that the tests can't run. Add in stub code for
these cases, allowing the tests to still be compiled, but to report
as skipped in those cases.

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: David Hunt <david.hunt@intel.com>
6 years agobuild: fix dependency on execinfo for BSD meson builds
Bruce Richardson [Thu, 1 Feb 2018 14:20:08 +0000 (14:20 +0000)]
build: fix dependency on execinfo for BSD meson builds

The binaries and apps in DPDK all need to be linked against the
execinfo library on FreeBSD so add this as a dependency in cases
where it is found. It's available by default on BSD, but not
at all on Linux

Fixes: 16ade738fd0d ("app/testpmd: build with meson")
Fixes: 89f0711f9ddf ("examples: build some samples with meson")
Fixes: b5dc795a8a55 ("test: build app with meson as dpdk-test")
Fixes: 2ff67267b049 ("app/eventdev: build with meson")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
6 years agoeal/bsd: fix kernel modules build with meson
Bruce Richardson [Thu, 1 Feb 2018 14:20:07 +0000 (14:20 +0000)]
eal/bsd: fix kernel modules build with meson

The kernel module source file directory passed via VPATH was wrong,
which caused the source files to be not found via make. Rather than
explicitly passing VPATH, make use of the fact that the full path
to the source files is passed by meson, so split that into directory
part - to be used as VPATH - and file part - to be used as the source
filename.

Fixes: 610beca42ea4 ("build: remove library special cases")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
6 years agonet/i40e: fix dependencies for AVX2 build with meson
Bruce Richardson [Wed, 31 Jan 2018 17:09:05 +0000 (17:09 +0000)]
net/i40e: fix dependencies for AVX2 build with meson

The AVX2 code path includes files from the ethdev, hash and kvargs libs.
These are not listed as dependencies in the case where AVX2 is not in
the default instruction set for the build e.g. machine=nehalem. This
leads to compiler errors as the header files needed cannot be found.

Fixes: e940646b20fa ("drivers/net: build Intel NIC PMDs with meson")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
6 years agousertools/devbind: fix kernel module reporting
Anatoly Burakov [Wed, 24 Jan 2018 10:26:12 +0000 (10:26 +0000)]
usertools/devbind: fix kernel module reporting

lspci reports kernel modules in "Module" string, but devbind
expects it to be "Module_str". Fix it up similar to how we fix
up "Driver" to be "Driver_str".

Fixes: c3ce205d5729 ("usertools: optimize lspci invocation")
Cc: stable@dpdk.org
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
6 years agousertools/devbind: remove unused function
Anatoly Burakov [Wed, 24 Jan 2018 13:16:06 +0000 (13:16 +0000)]
usertools/devbind: remove unused function

Fixes: 629395b063e8 ("igb_uio: remove PCI id table")
Cc: stable@dpdk.org
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
6 years agotest/mempool: get best pool via the new API
Hemant Agrawal [Mon, 5 Feb 2018 07:43:11 +0000 (13:13 +0530)]
test/mempool: get best pool via the new API

This patch replaces the uses of default mempool ops API
with newly supported best_mempool_ops API.

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
6 years agotest/memzone: handle previously allocated memzones
Anatoly Burakov [Thu, 1 Feb 2018 10:14:50 +0000 (10:14 +0000)]
test/memzone: handle previously allocated memzones

Currently, memzone autotest expects there to be no memzones
present by the time the test is run. Some hardware drivers
will allocate memzones for internal use during initialization,
resulting in tests failing due to unexpected memzones being
allocated before the test was run.

Fix this by making sure all memzones allocated by this test
have a common prefix, and making callback increment a counter
on encountering memzones with this prefix. Also, separately
increment another counter that will count total number of
memzones left after test, and compares it to previously stored
number of memzones, to ensure that we didn't accidentally
allocated/freed any memzones we weren't supposed to. This
also doubles as a test for correct operation of memzone_walk().

Fixes: 71330483a193 ("test/memzone: fix memory leak")
Cc: stable@dpdk.org
Signed-off-by: Phil Yang <phil.yang@arm.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Reviewed-by: Radoslaw Biernacki <radoslaw.biernacki@linaro.org>
6 years agotest/memzone: add test for count in EAL config
Anatoly Burakov [Thu, 1 Feb 2018 10:14:49 +0000 (10:14 +0000)]
test/memzone: add test for count in EAL config

Ensure that memzone count in eal mem config is incremented and
decremented whenever memzones are allocated and freed.

Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Reviewed-by: Radoslaw Biernacki <radoslaw.biernacki@linaro.org>
6 years agotest: clean up memory for function reentrancy test
Anatoly Burakov [Wed, 31 Jan 2018 14:17:32 +0000 (14:17 +0000)]
test: clean up memory for function reentrancy test

Function reentrancy test limits maximum number of iterations based
on the number of memzones and cores, however it doesn't free the
memzones after the fact, so on a machine with big amount of cores
the tests will fail due to running out of memzones.

Fix this by introducing cleanup functions for ring and mempool
reentrancy tests.

Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
6 years agopmdinfogen: fix resource leak of file object
Bruce Richardson [Fri, 2 Feb 2018 12:00:58 +0000 (12:00 +0000)]
pmdinfogen: fix resource leak of file object

Coverity flags an issue where the resources used by the FILE object for
the temporary input file are leaked. This is a very minor issue, but is
easily fixed, while also avoiding later problems where we try to close
an invalid file descriptor in the failure case.

The fix is to use "dup()" to get a new file descriptor number rather than
using the value directly from fileno. This allows us to close the file
opened with tmpfile() within in scope block, while allowing the duplicate
to pass to the outer block and be closed when the function terminates.

As a side-effect I/O in the function is therefore changed from using stdio
fread/fwrite to read/write system calls.

Coverity issue: 260399
Fixes: 0d68533617e3 ("pmdinfogen: allow using stdin and stdout")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
6 years agombuf: fix logic of user mempool ops API
Nipun Gupta [Fri, 2 Feb 2018 08:03:01 +0000 (13:33 +0530)]
mbuf: fix logic of user mempool ops API

The existing rte_eal_mbuf_default mempool ops can return the compile time
default ops name if the user has not provided command line inputs for
mempool ops name. It will break the logic of best mempool ops as it will
never return platform hw mempool ops.

This patch introduces a new API to just return the user mempool ops only.

Fixes: 8b0f7f434132 ("mbuf: maintain user and compile time mempool ops name")

Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
6 years agomempool: fix physical contiguous check
Andrew Rybchenko [Thu, 1 Feb 2018 14:02:23 +0000 (14:02 +0000)]
mempool: fix physical contiguous check

There is not specified dependency between rte_mempool_populate_default()
and rte_mempool_populate_iova(). So, the second should not rely on the
fact that the first adds capability flags to the mempool flags.

Fixes: 65cf769f5e6a ("mempool: detect physical contiguous objects")
Cc: stable@dpdk.org
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Acked-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
6 years agoevent/dpaa: fix portal allocation
Nipun Gupta [Mon, 5 Feb 2018 05:21:57 +0000 (10:51 +0530)]
event/dpaa: fix portal allocation

Checking if portal has been allocated is now required at the
caller of rte_dpaa_portal_init() API. This patch adds check
in the dpaa eventdev driver.

Fixes: 5d944582d028 ("bus/dpaa: check portal presence in the caller function")

Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
6 years agoevent/dpaa: rename vdev with dpaa1
Nipun Gupta [Mon, 5 Feb 2018 05:21:56 +0000 (10:51 +0530)]
event/dpaa: rename vdev with dpaa1

DPAA2 eventdev is named as event_dpaa2 which conflicts with
event_dpaa when both are compiled in together. So event_dpaa
is required to renamed.

Fixes: 1ee9569576f6 ("config: enable dpaaX drivers for generic ARMv8")

Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
6 years agobus/dpaa: fix mempool ops registration
Nipun Gupta [Mon, 5 Feb 2018 05:21:55 +0000 (10:51 +0530)]
bus/dpaa: fix mempool ops registration

Fixes: 2bd0d5b951a9 ("bus/dpaa: register platform HW mempool on runtime")

Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Acked-by: Shreyansh Jain <Shreyansh.jain@nxp.com>
6 years agobus/fslmc: fix mempool ops registration
Nipun Gupta [Mon, 5 Feb 2018 05:21:54 +0000 (10:51 +0530)]
bus/fslmc: fix mempool ops registration

Fixes: 8824b74d8f5f ("bus/fslmc: register platform HW mempool on runtime")

Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Shreyansh Jain <shreyansh.jain@nxp.com>
6 years agobus/vdev: continue probing after a device failure
Moti Haimovsky [Mon, 5 Feb 2018 17:15:03 +0000 (19:15 +0200)]
bus/vdev: continue probing after a device failure

This commit modifies vdev_probe to continue probing all the devices
regardless of device probing failures.

Cc: stable@dpdk.org
Signed-off-by: Moti Haimovsky <motih@mellanox.com>
6 years agoeal: add error check for core options
Marko Kovacevic [Fri, 2 Feb 2018 14:51:28 +0000 (14:51 +0000)]
eal: add error check for core options

Error information on current core usage list, mask or map
were incomplete. Added states to differentiate core usage
and to inform user.

Signed-off-by: Marko Kovacevic <marko.kovacevic@intel.com>
Reviewed-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
6 years agoigb_uio: print IRQ as decimal number
Tonghao Zhang [Tue, 23 Jan 2018 16:17:34 +0000 (08:17 -0800)]
igb_uio: print IRQ as decimal number

The kernel uses the '%d' or '%ld' to print irq num.
But igb_uio may use the '%lx', then the log may confuse
the user what irq num has been used. The log is show as
below.

igb_uio 0000:00:03.0: irq 24 for MSI/MSI-X
igb_uio 0000:00:03.0: uio device registered with irq 18

kernel version: 3.10.0-514.16.1.el7

For avoiding to be confused, change the igb_uio irq
print type.

Signed-off-by: Tonghao Zhang <xiangxia.m.yue@gmail.com>
6 years agomk: fix external build
Marko Kovacevic [Mon, 5 Feb 2018 15:45:31 +0000 (15:45 +0000)]
mk: fix external build

Code commit for 'make -f' support, breaks the build in cases where
entries in $(MAKEFILE_LIST) are absolute paths. This commit uses
notdir and firstword to ensure that only the local filename is used.

Fixes: 3a5c339d51a4 ("mk: support renamed Makefile in external project")
Cc: stable@dpdk.org
Signed-off-by: Marko Kovacevic <marko.kovacevic@intel.com>
6 years agonet/tap: fix icc build
Zhiyong Yang [Thu, 1 Feb 2018 04:43:00 +0000 (12:43 +0800)]
net/tap: fix icc build

The following error is reported when compiling 18.02-rc2 using ICC,
"transfer of control bypasses initialization of".
The patch fixes the issue.

Fixes: 1911c5edc6cd ("net/tap: fix eBPF RSS map key handling")

Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
6 years agoversion: 18.02-rc2
Thomas Monjalon [Thu, 1 Feb 2018 02:09:10 +0000 (03:09 +0100)]
version: 18.02-rc2

Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
6 years agodoc: add procinfo restriction with vdev
Marko Kovacevic [Wed, 24 Jan 2018 16:47:26 +0000 (16:47 +0000)]
doc: add procinfo restriction with vdev

Note added to outline that using
proc_info for virtual devices is not supported

Signed-off-by: Marko Kovacevic <marko.kovacevic@intel.com>
Acked-by: Deepak Kumar Jain <deepak.k.jain@intel.com>
6 years agodoc: add procinfo restriction with shared library
Vipin Varghese [Tue, 30 Jan 2018 12:17:02 +0000 (17:47 +0530)]
doc: add procinfo restriction with shared library

added note category to procinfo guide, to intimate users in shared
library mode. Procinfo requires same NIC libraries to probe the NIC
devices as Primary Application.

Signed-off-by: Vipin Varghese <vipin.varghese@intel.com>
Acked-by: Marko Kovacevic <marko.kovacevic@intel.com>
6 years agodoc: add a restriction to multi-process support
Junjie Chen [Wed, 29 Nov 2017 17:17:13 +0000 (12:17 -0500)]
doc: add a restriction to multi-process support

This patch add a restriction to multi-process support: secondary
processes should only run alongside primary process with same DPDK
version, so that secondary processes can use the same hugepage mmap
layout as primary process.

Signed-off-by: Junjie Chen <junjie.j.chen@intel.com>
Acked-by: John McNamara <john.mcnamara@intel.com>
6 years agoevent/opdl: fix license header and SPDX tags
Bruce Richardson [Tue, 23 Jan 2018 14:11:33 +0000 (14:11 +0000)]
event/opdl: fix license header and SPDX tags

This patch ensures that the OPDL files all contain correct SPDX tags.
The following changes were made to achieve this:
* replace license text with SPDX tag
* correct occurences where SPDX tag was not on first line of file
* ensure license years were correct

Fixes: 4236ce9bf5bf ("event/opdl: add OPDL ring infrastructure library")
Fixes: 3c7f3dcfb099 ("event/opdl: add PMD main body and helper function")
Fixes: d548ef513cd7 ("event/opdl: add unit tests")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Liang Ma <liang.j.ma@intel.com>
6 years agodoc: replace license text with SPDX tags on SVG images
Bruce Richardson [Tue, 23 Jan 2018 13:33:37 +0000 (13:33 +0000)]
doc: replace license text with SPDX tags on SVG images

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
6 years agoconfig: replace Intel license headers with SPDX tags
Bruce Richardson [Tue, 23 Jan 2018 14:21:16 +0000 (14:21 +0000)]
config: replace Intel license headers with SPDX tags

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
6 years agotest: use SPDX tags in 6WIND copyrighted files
Olivier Matz [Mon, 29 Jan 2018 13:11:29 +0000 (14:11 +0100)]
test: use SPDX tags in 6WIND copyrighted files

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
6 years agoapp/testpmd: use SPDX tags in 6WIND copyrighted files
Olivier Matz [Mon, 29 Jan 2018 13:11:28 +0000 (14:11 +0100)]
app/testpmd: use SPDX tags in 6WIND copyrighted files

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
6 years agonet/ixgbe: use SPDX tags in 6WIND copyrighted files
Olivier Matz [Mon, 29 Jan 2018 13:11:35 +0000 (14:11 +0100)]
net/ixgbe: use SPDX tags in 6WIND copyrighted files

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
6 years agonet/failsafe: use SPDX tags in 6WIND copyrighted files
Olivier Matz [Mon, 29 Jan 2018 13:11:34 +0000 (14:11 +0100)]
net/failsafe: use SPDX tags in 6WIND copyrighted files

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
6 years agonet/tap: use SPDX tags in 6WIND copyrighted files
Olivier Matz [Mon, 29 Jan 2018 13:11:36 +0000 (14:11 +0100)]
net/tap: use SPDX tags in 6WIND copyrighted files

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
6 years agonet/af_packet: use SPDX tags in 6WIND copyrighted files
Olivier Matz [Mon, 29 Jan 2018 13:11:33 +0000 (14:11 +0100)]
net/af_packet: use SPDX tags in 6WIND copyrighted files

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
6 years agonet/mlx4: use SPDX tags in 6WIND copyrighted files
Olivier Matz [Mon, 29 Jan 2018 13:11:31 +0000 (14:11 +0100)]
net/mlx4: use SPDX tags in 6WIND copyrighted files

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>