Wrap SYS_BPF errors, user-provided uprobe offsets, support new map, program and flag types
Breaking changes
- None
Features
- Return friendly error when creating maps with
BPF_F_MMAPABLE
orBPF_F_INNER_MAP
and the kernel doesn't support them. - Add support for StructOps, RingBuf, InodeStorage and TaskStorage map types.
- Support many new BPF program types added over the course of 2019/2020 in the assembler.
- Detect
fentry
,fmod_ret
andfexit
programs by their ELF section names. - link: support user-provided offsets for uprobe locations by specifying
UprobeOptions
. - link: support creating bpf_map_elem iterators
- Wrap and propagate all errors generated by SYS_BPF, allowing the caller to retrieve
Bug Fixes
- Fix flaky TestMapPin test on Go 1.17beta1
Deprecations
ebpf.ErrNotExist
is now an alias toos.ErrNotExist
and will be removed in a future release.
Examples
- Docstring fixup in kprobe example
Contributors
Chris Tarazi
Lorenz Bauer
Mattia Meleleo
Mikko Ylinen
Robin Gögge
Tobias Klauser
Thank you for your work!