error.c revision 5af21843
1/*
2 * Callers outside of misc.c need access to the error reporting routines,
3 * but the *_putstr() functions need to stay in misc.c because of how
4 * memcpy() and memmove() are defined for the compressed boot environment.
5 */
6#include "misc.h"
7#include "error.h"
8
9void warn(char *m)
10{
11	error_putstr("\n\n");
12	error_putstr(m);
13	error_putstr("\n\n");
14}
15
16void error(char *m)
17{
18	warn(m);
19	error_putstr(" -- System halted");
20
21	while (1)
22		asm("hlt");
23}
24