From 7aca53753e851be45ab4c5e072b37154347aeedb Mon Sep 17 00:00:00 2001 From: 4lDO2 <4lDO2@protonmail.com> Date: Mon, 26 Jun 2023 13:39:49 +0200 Subject: [PATCH] Call init_mm from correct function. --- src/arch/x86_64/start.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/arch/x86_64/start.rs b/src/arch/x86_64/start.rs index 5620c6927b..0036c2d625 100644 --- a/src/arch/x86_64/start.rs +++ b/src/arch/x86_64/start.rs @@ -191,6 +191,9 @@ pub unsafe extern fn kstart(args_ptr: *const KernelArgs) -> ! { // Initialize all of the non-core devices not otherwise needed to complete initialization device::init_noncore(); + // Initialize data structures used to track pages. + memory::init_mm(); + // Stop graphical debug #[cfg(feature = "graphical_debug")] graphical_debug::fini(); @@ -263,8 +266,6 @@ pub unsafe extern fn kstart_ap(args_ptr: *const KernelArgsAp) -> ! { // Initialize devices (for AP) device::init_ap(); - memory::init_mm(); - AP_READY.store(true, Ordering::SeqCst); cpu_id