summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormarcel <marcel@FreeBSD.org>2004-09-17 22:27:23 +0000
committermarcel <marcel@FreeBSD.org>2004-09-17 22:27:23 +0000
commitf2afc2cd7a6361c1d4eb98545c92556d3cd59656 (patch)
tree9bd19187808584ba8d3c7c960925d529c34fb75b
parent2ca675d9a88fde7c309b7bdd38263acc90f3dade (diff)
downloadFreeBSD-src-f2afc2cd7a6361c1d4eb98545c92556d3cd59656.zip
FreeBSD-src-f2afc2cd7a6361c1d4eb98545c92556d3cd59656.tar.gz
Move makectx() after kdb_cpu_trap(), so the PCB will have possible MD
corrections made to the trapframe. This is more logical.
-rw-r--r--sys/kern/subr_kdb.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/kern/subr_kdb.c b/sys/kern/subr_kdb.c
index 08675d2..193694f 100644
--- a/sys/kern/subr_kdb.c
+++ b/sys/kern/subr_kdb.c
@@ -399,13 +399,9 @@ kdb_trap(int type, int code, struct trapframe *tf)
if (kdb_active)
return (0);
- makectx(tf, &kdb_pcb);
-
critical_enter();
kdb_active++;
- kdb_frame = tf;
- kdb_thr_select(curthread);
#ifdef SMP
if ((did_stop_cpus = kdb_stop_cpus) != 0)
@@ -415,6 +411,10 @@ kdb_trap(int type, int code, struct trapframe *tf)
/* Let MD code do its thing first... */
kdb_cpu_trap(type, code);
+ kdb_frame = tf;
+ makectx(tf, &kdb_pcb);
+ kdb_thr_select(curthread);
+
handled = kdb_dbbe->dbbe_trap(type, code);
#ifdef SMP
OpenPOWER on IntegriCloud