diff options
author | Amery Hung <amery.hung@bytedance.com> | 2025-04-10 00:45:59 +0300 |
---|---|---|
committer | Martin KaFai Lau <martin.lau@kernel.org> | 2025-04-17 20:54:40 +0300 |
commit | 870c28588afa20d786e2c26e8fcc14e2b9a55616 (patch) | |
tree | 0b04016a3c18d4bd7b463ee3937c7dc8a4f249bb /tools/perf/scripts/python/stackcollapse.py | |
parent | c8240344956e3f0b4e8f1d40ec3435e47040cacb (diff) | |
download | linux-870c28588afa20d786e2c26e8fcc14e2b9a55616.tar.xz |
bpf: net_sched: Add basic bpf qdisc kfuncs
Add basic kfuncs for working on skb in qdisc.
Both bpf_qdisc_skb_drop() and bpf_kfree_skb() can be used to release
a reference to an skb. However, bpf_qdisc_skb_drop() can only be called
in .enqueue where a to_free skb list is available from kernel to defer
the release. bpf_kfree_skb() should be used elsewhere. It is also used
in bpf_obj_free_fields() when cleaning up skb in maps and collections.
bpf_skb_get_hash() returns the flow hash of an skb, which can be used
to build flow-based queueing algorithms.
Finally, allow users to create read-only dynptr via bpf_dynptr_from_skb().
Signed-off-by: Amery Hung <amery.hung@bytedance.com>
Signed-off-by: Martin KaFai Lau <martin.lau@kernel.org>
Acked-by: Toke Høiland-Jørgensen <toke@redhat.com>
Link: https://patch.msgid.link/20250409214606.2000194-4-ameryhung@gmail.com
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions