Flush serial device on panic.
authorBen Pfaff <blp@cs.stanford.edu>
Mon, 13 Sep 2004 01:24:28 +0000 (01:24 +0000)
committerBen Pfaff <blp@cs.stanford.edu>
Mon, 13 Sep 2004 01:24:28 +0000 (01:24 +0000)
src/lib/debug.c

index 2082eedd5714824894f56cb6225c91d8008fc935..2388a2daa3f23c7773c21094122b13c17c413610 100644 (file)
@@ -6,6 +6,7 @@
 #include <string.h>
 #ifdef KERNEL
 #include "threads/interrupt.h"
+#include "devices/serial.h"
 #else
 #include <syscall.h>
 #endif
@@ -81,6 +82,7 @@ debug_panic (const char *file, int line, const char *function,
   debug_backtrace ();
 
 #ifdef KERNEL
+  serial_flush ();
   for (;;);
 #else
   exit (1);