Thread View: linux.kernel.netdev
1 messages
1 total messages
Started by patchwork-bot+netdevbpf
Tue, 10 Nov 2026 14:30
Re: [PATCH net 0/2] net: fix mac_len of skbs copied by generic XDP
Author: patchwork-bot+netdevbpf
Date: Tue, 10 Nov 2026 14:30
Date: Tue, 10 Nov 2026 14:30
35 lines
9523 bytes
9523 bytes
Hello:
This series was applied to netdev/net.git (main)
by Paolo Abeni <pabeni@redhat.com>:
On Tue, 3 Nov 2026 20:00:35 +0000 you wrote:
> Generic XDP copies the skb before it runs a program with frags support.
> The copy happens when the skb is cloned, nonlinear, or has less than 256
> bytes of headroom. skb_pp_cow_data() makes the copy, but it does not
> copy mac_len. After XDP, the skb has mac_len 0.
>
> Two places after generic XDP move skb->data by mac_len:
> - On XDP_REDIRECT to a cpumap, cpu_map_generic_redirect() pulls mac_len
> bytes, the length of the Ethernet header. Then it queues the skb to
> the target CPU. With mac_len 0, the IP layer on that CPU sees the
> Ethernet header and drops the packet.
> - On XDP_PASS, the skb can go on to tc ingress with a BPF program
> attached (tcx, cls_bpf or act_bpf). Before it runs the program, tc
> pushes mac_len bytes, the length of the Ethernet header. With
> mac_len 0, skb->data stays at the IP header. Therefore, the program
> reads the IP header as the Ethernet header.
>
> [...]
Here is the summary with links:
- [net,1/2] net: fix mac_len of skbs copied by generic XDP
https://git.kernel.org/netdev/net/c/71578e43b8a6
- [net,2/2] selftests: drv-net: ping: test generic XDP redirect to cpumap
https://git.kernel.org/netdev/net/c/71b116cf334b
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads