Re: [PATCH net] net: change skb->mac_header when Generic XDP calls adjust_head

2017-09-20 Thread David Miller
From: Edward Cree Date: Tue, 19 Sep 2017 18:45:56 +0100 > Since XDP's view of the packet includes the MAC header, moving the start- > of-packet with bpf_xdp_adjust_head needs to also update the offset of the > MAC header (which is relative to skb->head, not to the

[PATCH net] net: change skb->mac_header when Generic XDP calls adjust_head

2017-09-19 Thread Edward Cree
Since XDP's view of the packet includes the MAC header, moving the start- of-packet with bpf_xdp_adjust_head needs to also update the offset of the MAC header (which is relative to skb->head, not to the skb->data that was changed). Without this, tcpdump sees packets starting from the old MAC