bpftool v6.8
New features
- Implement
bpftool gen min_core_btf
to generate the minimal BTF file necessary to load a program - Add C++-specific skeleton wrappers
- Restore support for probing BPF features on hardware (such as Netronome SmartNICs)
- Add
bpf_cookie
tobpftool link
output - Add support for generating sub-skeletons for “incomplete” BPF object files
- Defaults to sysfs vmlinux when dumping BTF objects and no base BTF was specified
- Extend skeletons for LSM programs to create links
- Add name for
trace_kprobe_multi
attach type - Add name for
syscall
program types - Add names for
xdp
,perf_event
,kprobe_multi
link types - Add distinction, for feature probes, between reversible or permanent disabling of
bpf()
syscall for unprivileged users - Handle better the probing of BPF helpers for programs types that are not available
- Assert type sizes in BPF skeletons
- Expand autogeneration warnings in skeletons by mentioning bpftool
Bug fixes
- Fix error when looking up for keys in map with no associated BTF information
- Fix pretty-print dump for maps with no associated BTF information
- Fix formatting of
bytes_memlock
for JSON map listing - Show process PIDs for BPF maps even if there is no associated BTF id or the map is frozen
- Add the description of missing commands in the top-level
bpftool.8
man page - Handle
libbpf_probe_prog_type()
andlibbpf_probe_bpf_helper()
errors correctly in feature probing
Other internal changes
- Switch to libbpf's API to lift the rlimit restriction, on legacy systems without memcg-based memory accounting for BPF
- Replace the use of libc's
reallocarray()
with the implementation from libbpf - Remove redundant slashes in Makefile
Known bugs
- Some features requiring the use of “skeletons” (
feature-clang-bpf-co-re
compilation option) require kernel 5.15 or more recent, withCONFIG_PERF_EVENTS
set, to compile bpftool (#17).
Full Changelog: v6.7.0...v6.8.0