mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-21 16:33:24 +00:00
Finish bootstrap once finishing the initialization of OSTD
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
878f3f3760
commit
b17cbb2408
@ -46,7 +46,7 @@ pub mod timer;
|
||||
pub mod trap;
|
||||
pub mod user;
|
||||
|
||||
use core::sync::atomic::AtomicBool;
|
||||
use core::sync::atomic::{AtomicBool, Ordering};
|
||||
|
||||
pub use ostd_macros::{main, panic_handler};
|
||||
pub use ostd_pod::Pod;
|
||||
@ -100,10 +100,12 @@ unsafe fn init() {
|
||||
arch::irq::enable_local();
|
||||
|
||||
invoke_ffi_init_funcs();
|
||||
|
||||
IN_BOOTSTRAP_CONTEXT.store(false, Ordering::Relaxed);
|
||||
}
|
||||
|
||||
/// Indicates whether the kernel is in bootstrap context.
|
||||
pub static IN_BOOTSTRAP_CONTEXT: AtomicBool = AtomicBool::new(true);
|
||||
pub(crate) static IN_BOOTSTRAP_CONTEXT: AtomicBool = AtomicBool::new(true);
|
||||
|
||||
/// Invoke the initialization functions defined in the FFI.
|
||||
/// The component system uses this function to call the initialization functions of
|
||||
|
Reference in New Issue
Block a user