]> asedeno.scripts.mit.edu Git - linux.git/commit
iavf: allow null RX descriptors
authorMitch Williams <mitch.a.williams@intel.com>
Tue, 14 May 2019 17:37:09 +0000 (10:37 -0700)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Mon, 17 Jun 2019 22:39:26 +0000 (15:39 -0700)
commitefa14c3985828da3163f5372137cb64d992b0f79
tree3b2fa40bc5029a871cc45ebaf97b772f08edb7b6
parent68dfe6348f06945f900bfea803e1e030e7e158e6
iavf: allow null RX descriptors

In some circumstances, the hardware can hand us a null receive
descriptor, with no data attached but otherwise valid. Unfortunately,
the driver was ill-equipped to handle such an event, and would stop
processing packets at that point.

To fix this, use the Descriptor Done bit instead of the size to
determine whether or not a descriptor is ready to be processed. Add some
checks to allow for unused buffers.

Signed-off-by: Mitch Williams <mitch.a.williams@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/iavf/iavf_txrx.c