v0.9.2
This release contains an important bugfix for users of Program.Test()
and .Benchmark()
. A kernel change was made that disallows empty packet buffers, with knock-on effects to BPF_PROG_RUN
and, as a result, ebpf-go's detection routine for said feature. Users are strongly encouraged to upgrade. See #788 for more details.
The new features.HaveMapFlag()
API was merged in this release, congrats @paulcacheux!
Likewise, the link.K(ret)probeMulti()
API was added by @mmat11, bringing blazingly-fast bulk kprobe attachments to kernels 5.18 and newer.
Some improvements were made to verifier log handling. The VerifierError.Truncated
flag can now reliably be used to determine if a program load should be retried due to the provided buffer size being too small. Use this to retry with incrementally growing log buffers for large or complex programs. The Log*
fields in ProgramOptions
are now thoroughly documented to this effect.
It also bumps the minimum Go version to 1.18, since 1.19 is now out.
What's Changed
- run-tests: show curl error messages by @lmb in #738
- elf_reader: only read data from PROGBITS sections, ignore NOBITS by @ti-mo in #740
- program: support tracing of kernel modules by @lmb in #737
- CI: Test against kernel 5.18 by @ti-mo in #668
- internal: fix VerifierError output with empty log by @lmb in #743
- elf_reader: Allow strings read-only global data sections by @dylandreimerink in #742
- CI: expose individual test results by @lmb in #748
- Fix arm64 testsuite failures by @lmb in #745
- link: (u|k)probe: don't treat EINVAL as os.ErrNotExist by @ti-mo in #751
- features: remove EPERM wrapping exception, automatically wrap errors by @ti-mo in #749
- features: implement probes for StructOps maps and programs by @ti-mo in #746
- perf add timeout argument by @xpu22 in #736
- epoll deadline fixups by @lmb in #758
- prog: unconditionally enable verifier retries, add consts, document LogLevel by @ti-mo in #754
- program: fix comment typo by @wozniakjan in #764
- bpf2go: replace deprecated io/ioutil function by @florianl in #762
- btf: minimal support for BTF_KIND_DECL_TAG and BTF_KIND_TYPE_TAG by @lmb in #747
- features: add HaveMapFlag API by @paulcacheux in #673
- Build, test and format with Go 1.19, minimum 1.18 by @ti-mo in #765
- errors: remove verifier truncation heuristic, rely on ENOSPC by @ti-mo in #756
- examples: clarify how to rebuild by @lmb in #767
- feature: define
sys.MapFlags
and re-export it for map flags feature detection by @paulcacheux in #766 - cmd/bpf2go: clarify -target usage with bpf_tracing.h by @lmb in #773
- examples: add sockops example by @BigMikes in #771
- features: fix incorrect lock in probeMisc by @lmb in #775
- link: memoize PMU event types read from sysfs by @lmb in #774
- btf: handle signed enums and fix default signedness by @lmb in #781
- iter: Add support to load sleepable iterator program type by @olsajiri in #777
- Correct misleading unpin error in progAttachCgroup by @weiqiangt in #787
- Fix haveProgTestRun on kernel version 5.15.65 by @player-two in #788
- Provide 15-byte context inputs to
Program.{Run,Benchmark,Test}
by @ti-mo in #792 - link: implement kprobe.multi link by @mmat11 in #716
New Contributors
- @wozniakjan made their first contribution in #764
- @weiqiangt made their first contribution in #787
- @player-two made their first contribution in #788
Full Changelog: v0.9.1...v0.9.2