mirror of
https://github.com/Mathewnd/Astral.git
synced 2026-10-27 12:48:22 +00:00
kernel: panic
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
#include <panic.h>
|
||||
#include <arch/cpu.h>
|
||||
#include <printf.h>
|
||||
|
||||
__attribute__((noreturn)) void _panic(char *msg, context_t *ctx) {
|
||||
printf("Oops.\n");
|
||||
|
||||
if (msg)
|
||||
printf("%s\n", msg);
|
||||
|
||||
if (ctx)
|
||||
PRINT_CTX(ctx);
|
||||
|
||||
for (;;);
|
||||
}
|
||||
Reference in New Issue
Block a user