]> asedeno.scripts.mit.edu Git - linux.git/commit
ixgbevf: Fix coexistence of malicious driver detection with XDP
authorAlexander Duyck <alexander.h.duyck@intel.com>
Tue, 22 May 2018 15:44:29 +0000 (11:44 -0400)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Mon, 4 Jun 2018 17:17:55 +0000 (10:17 -0700)
commit4be87727d4aebe36913d9f2a6806724cb593516f
tree47fd6cbdce8da1f1eae174e23615e827b13f6c68
parent06140c793db51476585ee9abf032845e221982cb
ixgbevf: Fix coexistence of malicious driver detection with XDP

In the case of the VF driver it is supposed to provide a context descriptor
that allows us to provide information about the header offsets inside of
the frame. However in the case of XDP we don't really have any of that
information since the data is minimally processed. As a result we were
seeing malicious driver detection (MDD) events being triggered when the PF
had that functionality enabled.

To address this I have added a bit of new code that will "prime" the XDP
ring by providing one context descriptor that assumes the minimal setup of
an Ethernet frame which is an L2 header length of 14. With just that we can
provide enough information to make the hardware happy so that we don't
trigger MDD events.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/ixgbevf/ixgbevf.h
drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c