netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] i40e: fix regression that enables AF_XDP ZC unconditionally
@ 2019-02-12  8:52 Björn Töpel
  2019-02-12  8:52 ` [PATCH 1/2] i40e: move i40e_xsk_umem function Björn Töpel
  2019-02-12  8:52 ` [PATCH 2/2] i40e: add tracking of AF_XDP ZC state for each queue pair Björn Töpel
  0 siblings, 2 replies; 5+ messages in thread
From: Björn Töpel @ 2019-02-12  8:52 UTC (permalink / raw)
  To: intel-wired-lan
  Cc: Björn Töpel, magnus.karlsson, magnus.karlsson, netdev,
	jan.sokolowski

This series addresses a recent AF_XDP zero-copy regression.

In commit f3fef2b6e1cc ("i40e: Remove umem from VSI") a regression was
introduced; When the VSI was reset, the setup code would try to enable
AF_XDP ZC unconditionally (as long as there was a umem placed in the
netdev._rx struct). Here, we add a bitmap to the VSI that tracks if a
certain queue pair has been "zero-copy enabled" via the ndo_bpf. The
bitmap is used in i40e_xsk_umem, and enables zero-copy if and only if
XDP is enabled, the corresponding qid in the bitmap is set and the
umem is non-NULL.

Thanks,
Björn


Björn Töpel (2):
  i40e: move i40e_xsk_umem function
  i40e: add tracking of AF_XDP ZC state for each queue pair

 drivers/net/ethernet/intel/i40e/i40e.h      | 16 ++----------
 drivers/net/ethernet/intel/i40e/i40e_main.c | 28 +++++++++++++++++++++
 drivers/net/ethernet/intel/i40e/i40e_xsk.c  |  3 +++
 3 files changed, 33 insertions(+), 14 deletions(-)

-- 
2.19.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-02-16  2:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-12  8:52 [PATCH 0/2] i40e: fix regression that enables AF_XDP ZC unconditionally Björn Töpel
2019-02-12  8:52 ` [PATCH 1/2] i40e: move i40e_xsk_umem function Björn Töpel
2019-02-16  2:54   ` Brown, Aaron F
2019-02-12  8:52 ` [PATCH 2/2] i40e: add tracking of AF_XDP ZC state for each queue pair Björn Töpel
2019-02-16  2:54   ` Brown, Aaron F

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).