This is a rewrite of the vroom userspace NVMe driver with the following changes:
- compilable with
no-std - usable with a custom allocator
The goal of the rewrite is to allow the driver to be used within the Hermit Unikernel.
The thesis of the original vroom project by Tuomas Pirhonen
contains some details about the original implementation.
This is by no means production-ready.
Do not use it in critical environments.
DMA may corrupt memory.
You will need Rust, as well as its package manager cargo.
The installation instructions can be found at rustup.rs.
Huge pages need to be enabled:
cd vroom
sudo ./setup-hugetlbfs.shBuild the driver, as well as any examples:
cargo build --release --all-targetsGet the PCI address of an NVMe drive with lspci.
The address should be formatted as 0000:00:xx.x for the program.
Run the std_pci_huge example (root privileges are needed for DMA):
sudo ./target/release/examples/std_pci_huge 0000:00:08.0