diff mbox series

[RFC,v1,02/15] mvneta: add XDP frame size to driver

Message ID 158446615781.702578.17438189744745816482.stgit@firesoul
State RFC
Delegated to: BPF Maintainers
Headers show
Series XDP extend with knowledge of frame size | expand

Commit Message

Jesper Dangaard Brouer March 17, 2020, 5:29 p.m. UTC
This marvell driver mvneta uses PAGE_SIZE frames, which makes it
really easy to convert.  It also only updated rxq and now frame_sz
once per NAPI call.

Cc: thomas.petazzoni@bootlin.com
Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com>
---
 drivers/net/ethernet/marvell/mvneta.c |    1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/drivers/net/ethernet/marvell/mvneta.c b/drivers/net/ethernet/marvell/mvneta.c
index 1c391f63a26f..e6c6524f63a5 100644
--- a/drivers/net/ethernet/marvell/mvneta.c
+++ b/drivers/net/ethernet/marvell/mvneta.c
@@ -2310,6 +2310,7 @@  static int mvneta_rx_swbm(struct napi_struct *napi,
 	rcu_read_lock();
 	xdp_prog = READ_ONCE(pp->xdp_prog);
 	xdp_buf.rxq = &rxq->xdp_rxq;
+	xdp_buf.frame_sz = PAGE_SIZE;
 
 	/* Fairness NAPI loop */
 	while (rx_proc < budget && rx_proc < rx_todo) {