From 6fd5085ed138d1748e375f071cda46d1ab801c1e Mon Sep 17 00:00:00 2001 From: faynot Date: Tue, 7 Jul 2026 19:59:56 +0300 Subject: [PATCH] Update kernel/src/mem/mod.rs --- kernel/src/mem/mod.rs | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/kernel/src/mem/mod.rs b/kernel/src/mem/mod.rs index 6f5eb8d..975163f 100644 --- a/kernel/src/mem/mod.rs +++ b/kernel/src/mem/mod.rs @@ -1,5 +1,3 @@ -//! `src/mem/mod.rs` — memory subsystem root - pub mod address; pub mod allocator; pub mod buddy; @@ -9,27 +7,18 @@ pub mod pmm; pub mod vmm; pub mod pm_router; -/// Initialise the physical memory manager. -/// -/// Must be called before any heap allocation or VMM operation. pub fn init_pmm(memmap: &limine::response::MemoryMapResponse) { unsafe { pmm::BitmapPMM::init(memmap); } } -/// Initialise CPU features required by the VMM (INVPCID detection). -/// -/// Must be called before `init_vmm` and any `AddressSpace::activate()`. pub fn init_cpu_features() { vmm::init_cpu_features(); } -/// Initialise the kernel address space record (after PMM, heap, and the -/// initial P4 page table have been set up in `kmain`). pub fn init_vmm(pml4_phys: address::PhysAddr) { vmm::init_kernel_space(pml4_phys); } -/// Physical memory statistics: `(used_pages, total_pages)`. pub fn get_stats() -> (usize, usize) { pmm::get_stats() }