Wisam Jaddo [Thu, 26 Nov 2020 11:15:41 +0000 (13:15 +0200)]
app/flow-perf: add multi-core rule insertion and deletion
One of the ways to increase the insertion/deletion rate is to use
multi-threaded insertion/deletion. Thus it's needed to have support
for testing and measure those rates using flow-perf application.
Now we generate cores and distribute all flows to those cores,
and start inserting/deleting in parallel.
The app now receive the cores count to use from command line option,
then it distribute the rte_flow rules evenly between the cores, and
start inserting/deleting. Each worker will report it's own results,
and in the end the MAIN worker will report the total results for all
cores.
The total results are calculated using RULES_COUNT divided over
max time used between all cores.
Also this touches the memory area, since inserting using multiple cores
in same time the pre solution for memory is not valid, thus now we save
memory before and after each allocation for all cores. In the end we
pick the min pre memory and the max post memory from all cores.
The difference between those values represent the total memory consumed
by the total rte_flow rules from all cores, and then report the total
size of single rte_flow in byte for each port.
How to use this feature:
--cores=N
Where 1 =< N <= RTE_MAX_LCORE
Signed-off-by: Wisam Jaddo <wisamm@nvidia.com>
Reviewed-by: Alexander Kozyrev <akozyrev@nvidia.com>
Reviewed-by: Suanming Mou <suanmingm@nvidia.com>
Wisam Jaddo [Thu, 26 Nov 2020 11:15:40 +0000 (13:15 +0200)]
app/flow-perf: refactor flows handler
Provide the flows_handler() function the ability to control
flow performance processes. It is made possible after the
introduction of the insert_flows() function.
Also provide to the flows_handler() function the ability to print
the DPDK layer memory consumption of rte_flow rule, regardless
if deletion feature is enabled or not, while in previous
solution it was printing all memory changes after flows_handler().
Thus if deletion is there, it will not provide any memory that
represents the rte_flow rule size.
Also current design is easier to read and understand.
Signed-off-by: Wisam Jaddo <wisamm@nvidia.com>
Reviewed-by: Alexander Kozyrev <akozyrev@nvidia.com>
Reviewed-by: Suanming Mou <suanmingm@nvidia.com>
Olivier Matz [Fri, 18 Dec 2020 13:14:22 +0000 (14:14 +0100)]
build: fix plugin load on static build
When dpdk is compiled as static libraries, it is not possible
to load a plugin from an application. We get the following error:
EAL: librte_pmd_xxxx.so: undefined symbol: per_lcore__rte_errno
This happens because the dpdk symbols are not exported. Add them to the
dynamic symbol table by using '-Wl,--export-dynamic'. This option was
previously present when compiled with Makefiles, it was introduced in
commit
f9a08f650211 ("eal: add support for shared object drivers")
Also add it to the pkg-config file.
Fixes:
16ade738fd0d ("app/testpmd: build with meson")
Fixes:
89f0711f9ddf ("examples: build some samples with meson")
Cc: stable@dpdk.org
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Reviewed-by: Bruce Richardson <bruce.richardson@intel.com>
Tal Shnaiderman [Sun, 13 Dec 2020 14:16:04 +0000 (16:16 +0200)]
bus/pci: ignore missing NUMA node on Windows
On older processors, NUMA isn't bound to PCIe locality.
those cases return ERROR_NOT_FOUND in response to the
SetupDiGetDevicePropertyW call with DEVPKEY_Device_Numa_Node
attribute.
This error fails the probe process for the PCIe device.
this commit will ignore such failure and will set the
numa_node to 0.
Fixes:
b762221ac24f ("bus/pci: support Windows with bifurcated drivers")
Cc: stable@dpdk.org
Reported-by: Odi Assli <odia@nvidia.com>
Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
Tested-by: Odi Assli <odia@nvidia.com>
Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Acked-by: Ranjit Menon <ranjit.menon@intel.com>
Pallavi Kadam [Tue, 15 Dec 2020 00:26:22 +0000 (16:26 -0800)]
eal/windows: add interrupt functions stub
Add some missing interrupt implementations on Windows.
Also add respective functions to export file.
Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
Signed-off-by: Pallavi Kadam <pallavi.kadam@intel.com>
Reviewed-by: Ranjit Menon <ranjit.menon@intel.com>
Acked-by: Narcisa Vasile <navasile@linux.microsoft.com>
Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Dmitry Kozlyuk [Fri, 11 Dec 2020 20:09:30 +0000 (23:09 +0300)]
bus/pci: fix hardware ID limit on Windows
Length of hardware IDs list is limited by REGSTR_VAL_MAX_HCID_LEN [1],
which is currently 1024. With the old limit of 260, obtaining the list
could fail in a rare occasion of a very long result (no examples known).
This also removes a bogus dependency on the maximum path length.
[1]: https://docs.microsoft.com/en-us/windows-hardware/drivers/install/hardware-ids
Fixes:
b762221ac24f ("bus/pci: support Windows with bifurcated drivers")
Cc: stable@dpdk.org
Signed-off-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
David Marchand [Sat, 19 Dec 2020 08:05:33 +0000 (09:05 +0100)]
ci: fix package installation in GitHub Actions
APT cache must be updated to avoid trying to install an unavailable
version of a package.
Fixes:
87009585e293 ("ci: hook to GitHub Actions")
Signed-off-by: David Marchand <david.marchand@redhat.com>
Vladimir Medvedkin [Tue, 8 Dec 2020 17:00:04 +0000 (17:00 +0000)]
rib: fix insertion in some cases
According to GCC documentation for __builtin_clz:
Returns the number of leading 0-bits in x,
starting at the most significant bit position.
If x is 0, the result is undefined.
__builtin_clz will be called with 0 if the existing
prefix address matches the one we want to insert.
Fixes:
5a5793a5ffa2 ("rib: add RIB library")
Cc: stable@dpdk.org
Reported-by: David Marchand <david.marchand@redhat.com>
Signed-off-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
David Marchand [Fri, 4 Dec 2020 17:36:22 +0000 (18:36 +0100)]
ci: enable v21 ABI checks
v21 ABI will be maintained until v21.11.
Let's use the latest released libabigail 1.8.
In GitHub Actions, libabigail binaries and the ABI reference are stored
in two shared caches as all branches can use the same.
While at it, we can reproduce changes from the commit
0b8086ce3fe7
("devtools: remove useless files from ABI reference").
This will save some space in the CI caches.
Signed-off-by: David Marchand <david.marchand@redhat.com>
Tested-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Aaron Conole <aconole@redhat.com>
David Marchand [Fri, 4 Dec 2020 17:36:21 +0000 (18:36 +0100)]
ci: hook to GitHub Actions
With the recent changes in terms of free access to the Travis CI, let's
offer an alternative with GitHub Actions.
Running jobs on ARM is not supported unless using external runners, so
this commit only adds builds for x86_64 and cross compiling for i386 and
aarch64.
Differences with the Travis CI integration:
- Error logs are not dumped to the console when something goes wrong.
Instead, they are gathered in a "catch-all" step and attached as
artifacts.
- A cache entry is stored once and for all, but if no cache is found you
can inherit from the default branch cache. The cache is 5GB large, for
the whole git repository.
- The maximum retention of logs and artifacts is 3 months.
- /home/runner is world writable, so a workaround has been added for
starting dpdk processes.
- Ilya, working on OVS GHA support, noticed that jobs can run with
processors that don't have the same capabilities. For DPDK, this
impacts the ccache content since everything was built with
-march=native so far, and we will end up with binaries that can't run
in a later build. The problem has not been seen in Travis CI (?) but
it is safer to use a fixed "-Dmachine=default" in any case.
- Scheduling jobs is part of the configuration and takes the form of a
crontab. A build is scheduled every Monday at 0:00 (UTC) to provide a
default ccache for the week (useful for the ovsrobot).
Signed-off-by: David Marchand <david.marchand@redhat.com>
Tested-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Aaron Conole <aconole@redhat.com>
John McNamara [Wed, 2 Dec 2020 19:01:40 +0000 (19:01 +0000)]
license: add licenses for exception cases
The license/exceptions.txt file lists a small number of files
that have licenses that are exceptions to the three main
licenses defined in the Intellectual Property Policy of the
DPDK Charter.
The three exception licenses are MIT, ISC and BSD-2-Clause.
Each of these licenses states that the content of the license
message should be included in the code distribution. This
change adds the text of the MIT, ISC and BSD-2-Clause licenses
as defined on the SPDX website.
Cc: stable@dpdk.org
Signed-off-by: John McNamara <john.mcnamara@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Nick Connolly [Sun, 29 Nov 2020 16:00:24 +0000 (16:00 +0000)]
build: disable Windows warnings for insecure funtions
Microsoft CRT defines Windows-specific secure alternatives to
standard library functions and triggers warnings when "insecure"
functions are used [1]. However, calling code already has all
necessary checks around those functions, so these warnings are not
useful for DPDK. MinGW provides its own CRT without this issue.
[1]:
https://docs.microsoft.com/en-us/cpp/c-runtime-library/security-features-in-the-crt?view=msvc-160
Disable this by defining -D_CRT_SECURE_NO_WARNINGS.
Signed-off-by: Nick Connolly <nick.connolly@mayadata.io>
Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
Nick Connolly [Sun, 29 Nov 2020 13:00:47 +0000 (13:00 +0000)]
eal/windows: fix vfprintf warning with clang
When building with clang (11.0,--buildtype=debug), eal_lcore.c
produces a -Wformat-nonliteral warning from the vfprintf call
in log_early.
Add __rte_format_printf annotation.
Fixes:
b8a36b086625 ("eal/windows: improve CPU and NUMA node detection")
Cc: stable@dpdk.org
Suggested-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Signed-off-by: Nick Connolly <nick.connolly@mayadata.io>
Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
Nick Connolly [Fri, 27 Nov 2020 11:07:26 +0000 (11:07 +0000)]
eal/windows: fix debug build with MinGW
Compiling with MinGW in --buildtype=debug produces a redefinition
error for strncasecmp.
The root cause is that rte_os.h shouldn't be injecting POSIX definitions
into the environment. It is the applications responsibility to decide
how to handle missing functionality.
Resolving this properly will require further work, but in the meantime
wrap all such definitions with #ifndef/#endif. This resolves the specific
issue with strncasecmp and handles similar issues that applications may
encounter.
Fixes:
e8428a9d89f1 ("eal/windows: add some basic functions and macros")
Cc: stable@dpdk.org
Reported-by: David Marchand <david.marchand@redhat.com>
Signed-off-by: Nick Connolly <nick.connolly@mayadata.io>
Dmitry Kozlyuk [Tue, 1 Dec 2020 16:39:59 +0000 (19:39 +0300)]
bus/pci: fix build with MinGW-w64 8
Fix redefinition of GUID, missing from previous versions.
Fixes:
b762221ac24f ("bus/pci: support Windows with bifurcated drivers")
Cc: stable@dpdk.org
Signed-off-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Tested-by: Thomas Monjalon <thomas@monjalon.net>
Dmitry Kozlyuk [Tue, 1 Dec 2020 16:39:58 +0000 (19:39 +0300)]
eal/windows: fix build with MinGW-w64 8
MinGW-w64 above 8.0.0 exposes VirtualAlloc2() API in headers, but lacks
it in import libraries. Hence, availability of this API at compile-time
can't be used to choose between locating VirtualAlloc2() manually or
relying on the dynamic linker.
Fix redefinition compile-time errors.
Always link VirtualAlloc2() when using GCC.
Fixes:
2a5d547a4a9b ("eal/windows: implement basic memory management")
Cc: stable@dpdk.org
Reported-by: Thomas Monjalon <thomas@monjalon.net>
Signed-off-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Tested-by: Thomas Monjalon <thomas@monjalon.net>
David Marchand [Mon, 30 Nov 2020 07:47:11 +0000 (08:47 +0100)]
version: 21.02-rc0
Start a new release cycle with empty release notes.
Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
Thomas Monjalon [Fri, 27 Nov 2020 18:48:48 +0000 (19:48 +0100)]
version: 20.11.0
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Ferruh Yigit [Tue, 24 Nov 2020 17:36:28 +0000 (17:36 +0000)]
doc: announce deprecation of maximum Rx length field
The configuration related to the MTU is complex
and have some design issues.
This area should be redesigned a bit.
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Acked-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
Acked-by: Matan Azrad <matan@nvidia.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
Ferruh Yigit [Tue, 24 Nov 2020 13:15:35 +0000 (13:15 +0000)]
doc: announce flow API matching structs changes
Proposing to replace protocol header fields in the ``rte_flow_item_*``
structures with the protocol structs.
This is both for documenting the intention and to be sure
``rte_flow_item_*`` always starts with complete protocol header.
Change will be done in two steps, at first step in v21.02 release,
protocol header struct will be added as union, for example:
Current ``struct rte_flow_item_eth``,
struct rte_flow_item_eth {
struct rte_ether_addr dst;
struct rte_ether_addr src;
rte_be16_t type;
uint32_t has_vlan:1;
uint32_t reserved:31;
}
will become in v21.02:
__extension__
struct rte_flow_item_eth {
union {
struct {
struct rte_ether_addr dst;
struct rte_ether_addr src;
rte_be16_t type;
};
struct rte_ether_hdr hdr;
};
uint32_t has_vlan:1;
uint32_t reserved:31;
}
After this point usage should switch to 'hdr' struct.
And in the second step, in the v21.11 LTS release the protocol fields
will be removed, and the struct will become:
struct rte_flow_item_eth {
struct rte_ether_hdr hdr;
uint32_t has_vlan:1;
uint32_t reserved:31;
}
Already many ``rte_flow_item_*`` structures implemented to have protocol
struct, target is convert all to this usage.
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
Andrew Rybchenko [Tue, 3 Nov 2020 14:26:16 +0000 (14:26 +0000)]
ethdev: deprecate shared counters using action attribute
A new generic shared actions API may be used to create shared
counter. There is no point to keep duplicate COUNT action specific
capability to create shared counters.
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Acked-by: Ori Kam <orika@nvidia.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Ajit Khaparde [Fri, 27 Nov 2020 03:21:34 +0000 (19:21 -0800)]
doc: add vector mode limitation in bnxt guide
PMD can support vector mode when jumbo is enabled as long as MTU is not
large enough to require scattered RX (which also depends on the mbuf size).
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Anatoly Burakov [Thu, 19 Nov 2020 11:32:32 +0000 (11:32 +0000)]
doc: add VFIO troubleshooting in Linux guide
There are common problems with VFIO that get asked over and over on the
mailing list. Document common problems with VFIO and how to fix them or
at least figure out what went wrong.
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Kevin Traynor <ktraynor@redhat.com>
Anatoly Burakov [Thu, 19 Nov 2020 11:32:31 +0000 (11:32 +0000)]
doc: add VFIO no-IOMMU in Linux guide
Currently, we have no documentation on how to use VFIO in no-IOMMU mode.
Add such documentation.
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Anatoly Burakov [Thu, 19 Nov 2020 11:32:30 +0000 (11:32 +0000)]
doc: reword VFIO and UIO sections in Linux guide
Make sure that we always prioritize VFIO over UIO. Also, minor wording
corrections and improvements.
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Anatoly Burakov [Thu, 19 Nov 2020 11:32:29 +0000 (11:32 +0000)]
doc: move VFIO driver to be first in Linux guide
Currently, the Linux GSG mentions UIO drivers first. This is not ideal
as for the longest time, the recommended way to use DPDK with hardware
devices has been to use VFIO driver.
This commit simply moves UIO section after VFIO, with minor edits.
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
David Marchand [Fri, 27 Nov 2020 15:07:10 +0000 (16:07 +0100)]
usertools: remove dpdk-setup.sh
This old script relied on deprecated stuff, and especially make.
It also applied some scary 666 permissions on files under /dev/vfio.
Its deprecation had been notified in a previous release, remove it.
Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Ruifeng Wang [Fri, 27 Nov 2020 08:09:03 +0000 (16:09 +0800)]
net/igc: fix build with gcc optimization level 0
GCC build with '-O0' failed for:
../drivers/net/igc/base/igc_api.c
Assembler messages:
29: Error: selected processor does not support `casp x0,x1,x2,x3,[x4]'
82: Error: selected processor does not support `caspa x0,x1,x2,x3,[x4]'
135: Error: selected processor does not support `caspl x0,x1,x2,x3,[x4]'
188: Error: selected processor does not support `caspal x0,x1,x2,x3,[x4]'
This is due to c_args not been passed to meson.
Fixes:
8cb7c57d9b3c ("net/igc: support device initialization")
Cc: stable@dpdk.org
Reported-by: Feifei Wang <feifei.wang2@arm.com>
Signed-off-by: Ruifeng Wang <ruifeng.wang@arm.com>
Tested-by: Jerin Jacob <jerinj@marvell.com>
Acked-by: Haiyue Wang <haiyue.wang@intel.com>
Ruifeng Wang [Fri, 27 Nov 2020 08:09:02 +0000 (16:09 +0800)]
eal/arm: fix build with gcc optimization level 0
GCC build with '-O0' on platforms with RTE_ARM_FEATURE_ATOMICS set
failed for:
../lib/librte_efd/rte_efd.c
Assembler messages:
3866: Error: selected processor does not support `crc32cb w0,w0,w1'
3890: Error: selected processor does not support `crc32ch w0,w0,w1'
3914: Error: selected processor does not support `crc32cw w0,w0,w1'
3938: Error: selected processor does not support `crc32cx w0,w0,x1'
This was caused by an architecture specifier added for Clang.
Unlike Clang, GCC considers each inline assembly block to be dependent
and therefore, the architecture specifier impacts assemble of some
blocks require certain extension support.
Removed the architecture for GCC to fix the issue.
Fixes:
8fce34cd0a6a ("eal/arm: fix clang build of native target")
Cc: stable@dpdk.org
Reported-by: Feifei Wang <feifei.wang2@arm.com>
Signed-off-by: Ruifeng Wang <ruifeng.wang@arm.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Anatoly Burakov [Thu, 19 Nov 2020 10:52:45 +0000 (10:52 +0000)]
doc: update information on using hugepages
Current information regarding hugepage usage is a little out of date.
Update it to include information on in-memory mode, as well as on
default mountpoints provided by systemd.
Cc: stable@dpdk.org
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Anatoly Burakov [Thu, 19 Nov 2020 10:52:44 +0000 (10:52 +0000)]
doc: clarify instructions on running as non-root
The current instructions are slightly out of date when it comes to
providing information about setting up the system for using DPDK as
non-root, so update them.
Cc: stable@dpdk.org
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Ray Kinsella [Mon, 10 Aug 2020 09:24:07 +0000 (10:24 +0100)]
doc: clarify reference version for ABI checks
Clarify the ABI reference version (DPDK_ABI_REF_VERSION) tag, to use
when testing builds with devtools/test-meson-builds.sh before
submitting patches.
Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Reviewed-by: David Marchand <david.marchand@redhat.com>
Ferruh Yigit [Fri, 3 Jul 2020 17:15:38 +0000 (18:15 +0100)]
doc: add sample for ABI checks
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Ray Kinsella <mdr@ashroe.eu>
Stephen Hemminger [Tue, 15 Sep 2020 02:03:40 +0000 (19:03 -0700)]
maintainers: update for netvsc
The removed maintainers deal with the Linux side of netvsc and
are not relevant for DPDK.
With Long's help the driver is now stable enough for real usage,
so the experimental mark is removed.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Nikhil Rao [Wed, 26 Aug 2020 02:02:06 +0000 (07:32 +0530)]
maintainers: update for eventdev Rx/Tx adapters
Jay is the new maintainer since Nikhil no longer works on DPDK.
Signed-off-by: Nikhil Rao <nikhil.rao@intel.com>
Ajit Khaparde [Tue, 24 Nov 2020 14:13:30 +0000 (06:13 -0800)]
doc: add tested platforms for Broadcom NICs
Add tested platforms for Broadcom NICs to the 20.11 release notes.
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Raslan Darawsheh [Tue, 24 Nov 2020 09:54:37 +0000 (11:54 +0200)]
doc: add tested platforms with Mellanox NICs
Add tested platforms with Mellanox NICs to the 20.11 release notes.
Signed-off-by: Raslan Darawsheh <rasland@nvidia.com>
Bo Chen [Fri, 20 Nov 2020 20:46:12 +0000 (15:46 -0500)]
doc: add tested Intel platforms with Intel NICs
Add tested Intel platforms with Intel NICs to v20.11 release note.
Signed-off-by: Bo Chen <box.c.chen@intel.com>
John McNamara [Tue, 24 Nov 2020 20:40:47 +0000 (20:40 +0000)]
doc: update release notes for 20.11
Fix grammar, spelling and formatting of DPDK 20.11 release notes.
Signed-off-by: John McNamara <john.mcnamara@intel.com>
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Bruce Richardson [Fri, 13 Nov 2020 16:16:47 +0000 (16:16 +0000)]
doc: remove meson version deprecation notice
DPDK has been using meson 0.47 for some time now, so we can safely
remove the note calling out this fact.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: David Marchand <david.marchand@redhat.com>
Gregory Etelson [Thu, 26 Nov 2020 16:43:28 +0000 (17:43 +0100)]
doc: add pkg-config requirement for applications
DPDK relies on pkg-config(1) to provide correct parameters for
compiler and linker used in application build. Inaccurate build
parameters, produced by pkg-config from DPDK .pc files could fail
application build or cause unpredicted results during application
runtime.
Update system requirements doc about a bug in pkg-config v0.27
used in RHEL-7.
Signed-off-by: Gregory Etelson <getelson@nvidia.com>
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Thomas Monjalon [Thu, 26 Nov 2020 16:08:37 +0000 (17:08 +0100)]
doc: remove Linux headers from requirements
The compilation of the kernel module KNI is optional.
The kernel headers should not be required for DPDK compilation.
Fixes:
91a861e54164 ("config: disable Linux kernel modules by default")
Cc: stable@dpdk.org
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Olivier Matz [Thu, 26 Nov 2020 14:26:39 +0000 (15:26 +0100)]
doc: add missing network layers in API index
Add missing files in doxy-api-index.md and add a short description
for files that hadn't one.
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Olivier Matz [Thu, 26 Nov 2020 14:23:45 +0000 (15:23 +0100)]
kni: fix build on RHEL 8.3
Like what was done for mainline kernel in commit
38ad54f3bc76 ("kni: fix
build with Linux 5.6"), a new parameter 'txqueue' has to be added to
'ndo_tx_timeout' ndo on RHEL 8.3 kernel.
Cc: stable@dpdk.org
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Tested-by: Christophe Grosse <christophe.grosse@6wind.com>
Tested-by: David Marchand <david.marchand@redhat.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Asaf Penso [Tue, 24 Nov 2020 07:32:32 +0000 (07:32 +0000)]
doc: update BlueField platform guide
The documentation file contains some broken links to Mellanox's site.
Also now BlueField-2 platform is supported.
This patch provides new links and adds documentation for
BlueField-2 platform.
Signed-off-by: Asaf Penso <asafp@nvidia.com>
Raslan Darawsheh [Tue, 24 Nov 2020 10:30:35 +0000 (12:30 +0200)]
doc: add ConnectX-6 Lx and BlueField-2 in mlx5 guide
This adds ConnectX-6 Lx and BlueField-2 to the list of NICs
supported by mlx5 PMD.
Signed-off-by: Raslan Darawsheh <rasland@nvidia.com>
Asaf Penso [Sun, 22 Nov 2020 12:05:55 +0000 (12:05 +0000)]
doc: update hardware offloads support in mlx5 guide
In DPDK 20.11 the following offload features are added:
* Buffer Split
* Sampling
* Tunnel offload
* 2-port hairpin
* RSS shared action
* Age shared action
Update the relevant tables with OFED/rdma-core/NIC versions.
Signed-off-by: Asaf Penso <asafp@nvidia.com>
Asaf Penso [Tue, 24 Nov 2020 07:44:16 +0000 (07:44 +0000)]
doc: add Rx functions limitations in mlx5 guide
The mlx5 PMD supports various Rx burst functions.
Each function is enabled differently and supports different features.
Signed-off-by: Asaf Penso <asafp@nvidia.com>
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Qi Zhang [Wed, 18 Nov 2020 23:56:07 +0000 (07:56 +0800)]
doc: update ice user guide
Add link for firmware/OOT kernel driver/DDP download
Add matching List.
Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Lijun Ou [Tue, 24 Nov 2020 13:56:17 +0000 (21:56 +0800)]
doc: update hns3 features
Since the hns3 NIC hardware features are not counted
and it is supported in fact. Besides, the flow director
is not supported and need to delete it.
Fixes:
fa29fe45a7b4 ("net/hns3: support queue start and stop")
Fixes:
521ab3e93361 ("net/hns3: add simple Rx path")
Fixes:
bba636698316 ("net/hns3: support Rx/Tx and related operations")
Fixes:
936eda25e8da ("net/hns3: support dump register")
Fixes:
53b9f2b9a560 ("doc: update feature list in hns3 guide")
Cc: stable@dpdk.org
Signed-off-by: Lijun Ou <oulijun@huawei.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Ajit Khaparde [Wed, 25 Nov 2020 04:46:41 +0000 (20:46 -0800)]
doc: update TRUFLOW support in bnxt guide
Currently TRUFLOW is supported only on Whitney+ and Stingray devices.
Update the PMD doc with this info.
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Ajit Khaparde [Mon, 26 Oct 2020 21:46:04 +0000 (14:46 -0700)]
doc: announce end of support for some Broadcom devices
Devices belonging to BCM573xx and BCM5740x family will not be supported
from the 21.02 release.
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Kevin Traynor <ktraynor@redhat.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Ajit Khaparde [Tue, 24 Nov 2020 14:25:03 +0000 (06:25 -0800)]
doc: remove list of supported OS from bnxt guide
Remove list of supported OS in PMD specific doc.
Documenting an unsupported version of OS makes more sense in
PMD specific docs.
Platforms tested with this device is documented in release notes anyway.
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Stephen Hemminger [Thu, 24 Sep 2020 17:53:47 +0000 (10:53 -0700)]
doc: prefer VFIO for device binding
We should be encouraging the use of vfio-pci for developers, not telling
them to use igb_uio.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Reshma Pattan [Thu, 26 Nov 2020 13:51:14 +0000 (13:51 +0000)]
doc: clarify multi-process roles for pdump
Update the pdump library programmers guide and Howto doc
with the use of multi process channel replacing socket
based communication.
Signed-off-by: Reshma Pattan <reshma.pattan@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Stephen Hemminger [Mon, 16 Nov 2020 02:22:02 +0000 (18:22 -0800)]
doc: add SPDX license tag header to Intel performance guide
This document never had any license or copyright on this file, add one.
Fixes:
b932ebcb2664 ("doc: add NIC performance guide on Linux IA")
Cc: stable@dpdk.org
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Acked-by: John McNamara <john.mcnamara@intel.com>
Sarosh Arif [Wed, 16 Sep 2020 11:14:38 +0000 (16:14 +0500)]
doc: fix grammar
This patch corrects a grammatical error by changing 'an DPDK' to 'a DPDK',
so that the sentences can become grammatically accurate.
Fixes:
2e486e26328c ("doc: remove Intel references from linux guide")
Fixes:
48624fd96e7c ("doc: remove Intel references from prog guide")
Fixes:
e0c7c4731957 ("doc: remove Intel references from sample apps guide")
Cc: stable@dpdk.org
Signed-off-by: Sarosh Arif <sarosh.arif@emumba.com>
Reviewed-by: David Marchand <david.marchand@redhat.com>
Viacheslav Ovsiienko [Mon, 23 Nov 2020 12:29:41 +0000 (12:29 +0000)]
net: fix eCPRI header generic data field
There was a typo in eCPRI header definition.
Fixes:
d164c609e70b ("ethdev: add eCPRI key fields to flow API")
Cc: stable@dpdk.org
Reported-by: Rani Sharoni <ranish@nvidia.com>
Signed-off-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Reviewed-by: Bing Zhao <bingz@nvidia.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Viacheslav Ovsiienko [Tue, 24 Nov 2020 11:49:56 +0000 (11:49 +0000)]
app/testpmd: fix build without i40e
If there was no RTE_NET_I40E configured the static routine
str2flowtype() was not used causing compilation warning.
The str2flowtype() is moved under #ifdef RTE_NET_I40E block.
Fixes:
1be514fbcea9 ("ethdev: remove legacy FDIR filter type support")
Signed-off-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Gregory Etelson [Wed, 18 Nov 2020 16:15:20 +0000 (18:15 +0200)]
doc: update flow API guide for rule removal on stop
There is a discrepancy between ethdev API and flow rules guide
regarding flow rules maintenance after port stop.
librte_ethdev.h declares that flow rules will not be stored in PMD
after port stop:
>>>>> Quote start
Please note that some configuration is not stored between calls to
rte_eth_dev_stop()/rte_eth_dev_start(). The following configuration
will be retained:
- MTU
- flow control settings
- receive mode configuration (promiscuous mode, all-multicast mode,
hardware checksum mode, RSS/VMDQ settings etc.)
- VLAN filtering configuration
- default MAC address
- MAC addresses supplied to MAC address array
- flow director filtering mode (but not filtering rules)
- NIC queue statistics mappings
<<<< Quote end
PMD cannot always correctly restore flow rules after port stop / port
start because application may alter port configuration after port stop
without PMD knowledge about undergoing changes. Consider the
following scenario:
application configures 2 queues 0 and 1 and creates a flow rule with
'queue index 1' action. After that application stops the port and
removes queue 1.
Although PMD can implement flow rule shadow copy to be used for
restore after port start, attempt to restore flow rule from shadow
will fail in example above and PMD could not notify application about
that failure. As the result, flow rules map in HW will differ from
what application expects. In addition, flow rules shadow copy used
for port start restore consumes considerable amount of system memory,
especially in systems with millions of flow rules.
Signed-off-by: Gregory Etelson <getelson@nvidia.com>
Acked-by: Ori Kam <orika@nvidia.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Timothy Redaelli [Tue, 24 Nov 2020 15:14:15 +0000 (16:14 +0100)]
eal: fix plugin loading
Commit
49b536fc3060 ("eal: load only shared libs from driver plugin directories")
introduced a check that any shared library must ends with .so, but it can't
work, at least, on Fedora/CentOS/RHEL since .so symlinks are not installed
when you install dpdk package, but only when you install dpdk-devel package.
This commit adds also a check for .so.ABI_VERSION to check for shared lib.
See Fedora Packaging Guidelines for more information:
https://docs.fedoraproject.org/en-US/packaging-guidelines/#_devel_packages
Fixes:
49b536fc3060 ("eal: load only shared libs from driver plugin directories")
Cc: stable@dpdk.org
Signed-off-by: Timothy Redaelli <tredaelli@redhat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: David Marchand <david.marchand@redhat.com>
Acked-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Tested-by: Ferruh Yigit <ferruh.yigit@intel.com>
Tested-by: Ali Alnubani <alialnu@nvidia.com>
Timothy Redaelli [Tue, 24 Nov 2020 15:14:14 +0000 (16:14 +0100)]
eal: fix shared lib mode detection
Commit
06c7871dde01 ("eal: restrict default plugin path to shared lib mode")
introduced a check that enabled shared lib mode when librte_eal.so can
be loaded, but it can't work, at least, on Fedora/CentOS/RHEL since .so
symlinks are not installed when you install dpdk package, but only when
you install dpdk-devel package.
This commit uses librte_eal.so.ABI_VERSION to check for shared lib,
since it exists on any linux distributions.
See Fedora Packaging Guidelines for more information:
https://docs.fedoraproject.org/en-US/packaging-guidelines/#_devel_packages
Fixes:
06c7871dde01 ("eal: restrict default plugin path to shared lib mode")
Cc: stable@dpdk.org
Signed-off-by: Timothy Redaelli <tredaelli@redhat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: David Marchand <david.marchand@redhat.com>
Acked-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Tested-by: Ali Alnubani <alialnu@nvidia.com>
Guoyang Zhou [Tue, 24 Nov 2020 06:45:34 +0000 (14:45 +0800)]
net/hinic: remove optical module operation
Remove the operation of optical modules in the link function, because
when device binds from dpdk to kernel, it will be linked failed. This
function does not take effect in cable mode, therefore, optimization
is required.
Fixes:
54ac33869932 ("net/hinic: set link down and up")
Cc: stable@dpdk.org
Signed-off-by: Guoyang Zhou <zhouguoyang@huawei.com>
Guoyang Zhou [Tue, 24 Nov 2020 06:45:33 +0000 (14:45 +0800)]
net/hinic/base: remove queue number limitation
The maximum number of queues on the chip can be any value greater
than 0, it does not have to be the power of two, if it does not be
fixed, dpdk initialization may be failed with OVS mode firmware.
Fixes:
828d3e15a9dc ("net/hinic/base: support context and work queue")
Cc: stable@dpdk.org
Signed-off-by: Guoyang Zhou <zhouguoyang@huawei.com>
Cristian Dumitrescu [Mon, 23 Nov 2020 17:49:24 +0000 (17:49 +0000)]
doc: add pipeline example user guide
Document the pipeline example in the Sample Application User Guide.
Signed-off-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
Diogo Behrens [Wed, 26 Aug 2020 09:20:02 +0000 (11:20 +0200)]
mcslock: fix hang in weak memory model
The initialization me->locked=1 in lock() must happen before
next->locked=0 in unlock(), otherwise a thread may hang forever,
waiting me->locked become 0. On weak memory systems (such as ARMv8),
the current implementation allows me->locked=1 to be reordered with
announcing the node (pred->next=me) and, consequently, to be
reordered with next->locked=0 in unlock().
This fix adds a release barrier to pred->next=me, forcing
me->locked=1 to happen before this operation.
Fixes:
2173f3333b61 ("mcslock: add MCS queued lock implementation")
Cc: stable@dpdk.org
Signed-off-by: Diogo Behrens <diogo.behrens@huawei.com>
Acked-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Bruce Richardson [Tue, 24 Nov 2020 09:46:56 +0000 (09:46 +0000)]
usertools: fix binding regex or misc device
The "misc" and "regex" device classes were missing from the list used to
check arguments, preventing them from being used with "--status-dev"
flag to list only devices of those types.
When adding them to the list, the list is also sorted alphabetically for
consistency.
Bugzilla ID: 582
Fixes:
81255f27c65c ("usertools: replace optparse with argparse")
Reported-by: Wei Ling <weix.ling@intel.com>
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
Tested-by: Yu Jiang <yux.jiang@intel.com>
Thomas Monjalon [Tue, 24 Nov 2020 22:33:15 +0000 (23:33 +0100)]
net/mlx5: fix flow shared action destroy error code
In the function rte_flow_shared_action_destroy(),
the errno ETOOMANYREFS has been replaced with EBUSY in the
commit
dc328d1c555a ("ethdev: rename a flow shared action error code").
Another occurrence of ETOOMANYREFS, added later by mistake,
is replaced with EBUSY errno.
Fixes:
fa7ad49e96b5 ("net/mlx5: fix shared RSS action update")
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Reviewed-by: Tal Shnaiderman <talshn@nvidia.com>
Tested-by: Tal Shnaiderman <talshn@nvidia.com>
Gregory Etelson [Wed, 25 Nov 2020 09:44:27 +0000 (11:44 +0200)]
net/mlx5: fix tunnel offload freeing
PMD did not remove tunnel offload object from tunnels database before
it released the object memory. As the result, the tunnels database
become corrupted and subsequent search operations triggered PMD crash.
The patch removes tunnel offload object from the tunnels database when
the object is not in-use by PMD any more.
Fixes:
bc1d90a3cf6f ("net/mlx5: fix build with Direct Verbs disabled")
Signed-off-by: Gregory Etelson <getelson@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Matan Azrad [Mon, 23 Nov 2020 15:56:42 +0000 (15:56 +0000)]
net/mlx5: reduce log level in hash list registration
In mlx5 internal hash list tool, there is a log print when an entry
allocation is failed: Can't allocate hash list entry.
Some initialization checks triggers hash list registration in order to
check some capabilities. Here, the failure in registration doesn't
lead to failure in the initialization flow, that is why the log level
can be lower.
Move the entry allocation failure log to debug level.
Signed-off-by: Matan Azrad <matan@nvidia.com>
Reviewed-by: Asaf Penso <asafp@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Gregory Etelson [Tue, 24 Nov 2020 08:10:13 +0000 (10:10 +0200)]
net/mlx5: fix DevX resources freeing
Invalid memory release order of DevX resources caused PMD crash.
1. SQ and CQ memory must be unregistered with DevX before it is freed.
2. SQ objects reference to a CQ ones. Hence, SQ should be destroyed in
advance of CQ it references to.
Fixes:
6deb19e1b2d2 ("net/mlx5: separate Rx queue object creations")
Fixes:
88f2e3f18cc7 ("net/mlx5: rearrange SQ and CQ creation in DevX module")
Signed-off-by: Gregory Etelson <getelson@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
Xiaoyu Min [Mon, 16 Nov 2020 07:55:17 +0000 (15:55 +0800)]
net/iavf: fix ethernet header size in flow rule
The rte_flow_item_vlan items are refined.
The structs do not exactly represent the packet bits captured on the
wire anymore so should only copy real header instead of the whole struct.
Replace the rte_flow_item_* with the existing corresponding rte_*_hdr.
Fixes:
09315fc83861 ("ethdev: add VLAN attributes to ethernet and VLAN items")
Signed-off-by: Xiaoyu Min <jackmin@nvidia.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Thomas Monjalon [Sun, 22 Nov 2020 21:53:47 +0000 (22:53 +0100)]
version: 20.11-rc5
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Ferruh Yigit [Sat, 21 Nov 2020 01:15:21 +0000 (01:15 +0000)]
devtools: add acronyms in dictionary for commit checks
ICMP -> Internet Control Message Protocol
IPv4 -> Internet Protocol version 4
IPv6 -> Internet Protocol version 6
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Stephen Hemminger [Wed, 9 Sep 2020 18:51:01 +0000 (11:51 -0700)]
usertools: add huge page setup script
This is an improved version of the setup of huge pages
bases on earlier DPDK setup.
Differences are:
* autodetects NUMA vs non NUMA
* allows setting different page sizes
recent kernels support multiple sizes.
* accepts a parameter in bytes (not pages).
* can display current hugepage settings.
Most users will just use --setup argument but if necessary
the steps of clearing old settings and mounting/umounting
can be done individually.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Julien Massonneau [Thu, 19 Nov 2020 09:44:01 +0000 (10:44 +0100)]
usertools: fix pmdinfo parsing
In the display_pmd_info_strings function, the script parses the section
until to find a byte between 32 and 127, and get all data
until a byte equals to 0.
After, it searches "PMD_INFO_STRING" in the data and passes the whole
string in the parse_pmd_info_string function, which split the string
with "=" and convert it in python dict with json.loads().
But the string may contain a "=" before "PMD_INFO_STRING",
so it is not correctly split and will lead to an error
(json.decoder.JSONDecodeError).
Example of a string encountered that leads to an error:
"Ag%=C£°ÐÊ+Ë®{0´wË-£0òjB·;¾¬úPMD_INFO_STRING= {"name" :
"net_octeontx", "params" : "nr_port=<int> ", "pci_ids" : []}"
Fixes:
c67c9a5c646a ("tools: query binaries for HW and other support information")
Cc: stable@dpdk.org
Signed-off-by: Julien Massonneau <julien.massonneau@6wind.com>
Stephen Hemminger [Wed, 4 Nov 2020 07:03:50 +0000 (23:03 -0800)]
usertools: test multiple strings with operator in
Python lint suggests using in instead of multiple comparisons.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Stephen Hemminger [Wed, 4 Nov 2020 07:03:47 +0000 (23:03 -0800)]
usertools: remove unused imports in devbind
Address python lint complaints about unused imports.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Stephen Hemminger [Wed, 4 Nov 2020 06:48:42 +0000 (22:48 -0800)]
usertools: do not test empty with function len
Python lint warns about using len(SEQUENCE) to determine if sequence is empty.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Stephen Hemminger [Wed, 4 Nov 2020 06:48:41 +0000 (22:48 -0800)]
usertools: replace optparse with argparse
The optparse module is deprecated and replaced with new argparse.
Using the python standard argument parser instead of C library
style getopt gives a number of advantages such as checking
for conflicting arguments, restricting choices, and automatically
generating help messages.
Some of the help messages are now less wordy.
The code now enforces the rule that only one of the pmdinfo formats
can be specified: raw or json.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Stephen Hemminger [Wed, 4 Nov 2020 06:48:40 +0000 (22:48 -0800)]
usertools: fix indentation
Python lint complains about indentation and missing spaces around commas.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Stephen Hemminger [Wed, 4 Nov 2020 06:48:39 +0000 (22:48 -0800)]
usertools: replace explicit boolean checks
Code reads better if unnecessary comparison with False and True
is not used.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Stephen Hemminger [Wed, 4 Nov 2020 06:48:38 +0000 (22:48 -0800)]
usertools: remove unnecessary parens and else
Python lint complains:
Unnecessary parens after 'if' keyword
Unnecessary parens after 'not' keyword
Unnecessary "else" after "return"
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Stephen Hemminger [Wed, 4 Nov 2020 06:48:37 +0000 (22:48 -0800)]
usertools: replace io.open
The builtin open() is the recommended approach in python3.
io.open was for compatibility with older versions.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Stephen Hemminger [Wed, 4 Nov 2020 06:48:36 +0000 (22:48 -0800)]
usertools: replace string.split
In python3 the standard way to split strings is to use the
split() on the string object itself. The old way is broken
and would cause a traceback.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Conor Walsh [Thu, 19 Nov 2020 10:17:00 +0000 (10:17 +0000)]
net/bnxt: fix format specifier for unsigned numbers
&device requires the %u format specifer not the %d specifier, as
&device is unsigned.
Fixes:
a46bbb57605b ("net/bnxt: update multi device design")
Cc: stable@dpdk.org
Signed-off-by: Conor Walsh <conor.walsh@intel.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Conor Walsh [Thu, 19 Nov 2020 10:16:59 +0000 (10:16 +0000)]
build: fix gcc warning requiring Wformat
On some CentOS/RHEL systems using gcc 8.3.1 to compile dpdk, gcc shows a
warning on every build step saying that -Wformat-nonliteral and
-Wformat-security warnings will be ignored unless -Wformat is
also specified as a compiler flag. When the build is run with -werror
the build will fail due to these warnings.
Exact warning returned:
cc1: error: -Wformat-nonliteral ignored without -Wformat
[-Werror=format-nonliteral]
cc1: error: -Wformat-security ignored without -Wformat
[-Werror=format-security]
cc1: all warnings being treated as errors
This patch adds the -Wformat flag to config/meson.build. The warning id
181 has also been suppressed in icc as icc was showing false positives
with -Wformat enabled.
Fixes:
524a0d5d66b9 ("build: enable extra warnings with meson")
Cc: stable@dpdk.org
Signed-off-by: Conor Walsh <conor.walsh@intel.com>
Tested-by: Lingli Chen <linglix.chen@intel.com>
Nick Connolly [Sun, 22 Nov 2020 08:45:15 +0000 (08:45 +0000)]
eal/windows: fix linkage with MinGW
Linking with the 'pci' driver when building with MinGW on
Windows fails with undefined symbol 'GUID_DEVCLASS_NET'.
This occurs because devguid.h is included in rte_windows.h
before INITGUID is defined.
Move the include of devguid.h after the definition of INITGUID.
Fixes:
b762221ac24f ("bus/pci: support Windows with bifurcated drivers")
Cc: stable@dpdk.org
Signed-off-by: Nick Connolly <nick.connolly@mayadata.io>
Reviewed-by: Tal Shnaiderman <talshn@nvidia.com>
Yunjian Wang [Thu, 12 Nov 2020 09:31:15 +0000 (17:31 +0800)]
malloc: fix style in free list index computation
Cleanup code style issue reported by kernel checkpatch. As follows:
* ERROR:CODE_INDENT: code indent should use tabs where possible
* ERROR:SPACING: spaces required around that '?' (ctx:VxE)
* WARNING:INDENTED_LABEL: labels should not be indented
Fixes:
b0489e7bca2f ("malloc: fix linear complexity")
Cc: stable@dpdk.org
Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
Acked-by: Anatoly Burakov <anatoly.burakov@intel.com>
Gregory Etelson [Tue, 17 Nov 2020 18:49:40 +0000 (20:49 +0200)]
net/mlx5: fix representor interrupts handler
Representor is a port in DPDK that is connected to a VF in such a way
that assuming there are no offload flows, each packet that is sent
from the VF will be received by the corresponding representor. While
each packet that is sent to a representor will be received by the VF.
This is very useful in case of SRIOV mode, where the first packet that
is sent by the VF will be received by the DPDK application which will
decide if this flow should be offloaded to the E-Switch.
Representor shares interrupts handler with host PF over the PCI
address. Therefore, after PF completes its interrupts handler
initialization, no additional actions required for representor.
Fixes:
26c08b979d26 ("net/mlx5: add port representor awareness")
Cc: stable@dpdk.org
Signed-off-by: Gregory Etelson <getelson@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Gregory Etelson [Tue, 17 Nov 2020 18:49:39 +0000 (20:49 +0200)]
examples/l3fwd-power: check packet types after start
l3fwd-power uses `--parse-ptype' parameter to query egress packets
type. Before that feature is enabled l3fwd-power verifies PMD ability
to advertise supported packet types with
rte_eth_dev_get_supported_ptypes().
The above ethdev function API contains this note:
"
Better to invoke this API after the device is already started or rx burst
function is decided, to obtain correct supported ptypes.
"
The patch updates code for PMDs that register supported types after
dev_start.
Fixes:
82bea4661626 ("examples/l3fwd-power: add --parse-ptype option")
Cc: stable@dpdk.org
Signed-off-by: Gregory Etelson <getelson@nvidia.com>
Andrey Vesnovaty [Sun, 22 Nov 2020 14:49:51 +0000 (16:49 +0200)]
net/mlx5: fix shared RSS action update
The shared RSS action update was not operational due to lack
of kernel driver support of TIR object modification.
This commit introduces the workaround to support shared RSS
action modify using an indirect queue table update instead of
touching TIR object directly.
Limitations: the only supported RSS property to update is queues, the
rest of the properties ignored.
Fixes:
d2046c09aa64 ("net/mlx5: support shared action for RSS")
Signed-off-by: Andrey Vesnovaty <andreyv@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Tonghao Zhang [Fri, 20 Nov 2020 14:48:03 +0000 (14:48 +0000)]
net/mlx5: check register available for metadata action
If user don't set the dv_xmeta_en to 1 or 2,
in the flow_dv_convert_action_set_meta function:
- flow_dv_get_metadata_reg may return the REG_NONE,
when MLX5_METADATA_FDB enabled for metadata set action.
- reg_to_field(REG_NONE) returns MLX5_MODI_OUT_NONE,
that is invalid and rdma-core fails.
The rdma-core calltrace:
dr_action_create_modify_action
dr_actions_convert_modify_header
dr_action_modify_sw_to_hw
dr_action_modify_sw_to_hw_set
dr_ste_get_modify_hdr_hw_field
Fixes:
fcc8d2f716fd ("net/mlx5: extend flow metadata support")
Cc: stable@dpdk.org
Signed-off-by: Tonghao Zhang <xiangxia.m.yue@gmail.com>
Signed-off-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Alexander Kozyrev [Sat, 21 Nov 2020 03:42:39 +0000 (03:42 +0000)]
net/mlx5: fix mbuf overflow in vectorized MPRQ
Changing the allocation scheme to improve mbufs locality caused mbufs
overrun in some cases. Revert the previous replenish logic back.
Calculate a number of unused mbufs and replenish max this number of mbufs.
Mark the last 4 mbufs as fake mbufs to prevent overflowing into consumed
mbufs in the future. Keep the consumed index and the produced index 4 mbufs
apart for this purpose.
Replenish some mbufs only in case the consumed index is within the
replenish threshold of the produced index in order to retain the cache
locality for the vectorized MPRQ routine.
Fixes:
5c68764377 ("net/mlx5: improve vectorized MPRQ descriptors locality")
Signed-off-by: Alexander Kozyrev <akozyrev@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Viacheslav Ovsiienko [Thu, 19 Nov 2020 19:18:24 +0000 (19:18 +0000)]
net/mlx5: make Tx scheduling xstats names compliant
xstats names for Tx packet scheduling should be compliant with [1]
[1] http://doc.dpdk.org/guides/prog_guide/poll_mode_drv.html?highlight=xstats#extended-statistics-api
Bugzilla ID: 558
Signed-off-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Viacheslav Ovsiienko [Thu, 19 Nov 2020 19:18:05 +0000 (19:18 +0000)]
net/mlx5: make ethernet xstats names compliant
xstats names for simple stats are mostly standardized in ethdev drivers
and should be compliant with [1]
[1] http://doc.dpdk.org/guides/prog_guide/poll_mode_drv.html?highlight=xstats#extended-statistics-api
Bugzilla ID: 558
Reported-by: Igor Ryzhov <iryzhov@nfware.com>
Signed-off-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
Benoît Ganne [Sun, 22 Nov 2020 10:04:04 +0000 (12:04 +0200)]
net/mlx5: allow unknown link speed
mlx5 PMD refuses to update link state if link speed is defined but
status is down or if link speed is undefined but status is up, even if
the ioctl() succeeded.
This prevents application to detect link up/down event, especially when
the link speed is not correctly detected.
Commit [1] allowed returning unknown link speed, so now PMD allows
the return of unknown link speed in the above case.
Due to some old kernel driver bug, link speed wasn't detected properly.
[1] http://git.dpdk.org/dpdk/commit/?id=
810b17d116f03
Signed-off-by: Benoît Ganne <bganne@cisco.com>
Signed-off-by: Raslan Darawsheh <rasland@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
Xiaoyu Min [Mon, 16 Nov 2020 07:55:15 +0000 (15:55 +0800)]
app/flow-perf: fix raw encapsulation size
The rte_flow_item_eth and rte_flow_item_vlan items are refined.
The structs do not exactly represent the packet bits captured on the
wire anymore so add_*_header functions should use real header instead of
the using rte_flow_item_* struct.
Replace the rte_flow_item_* with the existing corresponding rte_*_hdr.
Fixes:
09315fc83861 ("ethdev: add VLAN attributes to ethernet and VLAN items")
Signed-off-by: Xiaoyu Min <jackmin@nvidia.com>
Dekel Peled [Mon, 16 Nov 2020 07:55:18 +0000 (15:55 +0800)]
net/softnic: fix header size calculation
The rte_flow_item_eth and rte_flow_item_vlan items were updated in [1].
The rte_flow_item_ipv6 item was updated in [2].
The structs now contain additional metadata following the header data.
The size to use for match should be the header data size only, and
not the size of the whole struct.
This patch replaces the rte_flow_item_* with the corresponding rte_*_hdr.
Fixes:
09315fc83861 ("ethdev: add VLAN attributes to ethernet and VLAN items")
Fixes:
ad976bd40d28 ("ethdev: add extensions attributes to IPv6 item")
Signed-off-by: Dekel Peled <dekelp@nvidia.com>
Acked-by: Jasvinder Singh <jasvinder.singh@intel.com>
Xiaoyu Min [Mon, 16 Nov 2020 07:55:14 +0000 (15:55 +0800)]
net/mlx5: fix encap/decap limit for hairpin flow split
The rte_flow_item_eth and rte_flow_item_vlan items are refined.
The structs do not exactly represent the packet bits captured on the
wire anymore.
Should use real header instead of the whole struct.
Replace the rte_flow_item_* with the existing corresponding rte_*_hdr.
Fixes:
09315fc83861 ("ethdev: add VLAN attributes to ethernet and VLAN items")
Fixes:
f9210259cac7 ("net/mlx5: fix raw encap/decap limit")
Signed-off-by: Xiaoyu Min <jackmin@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>