vmm: Pass MemoryManager through CpuManager creation

Instead of passing the GuestMemoryMmap directly to the CpuManager upon
its creation, it's better to pass a reference to the MemoryManager. This
way we will be able to know if SGX EPC region along with one or multiple
sections are present.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
This commit is contained in:
Sebastien Boeuf
2020-07-08 15:12:27 +02:00
committed by Samuel Ortiz
parent 2b06ce0ed4
commit 1603786374
2 changed files with 4 additions and 2 deletions
+1 -1
View File
@@ -293,7 +293,7 @@ impl Vm {
let cpu_manager = cpu::CpuManager::new(
&config.lock().unwrap().cpus.clone(),
&device_manager,
memory_manager.lock().unwrap().guest_memory(),
&memory_manager,
vm.clone(),
reset_evt,
hypervisor,