mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2024-12-22 05:35:20 +00:00
build: Bump vhost-user-backend, vhost, and virtio-queue
Update the vhost-user-backend crate version used along with related
crates (vhost and virtio-queue.) This requires minor changes to the
types used for the memory in the backends with the use of the
BitmapMmapRegion type for the Bitmap implementation.
Signed-off-by: Rob Bradford <rbradford@rivosinc.com>
(cherry picked from commit d10f20eb71
)
This commit is contained in:
parent
8632dda669
commit
4c0784f041
12
Cargo.lock
generated
12
Cargo.lock
generated
@ -2377,9 +2377,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "vhost"
|
name = "vhost"
|
||||||
version = "0.10.0"
|
version = "0.11.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "2b64e816d0d49769fbfaa1494eb77cc2a3ddc526ead05c7f922cb7d64106286f"
|
checksum = "6be08d1166d41a78861ad50212ab3f9eca0729c349ac3a7a8f557c62406b87cc"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"bitflags 2.4.1",
|
"bitflags 2.4.1",
|
||||||
"libc",
|
"libc",
|
||||||
@ -2389,9 +2389,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "vhost-user-backend"
|
name = "vhost-user-backend"
|
||||||
version = "0.13.1"
|
version = "0.15.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "72c8c447d076ac508d78cb45664d203df7989e891656dce260a7e93d72352c9a"
|
checksum = "1f0ffb1dd8e00a708a0e2c32d5efec5812953819888591fff9ff68236b8a5096"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"libc",
|
"libc",
|
||||||
"log",
|
"log",
|
||||||
@ -2481,9 +2481,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "virtio-queue"
|
name = "virtio-queue"
|
||||||
version = "0.11.0"
|
version = "0.12.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "e3f69a13d6610db9312acbb438b0390362af905d37634a2106be70c0f734986d"
|
checksum = "07d8406e7250c934462de585d8f2d2781c31819bca1fbb7c5e964ca6bbaabfe8"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"log",
|
"log",
|
||||||
"virtio-bindings",
|
"virtio-bindings",
|
||||||
|
@ -21,7 +21,7 @@ uuid = { version = "1.3.4", features = ["v4"] }
|
|||||||
versionize = "0.2.0"
|
versionize = "0.2.0"
|
||||||
versionize_derive = "0.1.6"
|
versionize_derive = "0.1.6"
|
||||||
virtio-bindings = { version = "0.2.0", features = ["virtio-v5_0_0"] }
|
virtio-bindings = { version = "0.2.0", features = ["virtio-v5_0_0"] }
|
||||||
virtio-queue = "0.11.0"
|
virtio-queue = "0.12.0"
|
||||||
vm-memory = { version = "0.14.0", features = ["backend-mmap", "backend-atomic", "backend-bitmap"] }
|
vm-memory = { version = "0.14.0", features = ["backend-mmap", "backend-atomic", "backend-bitmap"] }
|
||||||
vm-virtio = { path = "../vm-virtio" }
|
vm-virtio = { path = "../vm-virtio" }
|
||||||
vmm-sys-util = "0.12.1"
|
vmm-sys-util = "0.12.1"
|
||||||
|
@ -23,7 +23,7 @@ net_util = { path = "../net_util" }
|
|||||||
once_cell = "1.19.0"
|
once_cell = "1.19.0"
|
||||||
seccompiler = "0.4.0"
|
seccompiler = "0.4.0"
|
||||||
virtio-devices = { path = "../virtio-devices" }
|
virtio-devices = { path = "../virtio-devices" }
|
||||||
virtio-queue = "0.11.0"
|
virtio-queue = "0.12.0"
|
||||||
vmm = { path = "../vmm" }
|
vmm = { path = "../vmm" }
|
||||||
vmm-sys-util = "0.12.1"
|
vmm-sys-util = "0.12.1"
|
||||||
vm-memory = "0.14.0"
|
vm-memory = "0.14.0"
|
||||||
|
@ -16,7 +16,7 @@ thiserror = "1.0.52"
|
|||||||
versionize = "0.2.0"
|
versionize = "0.2.0"
|
||||||
versionize_derive = "0.1.6"
|
versionize_derive = "0.1.6"
|
||||||
virtio-bindings = "0.2.0"
|
virtio-bindings = "0.2.0"
|
||||||
virtio-queue = "0.11.0"
|
virtio-queue = "0.12.0"
|
||||||
vm-memory = { version = "0.14.0", features = ["backend-mmap", "backend-atomic", "backend-bitmap"] }
|
vm-memory = { version = "0.14.0", features = ["backend-mmap", "backend-atomic", "backend-bitmap"] }
|
||||||
vm-virtio = { path = "../vm-virtio" }
|
vm-virtio = { path = "../vm-virtio" }
|
||||||
vmm-sys-util = "0.12.1"
|
vmm-sys-util = "0.12.1"
|
||||||
|
@ -13,9 +13,9 @@ epoll = "4.3.3"
|
|||||||
libc = "0.2.147"
|
libc = "0.2.147"
|
||||||
log = "0.4.20"
|
log = "0.4.20"
|
||||||
option_parser = { path = "../option_parser" }
|
option_parser = { path = "../option_parser" }
|
||||||
vhost = { version = "0.10.0", features = ["vhost-user-backend"] }
|
vhost = { version = "0.11.0", features = ["vhost-user-backend"] }
|
||||||
vhost-user-backend = "0.13.1"
|
vhost-user-backend = "0.15.0"
|
||||||
virtio-bindings = "0.2.0"
|
virtio-bindings = "0.2.0"
|
||||||
virtio-queue = "0.11.0"
|
virtio-queue = "0.12.0"
|
||||||
vm-memory = "0.14.0"
|
vm-memory = "0.14.0"
|
||||||
vmm-sys-util = "0.12.1"
|
vmm-sys-util = "0.12.1"
|
||||||
|
@ -33,16 +33,18 @@ use std::vec::Vec;
|
|||||||
use std::{convert, error, fmt, io};
|
use std::{convert, error, fmt, io};
|
||||||
use vhost::vhost_user::message::*;
|
use vhost::vhost_user::message::*;
|
||||||
use vhost::vhost_user::Listener;
|
use vhost::vhost_user::Listener;
|
||||||
use vhost_user_backend::{VhostUserBackendMut, VhostUserDaemon, VringRwLock, VringState, VringT};
|
use vhost_user_backend::{
|
||||||
|
bitmap::BitmapMmapRegion, VhostUserBackendMut, VhostUserDaemon, VringRwLock, VringState, VringT,
|
||||||
|
};
|
||||||
use virtio_bindings::virtio_blk::*;
|
use virtio_bindings::virtio_blk::*;
|
||||||
use virtio_bindings::virtio_config::VIRTIO_F_VERSION_1;
|
use virtio_bindings::virtio_config::VIRTIO_F_VERSION_1;
|
||||||
use virtio_bindings::virtio_ring::VIRTIO_RING_F_EVENT_IDX;
|
use virtio_bindings::virtio_ring::VIRTIO_RING_F_EVENT_IDX;
|
||||||
use virtio_queue::QueueT;
|
use virtio_queue::QueueT;
|
||||||
use vm_memory::GuestAddressSpace;
|
use vm_memory::GuestAddressSpace;
|
||||||
use vm_memory::{bitmap::AtomicBitmap, ByteValued, Bytes, GuestMemoryAtomic};
|
use vm_memory::{ByteValued, Bytes, GuestMemoryAtomic};
|
||||||
use vmm_sys_util::{epoll::EventSet, eventfd::EventFd};
|
use vmm_sys_util::{epoll::EventSet, eventfd::EventFd};
|
||||||
|
|
||||||
type GuestMemoryMmap = vm_memory::GuestMemoryMmap<AtomicBitmap>;
|
type GuestMemoryMmap = vm_memory::GuestMemoryMmap<BitmapMmapRegion>;
|
||||||
|
|
||||||
const SECTOR_SHIFT: u8 = 9;
|
const SECTOR_SHIFT: u8 = 9;
|
||||||
const SECTOR_SIZE: u64 = 0x01 << SECTOR_SHIFT;
|
const SECTOR_SIZE: u64 = 0x01 << SECTOR_SHIFT;
|
||||||
@ -301,7 +303,7 @@ impl VhostUserBlkBackend {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl VhostUserBackendMut for VhostUserBlkBackend {
|
impl VhostUserBackendMut for VhostUserBlkBackend {
|
||||||
type Bitmap = AtomicBitmap;
|
type Bitmap = BitmapMmapRegion;
|
||||||
type Vring = VringRwLock<GuestMemoryAtomic<GuestMemoryMmap>>;
|
type Vring = VringRwLock<GuestMemoryAtomic<GuestMemoryMmap>>;
|
||||||
|
|
||||||
fn num_queues(&self) -> usize {
|
fn num_queues(&self) -> usize {
|
||||||
|
@ -13,8 +13,8 @@ libc = "0.2.147"
|
|||||||
log = "0.4.20"
|
log = "0.4.20"
|
||||||
net_util = { path = "../net_util" }
|
net_util = { path = "../net_util" }
|
||||||
option_parser = { path = "../option_parser" }
|
option_parser = { path = "../option_parser" }
|
||||||
vhost = { version = "0.10.0", features = ["vhost-user-backend"] }
|
vhost = { version = "0.11.0", features = ["vhost-user-backend"] }
|
||||||
vhost-user-backend = "0.13.1"
|
vhost-user-backend = "0.15.0"
|
||||||
virtio-bindings = "0.2.0"
|
virtio-bindings = "0.2.0"
|
||||||
vm-memory = "0.14.0"
|
vm-memory = "0.14.0"
|
||||||
vmm-sys-util = "0.12.1"
|
vmm-sys-util = "0.12.1"
|
||||||
|
@ -23,14 +23,15 @@ use std::sync::{Arc, Mutex, RwLock};
|
|||||||
use std::vec::Vec;
|
use std::vec::Vec;
|
||||||
use vhost::vhost_user::message::*;
|
use vhost::vhost_user::message::*;
|
||||||
use vhost::vhost_user::Listener;
|
use vhost::vhost_user::Listener;
|
||||||
|
use vhost_user_backend::bitmap::BitmapMmapRegion;
|
||||||
use vhost_user_backend::{VhostUserBackendMut, VhostUserDaemon, VringRwLock, VringT};
|
use vhost_user_backend::{VhostUserBackendMut, VhostUserDaemon, VringRwLock, VringT};
|
||||||
use virtio_bindings::virtio_config::{VIRTIO_F_NOTIFY_ON_EMPTY, VIRTIO_F_VERSION_1};
|
use virtio_bindings::virtio_config::{VIRTIO_F_NOTIFY_ON_EMPTY, VIRTIO_F_VERSION_1};
|
||||||
use virtio_bindings::virtio_net::*;
|
use virtio_bindings::virtio_net::*;
|
||||||
use vm_memory::GuestAddressSpace;
|
use vm_memory::GuestAddressSpace;
|
||||||
use vm_memory::{bitmap::AtomicBitmap, GuestMemoryAtomic};
|
use vm_memory::GuestMemoryAtomic;
|
||||||
use vmm_sys_util::{epoll::EventSet, eventfd::EventFd};
|
use vmm_sys_util::{epoll::EventSet, eventfd::EventFd};
|
||||||
|
|
||||||
type GuestMemoryMmap = vm_memory::GuestMemoryMmap<AtomicBitmap>;
|
type GuestMemoryMmap = vm_memory::GuestMemoryMmap<BitmapMmapRegion>;
|
||||||
|
|
||||||
pub type Result<T> = std::result::Result<T, Error>;
|
pub type Result<T> = std::result::Result<T, Error>;
|
||||||
type VhostUserBackendResult<T> = std::result::Result<T, std::io::Error>;
|
type VhostUserBackendResult<T> = std::result::Result<T, std::io::Error>;
|
||||||
@ -159,7 +160,7 @@ impl VhostUserNetBackend {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl VhostUserBackendMut for VhostUserNetBackend {
|
impl VhostUserBackendMut for VhostUserNetBackend {
|
||||||
type Bitmap = AtomicBitmap;
|
type Bitmap = BitmapMmapRegion;
|
||||||
type Vring = VringRwLock<GuestMemoryAtomic<GuestMemoryMmap>>;
|
type Vring = VringRwLock<GuestMemoryAtomic<GuestMemoryMmap>>;
|
||||||
|
|
||||||
fn num_queues(&self) -> usize {
|
fn num_queues(&self) -> usize {
|
||||||
|
@ -27,9 +27,9 @@ serial_buffer = { path = "../serial_buffer" }
|
|||||||
thiserror = "1.0.52"
|
thiserror = "1.0.52"
|
||||||
versionize = "0.2.0"
|
versionize = "0.2.0"
|
||||||
versionize_derive = "0.1.6"
|
versionize_derive = "0.1.6"
|
||||||
vhost = { version = "0.10.0", features = ["vhost-user-frontend", "vhost-user-backend", "vhost-kern", "vhost-vdpa"] }
|
vhost = { version = "0.11.0", features = ["vhost-user-frontend", "vhost-user-backend", "vhost-kern", "vhost-vdpa"] }
|
||||||
virtio-bindings = { version = "0.2.0", features = ["virtio-v5_0_0"] }
|
virtio-bindings = { version = "0.2.0", features = ["virtio-v5_0_0"] }
|
||||||
virtio-queue = "0.11.0"
|
virtio-queue = "0.12.0"
|
||||||
vm-allocator = { path = "../vm-allocator" }
|
vm-allocator = { path = "../vm-allocator" }
|
||||||
vm-device = { path = "../vm-device" }
|
vm-device = { path = "../vm-device" }
|
||||||
vm-memory = { version = "0.14.0", features = ["backend-mmap", "backend-atomic", "backend-bitmap"] }
|
vm-memory = { version = "0.14.0", features = ["backend-mmap", "backend-atomic", "backend-bitmap"] }
|
||||||
|
@ -9,5 +9,5 @@ default = []
|
|||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
log = "0.4.20"
|
log = "0.4.20"
|
||||||
virtio-queue = "0.11.0"
|
virtio-queue = "0.12.0"
|
||||||
vm-memory = { version = "0.14.0", features = ["backend-mmap", "backend-atomic", "backend-bitmap"] }
|
vm-memory = { version = "0.14.0", features = ["backend-mmap", "backend-atomic", "backend-bitmap"] }
|
||||||
|
@ -60,7 +60,7 @@ versionize_derive = "0.1.6"
|
|||||||
vfio-ioctls = { git = "https://github.com/rust-vmm/vfio", branch = "main", default-features = false }
|
vfio-ioctls = { git = "https://github.com/rust-vmm/vfio", branch = "main", default-features = false }
|
||||||
vfio_user = { git = "https://github.com/rust-vmm/vfio-user", branch = "main" }
|
vfio_user = { git = "https://github.com/rust-vmm/vfio-user", branch = "main" }
|
||||||
virtio-devices = { path = "../virtio-devices" }
|
virtio-devices = { path = "../virtio-devices" }
|
||||||
virtio-queue = "0.11.0"
|
virtio-queue = "0.12.0"
|
||||||
vm-allocator = { path = "../vm-allocator" }
|
vm-allocator = { path = "../vm-allocator" }
|
||||||
vm-device = { path = "../vm-device" }
|
vm-device = { path = "../vm-device" }
|
||||||
vm-memory = { version = "0.14.0", features = ["backend-mmap", "backend-atomic", "backend-bitmap"] }
|
vm-memory = { version = "0.14.0", features = ["backend-mmap", "backend-atomic", "backend-bitmap"] }
|
||||||
|
Loading…
Reference in New Issue
Block a user