broken cbfa to fix for a while

This commit is contained in:
FantasyPvP
2023-11-26 13:34:53 +00:00
parent b28b53418a
commit b16ce4a6f2
21 changed files with 86 additions and 601 deletions
+3 -7
View File
@@ -17,14 +17,12 @@ use core::panic::PanicInfo;
pub mod system;
pub mod user;
pub use system::kernel as kernel;
pub use system::std as std;
pub use user::bin::*;
extern crate alloc;
//extern crate fatfs;
#[cfg(test)]
use bootloader::{entry_point, BootInfo};
@@ -36,10 +34,8 @@ fn alloc_error_handler(layout: alloc::alloc::Layout) -> ! {
panic!("error while allocating: {:?}", layout)
}
pub fn init() {
system::init();
pub fn start(boot_info: &'static BootInfo) {
system::init(boot_info);
}
pub fn hlt() -> ! {
@@ -77,7 +73,7 @@ pub fn test_panic_handler(info: &PanicInfo) -> ! {
#[cfg(test)]
fn test_kernel_main(_boot_info: &'static BootInfo) -> ! {
init();
start();
test_main();
hlt();
}