mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
vmm: Create MemoryManager from restore data
Extending the MemoryManager::new() function to be able to create a MemoryManager from data that have been previously stored instead of always creating everything from scratch. This change brings real added value as it allows a VM to be restored respecting the proper memory layout instead of hoping the regions will be created the way they were before. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
This commit is contained in:
@@ -750,6 +750,7 @@ impl Vm {
|
||||
phys_bits,
|
||||
#[cfg(feature = "tdx")]
|
||||
tdx_enabled,
|
||||
None,
|
||||
)
|
||||
.map_err(Error::MemoryManager)?;
|
||||
|
||||
@@ -866,6 +867,7 @@ impl Vm {
|
||||
phys_bits,
|
||||
#[cfg(feature = "tdx")]
|
||||
false,
|
||||
None,
|
||||
)
|
||||
.map_err(Error::MemoryManager)?;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user