]> git.baikalelectronics.ru Git - kernel.git/commit
dpaa2-eth: Release buffers back to pool on XDP_DROP
authorIoana Ciocoi Radulescu <ruxandra.radulescu@nxp.com>
Mon, 26 Nov 2018 16:27:31 +0000 (16:27 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 28 Nov 2018 18:57:45 +0000 (10:57 -0800)
commit07313def0aea49d563417cb0b54d8f8fe7d9bb94
tree2e4bfac82b2123320f1722797932c07257c716d5
parent6175e916fc037b9ceda4b76cb9d54b1e4591119c
dpaa2-eth: Release buffers back to pool on XDP_DROP

Instead of freeing the RX buffers, release them back into the pool.
We wait for the maximum number of buffers supported by a single
release command to accumulate before issuing the command.

Also, don't unmap the Rx buffers at the beginning of the Rx routine
anymore, since that would require remapping them before release.
Instead, just do a DMA sync at first and only unmap if the frame is
meant for the stack.

Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c
drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.h