bpf: fix virtio-net's length calc for XDP_PASS
In commit 6870de43 ("bpf: make virtio compatible w/ bpf_xdp_adjust_tail") i didn't account for vi->hdr_len during new packet's length calculation after bpf_prog_run in receive_mergeable. because of this all packets, if they were passed to the kernel, were truncated by 12 bytes. Fixes:6870de43 ("bpf: make virtio compatible w/ bpf_xdp_adjust_tail") Reported-by: NDavid Ahern <dsahern@gmail.com> Signed-off-by: NNikita V. Shirokov <tehnerd@tehnerd.com> Acked-by: NJason Wang <jasowang@redhat.com> Signed-off-by: NDaniel Borkmann <daniel@iogearbox.net>
Showing
想要评论请 注册 或 登录