mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2024-10-01 11:05:46 +00:00
vmm: device_manager: Add the MemoryManager to the I/O bus
Now that the MemoryManager has I/O port functionality it needs to be exposed on the I/O bus. Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
parent
1218765df2
commit
8ecf736982
@ -500,6 +500,18 @@ impl DeviceManager {
|
|||||||
|
|
||||||
let config = vm_info.vm_cfg.clone();
|
let config = vm_info.vm_cfg.clone();
|
||||||
|
|
||||||
|
address_manager
|
||||||
|
.allocator
|
||||||
|
.lock()
|
||||||
|
.unwrap()
|
||||||
|
.allocate_io_addresses(Some(GuestAddress(0x0a00)), 0x18, None)
|
||||||
|
.ok_or(DeviceManagerError::AllocateIOPort)?;
|
||||||
|
|
||||||
|
address_manager
|
||||||
|
.io_bus
|
||||||
|
.insert(memory_manager.clone(), 0xa00, 0x18)
|
||||||
|
.map_err(DeviceManagerError::BusError)?;
|
||||||
|
|
||||||
Ok(DeviceManager {
|
Ok(DeviceManager {
|
||||||
address_manager,
|
address_manager,
|
||||||
console,
|
console,
|
||||||
|
Loading…
Reference in New Issue
Block a user