mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-23 09:47:44 +00:00
hv: mmu: remove get_mem_range_info in init_paging
We used get_mem_range_info to get the top memory address and then use this address as the high 64 bits max memory address. This assumes the platform must have high memory space. This patch calculates the high 64 bits max memory address according the e820 tables and removes the assumption "The platform must have high memory space" by map the low RAM region and high RAM region separately. Tracked-On: #5830 Signed-off-by: Li Fei1 <fei1.li@intel.com> Acked-by: eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -40,7 +40,8 @@
|
||||
#define MEM_1M (MEM_1K * 1024U)
|
||||
#define MEM_2M (MEM_1M * 2U)
|
||||
#define MEM_1G (MEM_1M * 1024U)
|
||||
#define MEM_2G (1024UL * 1024UL * 1024UL * 2UL)
|
||||
#define MEM_2G (MEM_1G * 2UL)
|
||||
#define MEM_4G (MEM_1G * 4UL)
|
||||
|
||||
#ifndef ASSEMBLER
|
||||
|
||||
|
@@ -31,6 +31,8 @@
|
||||
#define PAGE_CACHE_UC_MINUS PAGE_PCD
|
||||
#define PAGE_CACHE_UC (PAGE_PCD | PAGE_PWT)
|
||||
|
||||
#define PAGE_ATTR_USER (PAGE_PRESENT | PAGE_RW | PAGE_USER | PAGE_NX)
|
||||
|
||||
/**
|
||||
* @defgroup ept_mem_access_right EPT Memory Access Right
|
||||
*
|
||||
|
Reference in New Issue
Block a user