mirror of
https://github.com/torvalds/linux.git
synced 2026-09-22 20:54:03 +02:00
Merge branch 'xdp-metadata-support-for-dq-rda'
Joshua Washington says: ==================== XDP metadata support for DQ RDA This small series enables XDP metadata support in DQ RDA mode. While space is reserved in the headroom for metadata and the DQ queue format supports the xmo_rx_timestamp metadata operation, support for adjusting the metadata and passing metadata along to SKBs was not actually implemented. v2: https://lore.kernel.org/netdev/20260318192450.3400774-1-joshwash@google.com/ v1: https://lore.kernel.org/netdev/20260316230434.1398828-1-joshwash@google.com/ ==================== Link: https://patch.msgid.link/20260722221634.186886-1-joshwash@google.com Signed-off-by: Paolo Abeni <pabeni@redhat.com>
This commit is contained in:
commit
af2e7bf983
|
|
@ -770,8 +770,7 @@ static int gve_rx_xsk_dqo(struct napi_struct *napi, struct gve_rx_ring *rx,
|
|||
}
|
||||
|
||||
/* Copy the data to skb */
|
||||
rx->ctx.skb_head = gve_rx_copy_data(priv->dev, napi,
|
||||
xdp->data, buf_len);
|
||||
rx->ctx.skb_head = xdp_build_skb_from_zc(xdp);
|
||||
if (unlikely(!rx->ctx.skb_head)) {
|
||||
xsk_buff_free(xdp);
|
||||
gve_free_buf_state(rx, buf_state);
|
||||
|
|
@ -779,8 +778,6 @@ static int gve_rx_xsk_dqo(struct napi_struct *napi, struct gve_rx_ring *rx,
|
|||
}
|
||||
rx->ctx.skb_tail = rx->ctx.skb_head;
|
||||
|
||||
/* Free XSK buffer and Buffer state */
|
||||
xsk_buff_free(xdp);
|
||||
gve_free_buf_state(rx, buf_state);
|
||||
|
||||
/* Update Stats */
|
||||
|
|
@ -919,7 +916,7 @@ static int gve_rx_dqo(struct napi_struct *napi, struct gve_rx_ring *rx,
|
|||
buf_state->page_info.page_address +
|
||||
buf_state->page_info.page_offset,
|
||||
buf_state->page_info.pad,
|
||||
buf_len, false);
|
||||
buf_len, true);
|
||||
gve_xdp.gve = priv;
|
||||
gve_xdp.compl_desc = compl_desc;
|
||||
|
||||
|
|
@ -933,9 +930,17 @@ static int gve_rx_dqo(struct napi_struct *napi, struct gve_rx_ring *rx,
|
|||
return 0;
|
||||
}
|
||||
|
||||
rx->ctx.skb_head = xdp_build_skb_from_buff(&gve_xdp.xdp);
|
||||
if (unlikely(!rx->ctx.skb_head))
|
||||
goto error;
|
||||
rx->ctx.skb_tail = rx->ctx.skb_head;
|
||||
|
||||
gve_reuse_buffer(rx, buf_state);
|
||||
|
||||
u64_stats_update_begin(&rx->statss);
|
||||
rx->xdp_actions[XDP_PASS]++;
|
||||
u64_stats_update_end(&rx->statss);
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (eop && buf_len <= priv->rx_copybreak &&
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user