Last change
on this file since dd1be7c was
e16e8f2,
checked in by Edwin Eefting <edwin@datux.nl>, 3 years ago
|
bootstuff
|
-
Property mode set to
100644
|
File size:
450 bytes
|
Line | |
---|
1 | /* |
---|
2 | * kaboom.c |
---|
3 | */ |
---|
4 | |
---|
5 | #include "core.h" |
---|
6 | |
---|
7 | #if defined(CORE_DEBUG) || defined(DEBUG_PORT) |
---|
8 | |
---|
9 | #include <dprintf.h> |
---|
10 | |
---|
11 | __export __noreturn __bad_SEG(const volatile void *p) |
---|
12 | { |
---|
13 | dprintf("SEG() passed an invalid pointer: %p\n", p); |
---|
14 | kaboom(); |
---|
15 | } |
---|
16 | |
---|
17 | #endif |
---|
18 | |
---|
19 | #undef kaboom |
---|
20 | |
---|
21 | __export __noreturn _kaboom(void) |
---|
22 | { |
---|
23 | extern void kaboom(void); |
---|
24 | call16(kaboom, &zero_regs, NULL); |
---|
25 | /* Do this if kaboom somehow returns... */ |
---|
26 | for (;;) |
---|
27 | asm volatile("hlt"); |
---|
28 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.