On Thu Sep 10, 2026 at 7:02 AM PDT, Jakub Sitnicki wrote:
That said, as things stand we have already established in v1 [3] that for
our existing use case - attaching metadata to <1% of skbs - the
so you'll be using this bpf_skb_ext only on <1% of skb-s ?
How about we add a bit in skb 'special_cleanup' or something.
If set it will trigger a new tracepoint during kfree_skb/consume_skb.
Then use bpf_rhashtable, populate when necessary, set bit,
attach to that new tracepoint and delete from rhash where key==skb.
bpf_rhash is specifically optimized for 8-byte keys.
I suspect it would be faster than this approach.
Overall this approach is fine from bpf perspective, but if it can be
done with 1 bit + tracepoint approach that would be better.