Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/alpha/alpha Panic if we get an MM trans/prot fault ...
details: https://anonhg.NetBSD.org/src/rev/e80a993409ad
branches: trunk
changeset: 511771:e80a993409ad
user: thorpej <thorpej%NetBSD.org@localhost>
date: Tue Jun 26 17:29:28 2001 +0000
description:
Panic if we get an MM trans/prot fault in interrupt context.
diffstat:
sys/arch/alpha/alpha/trap.c | 13 +++++++++++--
1 files changed, 11 insertions(+), 2 deletions(-)
diffs (41 lines):
diff -r 8ee7184cc026 -r e80a993409ad sys/arch/alpha/alpha/trap.c
--- a/sys/arch/alpha/alpha/trap.c Tue Jun 26 17:27:31 2001 +0000
+++ b/sys/arch/alpha/alpha/trap.c Tue Jun 26 17:29:28 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: trap.c,v 1.72 2001/06/02 18:09:08 chs Exp $ */
+/* $NetBSD: trap.c,v 1.73 2001/06/26 17:29:28 thorpej Exp $ */
/*-
* Copyright (c) 2000 The NetBSD Foundation, Inc.
@@ -99,7 +99,7 @@
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
-__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.72 2001/06/02 18:09:08 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.73 2001/06/26 17:29:28 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -361,6 +361,8 @@
if (user)
KERNEL_PROC_LOCK(p);
else {
+ struct cpu_info *ci = curcpu();
+
if (p == NULL) {
/*
* If there is no current process,
@@ -387,6 +389,13 @@
goto out;
}
+ /*
+ * If we're in interrupt context at this
+ * point, this is an error.
+ */
+ if (ci->ci_intrdepth != 0)
+ goto dopanic;
+
KERNEL_LOCK(LK_CANRECURSE|LK_EXCLUSIVE);
}
Home |
Main Index |
Thread Index |
Old Index