vmm-sys-util
A system utility set
0.15.0
11M downloads/mo
#2972 most downloaded on crates.io
rust-vmm/vmm-sys-util
What this package is like to depend on
Last release 1 years ago
07 Aug 2025
Ships fairly regularly
a new release about every 4 months
Some releases are documented
notes for 11 of 20 stable releases
2 versions withdrawn
withdrawn after publishing
7 years old
22 releases · first in 2019
0 releases in the last 12 months
see the full history below
Release timeline
22 releases · Oct 2019 to Aug 2025Releases
latest 22-
0.15.007 Aug 2025Release notes
Open source →Changelog
v0.15.0
Added
- [#245]: Make sock_ctrl_msg support non-linux unix platforms.
- [#244]:
- Impl
IntoRawFdforlinux::eventfd::EventFd. - Use
File::try_cloneto replace the original implementation ofEventFd::try_clone.
Some flags can now be propagated, likeCLOEXEC. - Add
EventNotifierandEventConsumeras a generic event notification
- Impl
Release notes
Open source →Added
- [#245]: Make sock_ctrl_msg support non-linux unix platforms.
- [#244]:
- Impl
IntoRawFdforlinux::eventfd::EventFd. - Use
File::try_cloneto replace the original implementation ofEventFd::try_clone. Some flags can now be propagated, likeCLOEXEC. - Add
EventNotifierandEventConsumeras a generic event notification
- Impl
-
0.14.022 May 2025Release notes
Open source →Changelog
Upcoming
v0.14.0
Changed
- [#240]: Remove
PartialEqtrait constraint onEntryin FAM module.
Release notes
Open source →Changed
- [#240]: Remove
PartialEqtrait constraint onEntryin FAM module.
- [#240]: Remove
-
0.13.031 Mar 2025Release notes
Open source →Changelog
v0.13.0
Added
- [#230]: Introduce align_downwards! and align_upwards! macro to help address aligning, this implementation is faster than div_ceil way and more robust.
- [#236]: Add a utility function for constructing an empty FamStructWrapper with a given header.
Changed
- [#228]: Make
Debugimpl forFamStructWrapper<T>print out contents of the flexible array member. This causesDebugto only be implemented ifT::Entry: Debug.
Removed
- [#235]: Removed
impl From<Vec<T>> for FamStructWrapper<T>, as this was unsound.
Release notes
Open source →Added
- [#230]: Introduce align_downwards! and align_upwards! macro to help address aligning, this implementation is faster than div_ceil way and more robust.
- [#236]: Add a utility function for constructing an empty FamStructWrapper with a given header.
Changed
- [#228]: Make
Debugimpl forFamStructWrapper<T>print out contents of the flexible array member. This causesDebugto only be implemented ifT::Entry: Debug.
Removed
- [#235]: Removed
impl From<Vec<T>> for FamStructWrapper<T>, as this was unsound.
-
0.12.102 Jan 2024Release notes
Open source →Changelog
v0.12.1
Changed
- [#215]: Make
as_mut_fam_struct()public and unsafe to let users modify fields of the header other than the length.
v0.12.0 (yanked)
Changed
- Added all features to the generated docs.rs documentation.
- Fixed a bug in
serdeimplementation ofFamStructWrapperwhich allowed out of bounds memory access from Rust-safe code. See the related GHSA here: GHSA-875g-mfp6-g7f9 for more information.
Release notes
Open source →Changed
- [#215]: Make
as_mut_fam_struct()public and unsafe to let users modify fields of the header other than the length.
- [#215]: Make
-
0.12.002 Jan 2024 withdrawnRelease notes
Open source →Changed
- Added all features to the generated docs.rs documentation.
- Fixed a bug in
serdeimplementation ofFamStructWrapperwhich allowed out of bounds memory access from Rust-safe code. See the related GHSA here: https://github.com/rust-vmm/vmm-sys-util/security/advisories/GHSA-875g-mfp6-g7f9 for more information.
Fixed
- Fixed
ioctl_io*_nrmacros expanding unhygenically, requiring for example the import ofioctl_ioc_nr!when usingioctl_iow_nr!.
-
0.11.218 Sep 2023Release notes
Open source →Changed
- [#201] Updated
SyscallReturnCodeto accept any signed integer type.
- [#201] Updated
-
0.11.116 Jan 2023 -
0.11.009 Nov 2022Release notes
Open source →v0.11.0
Added
- Added
rand_bytesfunction that generates a pseudo random vector oflenbytes. - Added implementation of
std::error::Errorforfam::Error. - Added derive
EqandPartialEqfor error types.
Changed
- [#161]: Updated the license to BSD-3-Clause.
- Use edition 2021.
- [vm-memory#199]: Use caret dependencies. This is the idiomatic way of specifying dependencies. With this we reduce the risk of breaking customer code when new releases of the dependencies are published.
- Renamed
xor_psuedo_rng_u32toxor_pseudo_rng_u32to fix a typo. - Renamed
xor_psuedo_rng_u8_alphanumericstoxor_pseudo_rng_u8_alphanumericsto fix a typo.
Release notes
Open source →Added
- Added
rand_bytesfunction that generates a pseudo random vector oflenbytes. - Added implementation of
std::error::Errorforfam::Error.- Added derive
EqandPartialEqfor error types.
- Added derive
Changed
- [#161]: Updated the license to BSD-3-Clause.
- Use edition 2021.
- [vm-memory#199]: Use caret dependencies. This is the idiomatic way of specifying dependencies. With this we reduce the risk of breaking customer code when new releases of the dependencies are published.
- Renamed
xor_psuedo_rng_u32toxor_pseudo_rng_u32to fix a typo. - Renamed
xor_psuedo_rng_u8_alphanumericstoxor_pseudo_rng_u8_alphanumericsto fix a typo.
- Added
-
0.10.015 Jul 2022Release notes
Open source →Added
- Added Android support by using the appropriate macro configuration when exporting functionality.
- Derive
DebugforFamStructWrapper&EventFd.
Changed
- The
ioctl_expris now a const function instead of a macro.
Release notes
Open source →Added
- Added Android support by using the appropriate macro configuration when exporting functionality.
- Derive
DebugforFamStructWrapper&EventFd.
Changed
- The
ioctl_expris now a const function instead of a macro.
-
0.9.014 Sep 2021Release notes
Open source →v0.9.0
Changed
- Fixed safety for sock_ctrl_msg::raw_recvmsg() and enhanced documentation
- Fixed sock_cmsg: ensured copy_nonoverlapping safety
- [#135]: sock_ctrl_msg: mark recv_with_fds as unsafe
Release notes
Open source →Changed
- Fixed safety for sock_ctrl_msg::raw_recvmsg() and enhanced documentation
- Fixed sock_cmsg: ensured copy_nonoverlapping safety
- [#135]: sock_ctrl_msg: mark recv_with_fds as unsafe
-
0.8.024 Feb 2021Release notes
Open source →v0.8.0
- Added set_check_for_hangup() to PollContext.
- Added writable()/has_error()/raw_events() to PollEvent.
- Derived Copy/Clone for PollWatchingEvents.
- Fixed the implementation of
write_zeroesto useFALLOC_FL_ZERO_RANGE
instead ofFALLOC_FL_PUNCH_HOLE. - Added
write_all_zeroestoWriteZeroes, which callswrite_zeroesin a
loop until the requested length is met. - Added a new trait,
WriteZeroesAt, which allows giving the offset in file
instead of using the current cursor. - Removed
max_eventsfromEpoll::waitwhich removes possible undefined
behavior. - [#104]: Fixed FAM
structPartialEqimplementation. - [#85]: Fixed FAM struct
Cloneimplementation. - [#99]: Validate the
maximum capacity when initializing FAM Struct.
Release notes
Open source →- Added set_check_for_hangup() to PollContext.
- Added writable()/has_error()/raw_events() to PollEvent.
- Derived Copy/Clone for PollWatchingEvents.
- Fixed the implementation of
write_zeroesto useFALLOC_FL_ZERO_RANGEinstead ofFALLOC_FL_PUNCH_HOLE. - Added
write_all_zeroestoWriteZeroes, which callswrite_zeroesin a loop until the requested length is met. - Added a new trait,
WriteZeroesAt, which allows giving the offset in file instead of using the current cursor. - Removed
max_eventsfromEpoll::waitwhich removes possible undefined behavior. - [#104]: Fixed FAM
struct
PartialEqimplementation. - [#85]: Fixed FAM struct
Cloneimplementation. - [#99]: Validate the maximum capacity when initializing FAM Struct.
v0.7.0
- Switched to Rust edition 2018.
- Added the
metricmodule that provides aMetricinterface as well as a default implementation forAtomicU64.
v0.6.1
- Implemented
From<io::Error>forerrno::Error.
v0.6.0
- Derived Copy for EpollEvent.
- Implemented Debug for EpollEvent.
- Changed
Epoll::ctlsignature such thatEpollEventis passed by value and not by reference. - Enabled this crate to be used on other Unixes (besides Linux) by using target_os = linux where appropriate.
v0.5.0
- Added conditionally compiled
serdecompatibility toFamStructWrapper, gated by thewith-serdefeature. - Implemented
Into<std::io::Errorforerrno::Error. - Added a wrapper over
libc::epollused for basic epoll operations.
v0.4.0
- Added Windows support for TempFile and errno::Error.
- Added
into_filefor TempFile which enables the TempFile to be used as a regular file. - Implemented std::error::Error for errno::Error.
- Fixed the implementation of
register_signal_handlerby allowing only valid signal numbers.
v0.3.1
- Advertise functionality for obtaining POSIX real time signal base which is needed to provide absolute signals in the API changed in v0.3.0.
v0.3.0
- Removed
for_vcpuargument fromsignal::register_signal_handlerandsignal::validate_signal_num. Users can now pass absolute values for all valid signal numbers. - Removed
flagargument ofsignal::register_signal_handlerpublic methods, which now defaults tolibc::SA_SIGINFO. - Changed
TempFile::newandTempDir::newto create new temporary files/ directories inside$TMPDIRif set, otherwise inside/tmp. - Added methods which create temporary files/directories with prefix.
v0.2.1
- Fixed the FamStructWrapper Clone implementation to avoid UB.
v0.2.0
- fam: updated the macro that generates implementions of FamStruct to also take a parameter that specifies the name of the flexible array member.
v0.1.1
- Fixed the Cargo.toml license.
- Fixed some clippy warnings.
v0.1.0
This is the first vmm-sys-util crate release.
It is a collection of modules implementing helpers and utilities used by multiple rust-vmm components and rust-vmm based VMMs. Most of the code in this first release is based on either the crosvm or the Firecracker projects, or both.
The first release comes with the following Rust modules:
-
aio: Safe wrapper over
Linux AIO. -
errno: Structures, helpers, and type definitions for working with
errno. -
eventfd: Structure and wrapper functions for working with
eventfd. -
fallocate: Enum and function for dealing with an allocated disk space by
fallocate. -
fam: Trait and wrapper for working with C defined FAM structures.
-
file_traits: Traits for handling file synchronization and length.
-
ioctls: Macros and functions for working with
ioctl. -
poll: Traits and structures for working with
epoll -
rand: Miscellaneous functions related to getting (pseudo) random numbers and strings.
-
seek_hole: Traits and implementations over
lseek64. -
signal: Enums, traits and functions for working with
signal. -
sockctrl_msg: Wrapper for sending and receiving messages with file descriptors on sockets that accept control messages (e.g. Unix domain sockets).
-
tempdir: Structure for handling temporary directories.
-
tempfile: Struct for handling temporary files as well as any cleanup required.
-
terminal: Trait for working with
termios. -
timerfd: Structure and functions for working with
timerfd. -
write_zeroes: Traits for replacing a range with a hole and writing zeroes in a file.
-
0.7.013 Nov 2020Release notes
Open source →- Switched to Rust edition 2018.
- Added the
metricmodule that provides aMetricinterface as well as a
default implementation forAtomicU64.
-
0.6.110 Jun 2020Nothing published for this version
-
0.6.018 May 2020Nothing published for this version
-
0.5.001 Apr 2020Nothing published for this version
-
0.4.022 Jan 2020Nothing published for this version
-
0.3.110 Dec 2019Nothing published for this version
-
0.3.010 Dec 2019Nothing published for this version
-
0.2.121 Nov 2019Nothing published for this version
-
0.2.023 Oct 2019Nothing published for this version
-
0.1.108 Oct 2019Nothing published for this version
-
0.1.008 Oct 2019 withdrawnNothing published for this version