mirror of
https://github.com/phil-opp/blog_os.git
synced 2025-12-16 14:27:49 +00:00
Use hlt_loop in lib.rs too
This commit is contained in:
@@ -31,7 +31,7 @@ pub fn test_panic_handler(info: &PanicInfo) -> ! {
|
|||||||
serial_println!("[failed]\n");
|
serial_println!("[failed]\n");
|
||||||
serial_println!("Error: {}\n", info);
|
serial_println!("Error: {}\n", info);
|
||||||
exit_qemu(QemuExitCode::Failed);
|
exit_qemu(QemuExitCode::Failed);
|
||||||
loop {}
|
hlt_loop();
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||||
@@ -56,7 +56,7 @@ pub fn exit_qemu(exit_code: QemuExitCode) {
|
|||||||
pub extern "C" fn _start() -> ! {
|
pub extern "C" fn _start() -> ! {
|
||||||
init();
|
init();
|
||||||
test_main();
|
test_main();
|
||||||
loop {}
|
hlt_loop();
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
|
|||||||
Reference in New Issue
Block a user