summaryrefslogtreecommitdiff
path: root/sys/arch/mips64
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2008-06-22 21:02:12 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2008-06-22 21:02:12 +0000
commit8af57fdf574da8b61433ede4ae2b3b17f6d9cb5c (patch)
tree8742b7bffbc7c2d2956e3e6d14683f93c3632946 /sys/arch/mips64
parent59be0deb6c8aa359e4c31003703d97b85e6e3e94 (diff)
Like alpha, db_stack_dump() on mips and sh needs complete frame information
and can not work from a stack address only. Mention this and abort instead of printing a wrong trace. (prefer kern.splassert=3 to =2 on these platforms)
Diffstat (limited to 'sys/arch/mips64')
-rw-r--r--sys/arch/mips64/mips64/db_machdep.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/sys/arch/mips64/mips64/db_machdep.c b/sys/arch/mips64/mips64/db_machdep.c
index 245a5808b31..f84585025a0 100644
--- a/sys/arch/mips64/mips64/db_machdep.c
+++ b/sys/arch/mips64/mips64/db_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.c,v 1.16 2008/02/29 19:00:39 miod Exp $ */
+/* $OpenBSD: db_machdep.c,v 1.17 2008/06/22 21:02:10 miod Exp $ */
/*
* Copyright (c) 1998-2003 Opsycon AB (www.opsycon.se)
@@ -224,6 +224,11 @@ db_stack_trace_print(addr, have_addr, count, modif, pr)
extern char k_general[];
struct trap_frame *regs = &ddb_regs;
+ if (have_addr) {
+ (*pr)("mips trace requires a trap frame... giving up\n");
+ return;
+ }
+
/* get initial values from the exception frame */
sp = (vaddr_t)regs->sp;
pc = (vaddr_t)regs->pc;