Update module github.com/cilium/ebpf to v0.12.2 #98
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
v0.10.0
->v0.12.2
Warning
Some dependencies could not be looked up. Check the Dependency Dashboard for more information.
Release Notes
cilium/ebpf (github.com/cilium/ebpf)
v0.12.2
Compare Source
This release fixes unmarshaling from a map operation into a
[]byte
, see #1180. This is a regression in v0.12.0.We now also properly return an error when the value to unmarshal into is too small, see #1181. This behaviour has existed for a long time.
What's Changed
New Contributors
Full Changelog: cilium/ebpf@v0.12.1...v0.12.2
v0.12.1
Compare Source
Fixes
Fix ProgramInfo.Instructions failing to decode ExtInfos
A recent change to ProgramInfo.Instructions failed to take a difference between kernel and ELF wire format into account. This meant that retrieving the instructions of a program from the kernel failed with a error.
See #1168, fixed by #1169.
Fix reading auxv on 32-bit platforms
The code to determine the kernel version from vdso has been broken on 32-bit platforms. Note that 32-bit arches are not officially supported to the fix is best effort.
See #1133, fixed by #1144.
What's Changed
Full Changelog: cilium/ebpf@v0.12.0...v0.12.1
v0.12.0
Compare Source
This release requires at least Go 1.20. It is mainly a bugfix release without any expected breaking changes. Map operations have also been made faster on the Go side.
Fixes
Correctly freeze
.rodata
maps.rodata
maps were frozen after programs referring to them were loaded, preventing the verifier from eliminating dead code based on the contents of the.rodata
maps. Upgrade if you're running into odd verifier errors that don't occur on libbpf.See https://github.com/cilium/ebpf/pull/1159.
Fix fd leak in error path of kfunc support
The library leaked file descriptors when trying to use non-existent kfuncs.
See https://github.com/cilium/ebpf/pull/1145.
Fix incorrect formatting of signed BTF enums with negative values
Signed enums with negative values were incorrectly formatted, leading to invalid output from
bpf2go
.See https://github.com/cilium/ebpf/pull/1155.
Additions
Map operations using common types are much faster
Keys and values used in map operations were indiscriminately passed through the
encoding/binary
package. There is now a fast path which skips this step when the in-memory layout of a type is equivalent to the output produced bybinary.Write
. The result is less allocations and CPU usage.The optimization doesn't apply to per-CPU maps.
See https://github.com/cilium/ebpf/pull/1062.
What's Changed
New Contributors
Full Changelog: cilium/ebpf@v0.11.0...v0.12.0
v0.11.0
: Support for __ksym and __kfuncCompare Source
Breaking changes
This release requires at least Go 1.19.
github.com/cilium/ebpf/btf:
Handle.Spec()
now takes abase *Spec
argument.nil
is accepted if the Handle is for vmlinux. If Handle is for a (split BTF) kernel module, pass the result ofLoadKernelSpec()
.NewHandle()
now takes a*Builder
instead of a*Spec
.Loading BTF into the kernel now goes via a new
Builder
type. See the 'Additions' section below.github.com/cilium/ebpf/link:
The old API didn't take 32-bit architectures into account.
Fixes
Work around the kernel rejecting some Datasec
The kernel erroneously rejects Datasec where a Typedef, Volatile, Const, Restrict or typeTag follows a Pointer, Struct, Union or Array. There is now a workaround in place, see https://github.com/cilium/ebpf/pull/954.
Marshaling Map keys and values is more efficient
The marshaling code in the library now uses
sync.Pool
to re-usebytes.Buffer
, which makes common map operations cheaper, see https://github.com/cilium/ebpf/pull/1053.CO-RE relocations are a lot more efficient
The CO-RE code now does much less copying of BTF types, which makes CO-RE relocation a lot faster, especially against large types such as
sk_buff
. See https://github.com/cilium/ebpf/pull/1084.Additions
__ksym
(kfunc) supportIt's now possible to use new-style BPF helpers aka
kfunc
with the library. Going forward, all new BPF 'helper' functionality in the kernel will be exposed as kfuncs, and new helpers won't be added. See https://github.com/cilium/ebpf/pull/966 and https://github.com/cilium/ebpf/pull/996.__kconfig
supportTracing programs often need to vary their behaviour based on kernel configuration, such as
CONFIG_HZ
. Such references to__kconfig
variables are now automatically populated from a variety of sources such as/proc/config.gz
. Note that if you run your application implementing ebpf-go in a container, it will need access to the host's /boot on some distributions that don't ship /proc/config(.gz). (notably, Debian-based distros)As a special mention, the
LINUX_HAS_SYSCALL_WRAPPER
kconfig is also supported. This allows writing portable kprobes using theBPF_KSYSCALL
macro frombpf_tracing.h
.See https://github.com/cilium/ebpf/pull/951, https://github.com/cilium/ebpf/pull/960 and https://github.com/cilium/ebpf/pull/995.
Overwritable perf buffer support
The perf reader now allows creating "overwritable" perf buffers, which always contain the most recent events in case the buffer ever gets full. This is in contrast to regular perf buffers which drop recent events if there is no more space. This is useful to implement "flight recorder" type functionality for events sourced from BPF.
See https://github.com/cilium/ebpf/pull/953.
btf.Builder
Constructing custom BTF type blobs is now possible through the new
btf.Builder
type. Callbtf.NewBuilder()
to obtain one,Builder.Add(t btf.Type)
to add any types you need, followed bybtf.NewHandle(b btf.Builder)
to load the types into the kernel. Builder also has aMarshal()
method for serializing the type collection into the canonical BTF format so it can be stored for later use.What's Changed
+build
Go build tags by @ti-mo in https://github.com/cilium/ebpf/pull/888platformPrefix
list with libbpf values by @paulcacheux in https://github.com/cilium/ebpf/pull/982LINUX_HAS_SYSCALL_WRAPPER
kconfig by @paulcacheux in https://github.com/cilium/ebpf/pull/995container-all
make invocation by @paulcacheux in https://github.com/cilium/ebpf/pull/1021New Contributors
Full Changelog: cilium/ebpf@v0.10.0...v0.11.0
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Enabled.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.