diff options
author | Charles McLachlan <cmclachlan@solarflare.com> | 2019-10-31 13:23:10 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-11-01 00:14:53 +0300 |
commit | 8c42350116fe4ad23a5a813eba367355cfe7cff5 (patch) | |
tree | 89adf3d5d692af9fc49304e6aaffd01c9d0a30b8 /drivers/net/ethernet/sfc/tx.c | |
parent | d170eb69d40e9e5fccb8d57edbbacb97427dcf1c (diff) | |
download | linux-8c42350116fe4ad23a5a813eba367355cfe7cff5.tar.xz |
sfc: support encapsulation of xdp_frames in efx_tx_buffer
Add a field to efx_tx_buffer so that we can track xdp_frames. Add a
flag so that buffers that contain xdp_frames can be identified and
passed to xdp_return_frame.
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>
Diffstat (limited to 'drivers/net/ethernet/sfc/tx.c')
-rw-r--r-- | drivers/net/ethernet/sfc/tx.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/sfc/tx.c b/drivers/net/ethernet/sfc/tx.c index 65e81ec1b314..204aafb3d96a 100644 --- a/drivers/net/ethernet/sfc/tx.c +++ b/drivers/net/ethernet/sfc/tx.c @@ -95,6 +95,8 @@ static void efx_dequeue_buffer(struct efx_tx_queue *tx_queue, netif_vdbg(tx_queue->efx, tx_done, tx_queue->efx->net_dev, "TX queue %d transmission id %x complete\n", tx_queue->queue, tx_queue->read_count); + } else if (buffer->flags & EFX_TX_BUF_XDP) { + xdp_return_frame_rx_napi(buffer->xdpf); } buffer->len = 0; |