mirror of
https://github.com/gbowne1/ClassicOS.git
synced 2025-10-13 21:25:07 -07:00
addind more important kernel files and also fixing bugs
This commit is contained in:
@@ -1,5 +1,19 @@
|
||||
#include "panic.h"
|
||||
#include "terminal.h"
|
||||
#include "serial.h"
|
||||
#include <stdbool.h>
|
||||
|
||||
void panic(const char *message) {
|
||||
// Panic handling code
|
||||
terminal_write("KERNEL PANIC: ");
|
||||
terminal_write(message);
|
||||
terminal_write("\nSystem halted.\n");
|
||||
|
||||
serial_write("KERNEL PANIC: ");
|
||||
serial_write(message);
|
||||
serial_write("\nSystem halted.\n");
|
||||
|
||||
// Halt the system
|
||||
while (true) {
|
||||
asm volatile ("cli; hlt");
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user