tools: bpftool: add raw_tracepoint_writable prog type to header
Subsystems (4)
PATCH 1/1 tools: bpftool: add raw_tracepoint_writable prog type to header
From commit 9df1c28bb752 ("bpf: add writable context for raw tracepoints"), a new type of BPF_PROG, RAW_TRACEPOINT_WRITABLE has been added.
Since this BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLE is not listed at bpftool's header, it causes a segfault when executing 'bpftool feature'.
This commit adds BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLE entry to prog_type_name enum, and will eventually fixes the segfault issue.
--- tools/bpf/bpftool/main.h | 1 + 1 file changed, 1 insertion(+)
tools/bpf/bpftool/main.h +1 -0
@@ -74,6 +74,7 @@ static const char * const prog_type_name[] = { [BPF_PROG_TYPE_SK_REUSEPORT] = "sk_reuseport", [BPF_PROG_TYPE_FLOW_DISSECTOR] = "flow_dissector", [BPF_PROG_TYPE_CGROUP_SYSCTL] = "cgroup_sysctl", + [BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLE] = "raw_tracepoint_writable", [BPF_PROG_TYPE_CGROUP_SOCKOPT] = "cgroup_sockopt", };
Signature · 1 line
2.17.1
Quoted 10 lines · Daniel T. Lee
From commit
9df1c28bb752("bpf: add writable context for raw tracepoints"), a new type ofBPF_PROG,RAW_TRACEPOINT_WRITABLEhas been added.Since this
BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLEis not listed at bpftool's header, it causes a segfault when executing 'bpftool feature'.This commit adds
BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLEentry toprog_type_nameenum, and will eventually fixes the segfault issue.Signed-off-by Daniel T. Lee <[email protected]>
Applied, thanks!