Go to file
Hyong Youb Kim 8d782f3f89 net/enic: allocate stats DMA buffer upfront during probe
The driver provides a DMA buffer to the firmware when it requests port
stats. The NIC then fills that buffer with latest stats. Currently,
the driver allocates the DMA buffer the first time it requests stats
and saves it for later use. This can lead to crashes when
primary/secondary processes are involved. For example, the following
sequence crashes the secondary process.

1. Start a primary app that does not call rte_eth_stats_get()
2. dpdk-procinfo -- --stats

dpdk-procinfo crashes while trying to allocate the stats DMA buffer
because the alloc function pointer (vdev.alloc_consistent) is valid
only in the primary process, not in the secondary process.

Overwriting the alloc function pointer in the secondary process is not
an option, as it will simply make the pointer invalid in the primary
process. Instead, allocate the DMA buffer during probe so that only
the primary process does both allocate and free. This allows the
secondary process to dump stats as well.

Fixes: 9913fbb91d ("enic/base: common code")
Cc: stable@dpdk.org

Signed-off-by: Hyong Youb Kim <hyonkim@cisco.com>
Reviewed-by: John Daley <johndale@cisco.com>
2018-03-30 14:08:43 +02:00
app app/procinfo: fix strncpy usage in args parsing 2018-03-28 00:35:37 +02:00
buildtools buildtools: output build failure reason to stderr 2018-02-08 22:25:37 +01:00
config build: add meson cross-compilation config for dpaaX 2018-03-15 18:01:01 +01:00
devtools compat: relicense some files 2018-02-06 23:13:47 +01:00
doc net/enic: heed the requested max Rx packet size 2018-03-30 14:08:43 +02:00
drivers net/enic: allocate stats DMA buffer upfront during probe 2018-03-30 14:08:43 +02:00
examples examples/exception_path: limit core count to 64 2018-03-28 00:35:37 +02:00
kernel kni: fix build on RHEL 7.5 2018-03-28 00:15:08 +02:00
lib ethdev: remove versioning of filter control function 2018-03-30 14:08:43 +02:00
license
mk mk: fix kernel modules build dependency 2018-03-30 13:01:17 +02:00
pkg version: 18.02.0 2018-02-14 19:11:02 +01:00
test meter: add configuration profile 2018-02-19 22:28:05 +01:00
usertools usertools: support AVP device 2018-03-28 00:49:53 +02:00
.gitattributes
.gitignore
GNUmakefile move kernel modules directories 2018-03-21 23:04:21 +01:00
MAINTAINERS move kernel modules directories 2018-03-21 23:04:21 +01:00
Makefile
meson_options.txt test: build app with meson as dpdk-test 2018-01-30 21:58:59 +01:00
meson.build move kernel modules directories 2018-03-21 23:04:21 +01:00
README

DPDK is a set of libraries and drivers for fast packet processing.
It supports many processor architectures and both FreeBSD and Linux.

The DPDK uses the Open Source BSD-3-Clause license for the core libraries
and drivers. The kernel components are GPL-2.0 licensed.

Please check the doc directory for release notes,
API documentation, and sample application information.

For questions and usage discussions, subscribe to: users@dpdk.org
Report bugs and issues to the development mailing list: dev@dpdk.org