v0.24.0
github-actions
released this
07 Aug 21:20
·
111 commits
to refs/heads/master
since this release
What's Changed
libbpf-rs
- Split
{Open,}{Map,Program}
into{Open,}{Map,Program}
(for shared access) and{Open,}{Map,Program}Mut
(for exclusive access) - Added
AsRawLibbpf
impl forOpenObject
andObjectBuilder
- Decoupled
Map
andMapHandle
more and introducedMapCore
trait abstracting over common functionality - Adjusted
SkelBuilder::open
method to require mutable reference to storage space for BPF object - Adjusted
{Open,}Object::from_ptr
constructor to be infallible - Added
{Open,}Object::maps{_mut,}
and{Open,}Object::progs{_mut,}
for BPF map and program iteration - Adjusted various APIs to return/use
OsStr
instead ofCStr
orstr
- Adjusted
{Open,}Program
to lazily retrieve name and section- Changed
name
andsection
methods to return&OsStr
and made constructors infallible
- Changed
- Adjusted
OpenObject::name
to returnOption<&OsStr>
- Removed
Result
return type fromOpenProgram::{set_log_level,set_autoload,set_flags}
- Added
Object::name
method - Added
Copy
andClone
impls for types insidebtf::types
module - Adjusted
OpenMap::set_inner_map_fd
to returnResult
- Adjusted
ProgramInput::context_in
field to be a mutable reference - Made inner
query::Tag
contents publicly accessible - Fixed potential memory leak in
RingBufferBuilder::build
- Removed
Display
implementation of variousenum
types
libbpf-cargo
- Reworked generated skeletons to contain publicly accessible maps and program members, no longer requiring method calls
- Adjusted skeleton creation logic to generate Rust types for all types available in BPF
- Renamed module for generated Rust types from
<project>_types
to justtypes
- Renamed generated
struct_ops
type toStructOps
and moved it out oftypes
module - Fixed Rust code generation logic to properly create
Default
impl for arrays of pointers
New Contributors
Full Changelog: v0.23.3...v0.24.0