Go to file
Stefan Puiu 8fce14b789 net/vmxnet3: fix Rx deadlock
Our use case is that we have an app that needs to keep mbufs around
for a while. We've seen cases when calling vmxnet3_post_rx_bufs() from
vmxet3_recv_pkts(), it might not succeed to add any mbufs to any RX
descriptors (where it returns -err). Since there are no mbufs that the
virtual hardware can use, no packets will be received after this; the
driver won't refill the mbuf after this so it gets stuck in this
state. I call this a deadlock for lack of a better term - the virtual
HW waits for free mbufs, while the app waits for the hardware to
notify it for data (by flipping the generation bit on the used Rx
descriptors). Note that after this, the app can't recover.

This fix is a rework of this patch by Marco Lee:
http://dpdk.org/dev/patchwork/patch/6575/. I had to forward port
it, address review comments and also reverted the allocation
failure handling to the first version of the patch
(http://dpdk.org/ml/archives/dev/2015-July/022079.html), since
that's the only approach that seems to work, and seems to be what
other drivers are doing (I checked ixgbe and em). Reusing the mbuf
that's getting passed to the application doesn't seem to make
sense, and it was causing weird issues in our app. Also, reusing
rxm without checking if it's NULL could cause the code to crash.

Fixes: 14680e3747 ("vmxnet3: improve Rx performance")

Signed-off-by: Stefan Puiu <stefan.puiu@gmail.com>
Acked-by: Yong Wang <yongwang@vmware.com>
2017-01-17 19:40:51 +01:00
app app/testpmd: cleanup parameter checking 2017-01-17 19:39:28 +01:00
buildtools pmdinfogen: fix null dereference 2017-01-06 11:40:30 +01:00
config net/sfc: support firmware-assisted TSO 2017-01-17 19:40:51 +01:00
devtools devtools: skip capitalization check for commit prefixes 2017-01-13 17:03:43 +01:00
doc net/sfc: support firmware-assisted TSO 2017-01-17 19:40:51 +01:00
drivers net/vmxnet3: fix Rx deadlock 2017-01-17 19:40:51 +01:00
examples examples/ethtool: use ixgbe public function 2017-01-17 19:39:28 +01:00
lib ethdev: remove some VF functions 2017-01-17 19:40:50 +01:00
mk net/tap: add TUN/TAP device PMD 2017-01-17 19:40:50 +01:00
pkg tools: move to usertools 2017-01-04 21:17:32 +01:00
usertools tools: move to usertools 2017-01-04 21:17:32 +01:00
.gitattributes improve git diff 2016-11-13 15:25:12 +01:00
.gitignore doc: generate NIC overview table from ini files 2016-08-03 18:42:17 +02:00
GNUmakefile pmdinfogen: add buildtools and pmdinfogen utility 2016-07-06 22:34:39 +02:00
LICENSE.GPL doc: GPL/LGPL licenses 2013-07-25 14:43:06 +02:00
LICENSE.LGPL doc: fix file format (dos to unix) 2013-09-06 11:43:07 +02:00
MAINTAINERS net/tap: add TUN/TAP device PMD 2017-01-17 19:40:50 +01:00
Makefile remove trailing whitespaces 2014-06-11 00:29:34 +02:00
README doc: add readme file 2015-12-13 22:06:58 +01:00

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 license for the core libraries and
drivers. The kernel components are GPLv2 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