# Packages
No description provided by the author
No description provided by the author
No description provided by the author
Package kconfig implements a parser for the format of Linux's .config file.
Package linux contains OS specific wrappers around package unix.
Package sys contains bindings for the BPF syscall.
Package sysenc provides efficient conversion of Go values to system call interfaces.
No description provided by the author
No description provided by the author
Package unix re-exports Linux specific parts of golang.org/x/sys/unix.
# Functions
Align returns 'n' updated to 'alignment' boundary.
Between returns the value clamped between a and b.
ErrorWithLog wraps err in a VerifierError that includes the parsed verifier log buffer.
GoTypeName is like %T, but elides the package name.
Identifier turns a C style type or field name into an exportable Go equivalent.
IsPow returns true if n is a power of two.
NewBuffer retrieves a [bytes.Buffer] from a pool an re-initialises it.
NewBufferedSectionReader wraps an io.ReaderAt in an appropriately-sized buffered reader.
No description provided by the author
NewFeatureTest is a convenient way to create a single [FeatureTest].
NewSafeELFFile reads an ELF safely.
NewVersion creates a version from a string like "Major.Minor.Patch".
NewVersionFromCode creates a version from a LINUX_VERSION_CODE.
OpenSafeELFFile reads an ELF from a file.
PutBuffer releases a buffer to the pool.
ReadAllCompressed decompresses a gzipped file into memory.
ReadUint64FromFile reads a uint64 from a file.
ReadUint64FromFileOnce is like readUint64FromFile but memoizes the result.
WriteFormatted outputs a formatted src into out.
# Constants
Version constant used in ELF binaries indicating that the loader needs to substitute the eBPF program's version with the value of the kernel's KERNEL_VERSION compile-time macro.
No description provided by the author
# Variables
EmptyBPFContext is the smallest-possible BPF input context to be used for invoking `Program.{Run,Benchmark,Test}`.
ErrNotSupported indicates that a feature is not supported.
ErrNotSupportedOnOS indicates that a feature is not supported on the current operating system.
NativeEndian is set to either binary.BigEndian or binary.LittleEndian, depending on the host's endianness.
# Structs
Deque implements a double ended queue.
DiscardZeroes makes sure that all written bytes are zero before discarding them.
FeatureCache caches a potentially unlimited number of feature probes.
FeatureTest caches the result of a [FeatureTestFn].
No description provided by the author
UnsupportedFeatureError is returned by FeatureTest() functions.
VerifierError includes information from the eBPF verifier.
# Interfaces
Integer represents all possible integer types.
# Type aliases
FeatureMatrix groups multiple related feature tests into a map.
FeatureTestFn is used to determine whether the kernel supports a certain feature.
A Version in the form Major.Minor.Patch.