Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 30 May 2003 13:30:13 -0700 (PDT)
From:      Juli Mallett <jmallett@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 32119 for review
Message-ID:  <200305302030.h4UKUDFZ068726@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=32119

Change 32119 by jmallett@jmallett_dalek on 2003/05/30 13:29:22

	Enter DDB on breakpoint traps.  This actually works.  It
	also means we have to nest twice, for now.  First the real
	problem, then panic("trap") then the debugger.  This is enough
	to poke around a little.

Affected files ...

.. //depot/projects/mips/sys/mips/mips/trap.c#5 edit

Differences ...

==== //depot/projects/mips/sys/mips/mips/trap.c#5 (text+ko) ====

@@ -25,6 +25,8 @@
  * $FreeBSD$
  */
 
+#include "opt_ddb.h"
+
 #include <sys/param.h>
 #include <sys/kernel.h>
 #include <sys/systm.h>
@@ -98,6 +100,18 @@
 	printf("bad virtual address = %p\n", badvaddr);
 	printf("              cause = %x\n", cause);
 	printf("             status = %lx\n", tf->tf_regs[TF_SR]);
+
+	switch (code) {
+	case T_BREAK:
+#if	DDB
+		kdb_trap(code, tf);
+		break;
+#endif
+	default:
+		goto dopanic;
+	}
+	return;
+dopanic:
 	if (panicstr != NULL) {
 		printf("Double panic, resetting...\n");
 		cpu_reset();



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200305302030.h4UKUDFZ068726>