WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [patch] print panic message before trapping to debugger

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [patch] print panic message before trapping to debugger
From: Hollis Blanchard <hollisb@xxxxxxxxxx>
Date: Tue, 14 Mar 2006 15:12:21 -0600
Delivery-date: Tue, 14 Mar 2006 21:13:42 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Organization: IBM Linux Technology Center
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: KMail/1.8.3
I've found it useful to display the panic message *before* dropping into the 
debugger. Once there it may be very difficult to find the original message, 
and often a debugger isn't even needed if you can see what panicked.

Signed-off-by: Hollis Blanchard <hollisb@xxxxxxxxxx>

# HG changeset patch
# User hollisb@basalt
# Node ID c6267fda4f4c899dbf0f23191a658d7f18ca7c3c
# Parent  686cd624618cead274ea9850f0997d41c6134283
print panic message before trapping to debugger

diff -r 686cd624618c -r c6267fda4f4c xen/drivers/char/console.c
--- a/xen/drivers/char/console.c        Tue Mar 14 14:56:55 2006 -0600
+++ b/xen/drivers/char/console.c        Tue Mar 14 15:02:27 2006 -0600
@@ -683,8 +683,6 @@ void panic(const char *fmt, ...)
     (void)vsnprintf(buf, sizeof(buf), fmt, args);
     va_end(args);
 
-    debugger_trap_immediate();
-
     /* Spit out multiline message in one go. */
     spin_lock_irqsave(&lock, flags);
     printk("\n****************************************\n");
@@ -694,6 +692,8 @@ void panic(const char *fmt, ...)
     printk("Reboot in five seconds...\n");
     spin_unlock_irqrestore(&lock, flags);
 
+    debugger_trap_immediate();
+
     watchdog_disable();
     mdelay(5000);
     machine_restart(0);

-- 
Hollis Blanchard
IBM Linux Technology Center

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [patch] print panic message before trapping to debugger, Hollis Blanchard <=