sfc: perform XDP processing on received packets
authorCharles McLachlan <cmclachlan@solarflare.com>
Thu, 31 Oct 2019 10:23:23 +0000 (10:23 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 31 Oct 2019 21:14:53 +0000 (14:14 -0700)
commiteb9a36be7f3ec414700af9a616f035eda1f1e63e
tree07822b06a1e1cae2a4b4282ad42e1ce8e3bf0ff0
parent8c42350116fe4ad23a5a813eba367355cfe7cff5
sfc: perform XDP processing on received packets

Adds a field to hold an attached xdp_prog, but never populates it (see
following patch).  Also, XDP_TX support is deferred to a later patch
in the series.

Track failures of xdp_rxq_info_reg() via per-queue xdp_rxq_info_valid
flags and a per-nic xdp_rxq_info_failed flag. The per-queue flags are
needed to prevent attempts to xdp_rxq_info_unreg() structs that failed
to register.  Possibly the API could be changed in the future to avoid
the need for these flags.

Signed-off-by: Charles McLachlan <cmclachlan@solarflare.com>
Acked-by: Jesper Dangaard Brouer <brouer@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/sfc/efx.c
drivers/net/ethernet/sfc/net_driver.h
drivers/net/ethernet/sfc/rx.c