From 4bf2d4f7ddd1a51eef800bba6edd1905b50cc96f Mon Sep 17 00:00:00 2001 From: Yuanchu Xie Date: Sat, 20 Apr 2024 20:18:19 -0700 Subject: [PATCH] pci: Remove BusDevice requirement from PciDevice The BusDevice requirement is not needed, only Send is required. Signed-off-by: Yuanchu Xie --- pci/src/device.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pci/src/device.rs b/pci/src/device.rs index 905dbd1b2..f35fbbd19 100644 --- a/pci/src/device.rs +++ b/pci/src/device.rs @@ -11,7 +11,7 @@ use std::fmt::{self, Display}; use std::sync::{Arc, Barrier, Mutex}; use std::{io, result}; use vm_allocator::{AddressAllocator, SystemAllocator}; -use vm_device::{BusDevice, Resource}; +use vm_device::Resource; #[derive(Debug)] pub enum Error { @@ -54,7 +54,7 @@ pub struct BarReprogrammingParams { pub region_type: PciBarRegionType, } -pub trait PciDevice: BusDevice { +pub trait PciDevice: Send { /// Allocates the needed PCI BARs space using the `allocate` function which takes a size and /// returns an address. Returns a Vec of (GuestAddress, GuestUsize) tuples. fn allocate_bars(