Calculating a hash from a eBPF program?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



[This isn't strictly an XDP question, I'm using cls_bpf but I don't
know of a better place to ask]

Is there a way to calculate a hash of a struct or other data from
within an eBPF program? I need to build a classifier that can hash a
flow encapsulated in protocols like PPPoE or GTP-U. Basically like
cls_flow's use of jhash2 but at a different offset. I looked at the
helpers in bpf.h but don't see anything helpful there.

Thanks.



[Index of Archives]     [Linux Networking Development]     [Fedora Linux Users]     [Linux SCTP]     [DCCP]     [Gimp]     [Yosemite Campsites]

  Powered by Linux