Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

libbpf: Add "tc" SEC_DEF which is a better name for "classifier"

As argued in [0], add "tc" ELF section definition for SCHED_CLS BPF
program type. "classifier" is a misleading terminology and should be
migrated away from.

[0] https://lore.kernel.org/bpf/270e27b1-e5be-5b1c-b343-51bd644d0747@iogearbox.net/

Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20210928161946.2512801-2-andrii@kernel.org

authored by

Andrii Nakryiko and committed by
Alexei Starovoitov
9673268f 29eef85b

+1
+1
tools/lib/bpf/libbpf.c
··· 7968 7968 .attach_fn = attach_kprobe), 7969 7969 BPF_PROG_SEC("uretprobe/", BPF_PROG_TYPE_KPROBE), 7970 7970 BPF_PROG_SEC("classifier", BPF_PROG_TYPE_SCHED_CLS), 7971 + BPF_PROG_SEC("tc", BPF_PROG_TYPE_SCHED_CLS), 7971 7972 BPF_PROG_SEC("action", BPF_PROG_TYPE_SCHED_ACT), 7972 7973 SEC_DEF("tracepoint/", TRACEPOINT, 7973 7974 .attach_fn = attach_tp),