diff --git a/kernel/Cargo.toml b/kernel/Cargo.toml
index 46dd45b..d7d97c9 100644
--- a/kernel/Cargo.toml
+++ b/kernel/Cargo.toml
@@ -18,5 +18,6 @@ log = "0.4.22"
[lints.clippy]
missing_safety_doc = "allow"
needless_range_loop = "allow"
+too_many_arguments = "allow"
type_complexity = "allow"
upper_case_acronyms = "allow"
diff --git a/kernel/src/main.rs b/kernel/src/main.rs
index 1f92d59..9999802 100644
--- a/kernel/src/main.rs
+++ b/kernel/src/main.rs
@@ -23,7 +23,7 @@ use kernel_common::{
paging::{KERNEL_HEAP_INITIAL_SIZE, KERNEL_HEAP_START},
};
use log::{error, info};
-use misc::display::{setup_display, DISPLAY};
+use misc::display::{setup_display, PANIC_DISPLAY};
use sys::{
acpica_osl::AE_OK,
early_acpi::EarlyACPIHandler,
@@ -115,8 +115,9 @@ fn panic(info: &PanicInfo) -> ! {
}
error!("{}", info);
let str = format!("{}", info);
- let mut display = DISPLAY.lock();
+ let mut display = PANIC_DISPLAY.lock();
if let Some(display) = display.as_mut() {
+ display.clear();
display.print(&str);
}
}
diff --git a/kernel/src/misc/display.rs b/kernel/src/misc/display.rs
index 3562c79..3617aef 100644
--- a/kernel/src/misc/display.rs
+++ b/kernel/src/misc/display.rs
@@ -18,7 +18,9 @@ pub struct Display {
current_y: usize,
}
+//TODO: Change to mutex
pub static DISPLAY: Spinlock