mirror of
https://github.com/DragonOS-Community/DragonOS.git
synced 2025-06-19 17:26:31 +00:00
增加了timekeeping模块 (#106)
* 增加了timekeeping模块 * 格式化文档和细节更改 Co-authored-by: longjin <longjin@RinGoTek.cn>
This commit is contained in:
@ -3,7 +3,7 @@
|
||||
#![feature(core_intrinsics)] // <2>
|
||||
#![feature(alloc_error_handler)]
|
||||
#![feature(panic_info_message)]
|
||||
#![feature(drain_filter)]// 允许Vec的drain_filter特性
|
||||
#![feature(drain_filter)] // 允许Vec的drain_filter特性
|
||||
|
||||
#[allow(non_upper_case_globals)]
|
||||
#[allow(non_camel_case_types)]
|
||||
@ -18,18 +18,22 @@ mod ipc;
|
||||
|
||||
#[macro_use]
|
||||
mod libs;
|
||||
mod driver;
|
||||
mod mm;
|
||||
mod process;
|
||||
mod sched;
|
||||
mod smp;
|
||||
mod driver;
|
||||
mod time;
|
||||
|
||||
extern crate alloc;
|
||||
|
||||
use mm::allocator::KernelAllocator;
|
||||
|
||||
// <3>
|
||||
use crate::{include::bindings::bindings::{process_do_exit, BLACK, GREEN}, arch::x86_64::asm::current::current_pcb};
|
||||
use crate::{
|
||||
arch::x86_64::asm::current::current_pcb,
|
||||
include::bindings::bindings::{process_do_exit, BLACK, GREEN},
|
||||
};
|
||||
|
||||
// 声明全局的slab分配器
|
||||
#[cfg_attr(not(test), global_allocator)]
|
||||
@ -68,9 +72,7 @@ pub fn panic(info: &PanicInfo) -> ! {
|
||||
unsafe {
|
||||
process_do_exit(u64::MAX);
|
||||
};
|
||||
loop {
|
||||
|
||||
}
|
||||
loop {}
|
||||
}
|
||||
|
||||
/// 该函数用作测试,在process.c的initial_kernel_thread()中调用了此函数
|
||||
|
Reference in New Issue
Block a user