mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2025-02-22 19:32:20 +00:00
vmm: igvm: complete isolated import
Complete the isolated import, telling the Microsoft hypervisor that import is done so that MSHV can issue SNP_LAUNCH_FINISH command. Signed-off-by: Muminul Islam <muislam@microsoft.com>
This commit is contained in:
parent
cbcbf635ab
commit
dc68a6e30f
@ -423,7 +423,7 @@ pub fn load_igvm(
|
||||
{
|
||||
use std::time::Instant;
|
||||
|
||||
let now = Instant::now();
|
||||
let mut now = Instant::now();
|
||||
|
||||
// Sort the gpas to group them by the page type
|
||||
gpas.sort_by(|a, b| a.gpa.cmp(&b.gpa));
|
||||
@ -472,6 +472,21 @@ pub fn load_igvm(
|
||||
now.elapsed(),
|
||||
gpas.len()
|
||||
);
|
||||
|
||||
now = Instant::now();
|
||||
// Call Complete Isolated Import since we are done importing isolated pages
|
||||
let host_data: [u8; 32] = [0; 32];
|
||||
memory_manager
|
||||
.lock()
|
||||
.unwrap()
|
||||
.vm
|
||||
.complete_isolated_import(loaded_info.snp_id_block, host_data, 1)
|
||||
.map_err(Error::CompleteIsolatedImport)?;
|
||||
|
||||
info!(
|
||||
"Time it took to for launch complete command {:.2?}",
|
||||
now.elapsed()
|
||||
);
|
||||
}
|
||||
|
||||
debug!("Dumping the contents of VMSA page: {:x?}", loaded_info.vmsa);
|
||||
|
Loading…
x
Reference in New Issue
Block a user