vhost_user_block: Refactor vhost_user_block backend code into a new crate

Extract the majority of the code that provides the vhost-user-block
backend into its own crate and port the binary to use it.

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
Rob Bradford
2020-01-20 16:10:21 +00:00
parent fb763c4043
commit 1dd2451895
5 changed files with 321 additions and 262 deletions

18
Cargo.lock generated
View File

@@ -185,6 +185,7 @@ dependencies = [
"tempdir 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
"vhost_rs 0.1.0",
"vhost_user_backend 0.1.0",
"vhost_user_block 0.1.0",
"vhost_user_fs 0.1.0",
"vhost_user_net 0.1.0",
"virtio-bindings 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1026,6 +1027,23 @@ dependencies = [
"vmm-sys-util 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "vhost_user_block"
version = "0.1.0"
dependencies = [
"bitflags 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
"epoll 4.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"libc 0.2.66 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)",
"qcow 0.1.0",
"vhost_rs 0.1.0",
"vhost_user_backend 0.1.0",
"virtio-bindings 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"vm-memory 0.1.0 (git+https://github.com/rust-vmm/vm-memory)",
"vm-virtio 0.1.0",
"vmm-sys-util 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "vhost_user_fs"
version = "0.1.0"