diff options
author | Lorenzo Bianconi <lorenzo@kernel.org> | 2024-02-12 10:50:56 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2024-02-13 19:22:30 -0800 |
commit | e6d5dbdd20aa6a86974af51deb9414cd2e7794cb (patch) | |
tree | fe6622efbfe294d1c1d31cdc1d4b9e39e143702f /include | |
parent | 4d2bb0bfe8741a8778e0053f31a4e0f0cba80e8b (diff) | |
download | lwn-e6d5dbdd20aa6a86974af51deb9414cd2e7794cb.tar.gz lwn-e6d5dbdd20aa6a86974af51deb9414cd2e7794cb.zip |
xdp: add multi-buff support for xdp running in generic mode
Similar to native xdp, do not always linearize the skb in
netif_receive_generic_xdp routine but create a non-linear xdp_buff to be
processed by the eBPF program. This allow to add multi-buffer support
for xdp running in generic mode.
Acked-by: Jesper Dangaard Brouer <hawk@kernel.org>
Reviewed-by: Toke Hoiland-Jorgensen <toke@redhat.com>
Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
Link: https://lore.kernel.org/r/1044d6412b1c3e95b40d34993fd5f37cd2f319fd.1707729884.git.lorenzo@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/skbuff.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index 2dde34c29203..def3d8689c3d 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h @@ -3446,6 +3446,8 @@ static inline void skb_frag_ref(struct sk_buff *skb, int f) __skb_frag_ref(&skb_shinfo(skb)->frags[f]); } +int skb_cow_data_for_xdp(struct page_pool *pool, struct sk_buff **pskb, + struct bpf_prog *prog); bool napi_pp_put_page(struct page *page, bool napi_safe); static inline void |