mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-11-25 02:40:37 +00:00
The SOS VM should not use host efi memmap directly, since there are some memory ranges which reserved by hypersior and pre-launched VM should not be exposed to SOS VM. These memory ranges should be filtered from SOS VM efi memmap, otherwise it would caused unexpected issues. For example, The SOS kernel kaslr will try to find the random address for extracted kernel image in EFI table first. So it's possible that these reserved memory is picked for extracted kernel image. This will make SOS kernel boot fail. The patch would create efi memmory map for SOS VM and pass the memory map info to zeropage for loading SOS VM kernel. The boot service related region in host efi memmap is also kept for SOS VM so that SOS VM could have full capability of EFI services as host. Tracked-On: #5626 Signed-off-by: Victor Sun <victor.sun@intel.com> Reviewed-by: Jason Chen CJ <jason.cj.chen@intel.com>