Re: TC bpf_csum_diff problems post-5.6 kernel

Thomas Ptacek <[email protected]>
Newsgroups org.kernel.vger.xdp-newbies
Message-ID <CANDGNva-tvC_D1qnJFaUSaqU_u4iRwEs1AYTGHg+-C3jKkkdGw@mail.gmail.com>
Thanks for the context!

I write back to the packet directly (I chain all the checksum updates
through a series of bpf_csum_diff() calls and then write back the
ultimate value).

Since we have a mixed fleet right now, I'm guessing I'm going to need
multiple versions of the TC BPF .o binary, since it looks like
bpf_skb_net_shrink() EINVAL's on 5.6 with that
BPF_F_ADJ_ROOM_NO_CSUM_RESET flag.

A small price to pay! Again: many thanks for this; this group is really great.

On Tue, Nov 2, 2021 at 5:28 PM Daniel Borkmann <[email protected]> wrote:
> For the update, did you use bpf_csum_update() helper or directly writing into
> the pkt?

---
Thomas H. Ptacek
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.