feature: 增加early io remap的fixmap功能 (#495)

允许在内存管理初始化之前,使用fixmap功能,映射一些物理内存,并记录.
This commit is contained in:
LoGin
2024-01-21 01:21:55 +08:00
committed by GitHub
parent 1f58c8f5cf
commit 74ffde667e
6 changed files with 223 additions and 7 deletions

View File

@ -115,6 +115,10 @@ impl MemoryManagementArch for X86_64MMArch {
const USER_BRK_START: VirtAddr = VirtAddr::new(0x700000000000);
const USER_STACK_START: VirtAddr = VirtAddr::new(0x6ffff0a00000);
const FIXMAP_START_VADDR: VirtAddr = VirtAddr::new(0xffffb00000000000);
/// 设置FIXMAP区域大小为1M
const FIXMAP_SIZE: usize = 256 * 4096;
/// @brief 获取物理内存区域
unsafe fn init() {
extern "C" {