1 #include <aros/config.h>
6 #include "kernel_base.h"
7 #include "kernel_debug.h"
10 * This definition allows to move this buffer away from .bss.
11 * Can be used on native, by using, for example, zero page.
12 * This condition is considered fatal, there's no return.
14 #ifndef KERNEL_PANIC_BUFFER
15 static char panicBuffer
[1024];
16 #define KERNEL_PANIC_BUFFER panicBuffer
19 void krnPanic(struct KernelBase
*KernelBase
,const char *fmt
, ...)
21 const char *hdr
= "Critical boot failure\n";
22 char *ptr
= KERNEL_PANIC_BUFFER
;
25 /* Prepend the header */
29 /* vsprintf() here comes from librom.a */
31 vsprintf(ptr
, fmt
, ap
);
34 krnDisplayAlert(KERNEL_PANIC_BUFFER
, KernelBase
);
36 #if AROS_FLAVOUR & AROS_FLAVOUR_STANDALONE
37 /* Hosted AROS may quit here */