mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
vmm, vm-allocator: Introduce an allocator for platform devices
This allocator allocates 64-bit MMIO addresses for use with platform devices e.g. ACPI control devices and ensures there is no overlap with PCI address space ranges which can cause issues with PCI device remapping. Use this allocator the ACPI platform devices. Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
@@ -975,7 +975,7 @@ impl DeviceManager {
|
||||
.allocator
|
||||
.lock()
|
||||
.unwrap()
|
||||
.allocate_mmio_addresses(None, DEVICE_MANAGER_ACPI_SIZE as u64, None)
|
||||
.allocate_platform_mmio_addresses(None, DEVICE_MANAGER_ACPI_SIZE as u64, None)
|
||||
.ok_or(DeviceManagerError::AllocateIoPort)?;
|
||||
|
||||
let mut pci_irq_slots = [0; 32];
|
||||
@@ -1366,7 +1366,11 @@ impl DeviceManager {
|
||||
.allocator
|
||||
.lock()
|
||||
.unwrap()
|
||||
.allocate_mmio_addresses(None, devices::acpi::GED_DEVICE_ACPI_SIZE as u64, None)
|
||||
.allocate_platform_mmio_addresses(
|
||||
None,
|
||||
devices::acpi::GED_DEVICE_ACPI_SIZE as u64,
|
||||
None,
|
||||
)
|
||||
.ok_or(DeviceManagerError::AllocateMmioAddress)?;
|
||||
let ged_device = Arc::new(Mutex::new(devices::AcpiGedDevice::new(
|
||||
interrupt_group,
|
||||
|
||||
Reference in New Issue
Block a user