aboutsummaryrefslogtreecommitdiff
path: root/sys/pc98
diff options
context:
space:
mode:
authorKATO Takenori <kato@FreeBSD.org>2001-01-28 12:31:03 +0000
committerKATO Takenori <kato@FreeBSD.org>2001-01-28 12:31:03 +0000
commit9ec492e57bd543e8f89413ddd9edd8283cc53bbc (patch)
treee627b45e946f686171e8846e0b6fdedcded014bf /sys/pc98
parentc30d5afab4db43a2b2b7a1738960aa8d274a6b45 (diff)
Notes
Diffstat (limited to 'sys/pc98')
-rw-r--r--sys/pc98/pc98/npx.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sys/pc98/pc98/npx.c b/sys/pc98/pc98/npx.c
index 6dbb355ea94fb..0f9a8b59eb9fe 100644
--- a/sys/pc98/pc98/npx.c
+++ b/sys/pc98/pc98/npx.c
@@ -48,6 +48,7 @@
#include <sys/module.h>
#include <sys/sysctl.h>
#include <sys/proc.h>
+#include <sys/mutex.h>
#include <machine/bus.h>
#include <sys/rman.h>
#ifdef NPX_DEBUG
@@ -439,7 +440,8 @@ npx_probe1(dev)
if (r == 0)
panic("npx: can't get IRQ");
BUS_SETUP_INTR(device_get_parent(dev),
- dev, r, INTR_TYPE_MISC,
+ dev, r,
+ INTR_TYPE_MISC | INTR_MPSAFE,
npx_intr, 0, &intr);
if (intr == 0)
panic("npx: can't create intr");
@@ -563,7 +565,7 @@ npxexit(p)
u_int masked_exceptions;
masked_exceptions = PCPU_GET(curpcb)->pcb_savefpu.sv_env.en_cw
- &PCPU_GET(curpcb)->pcb_savefpu.sv_env.en_sw & 0x7f;
+ & PCPU_GET(curpcb)->pcb_savefpu.sv_env.en_sw & 0x7f;
/*
* Log exceptions that would have trapped with the old
* control word (overflow, divide by 0, and invalid operand).
@@ -772,6 +774,7 @@ npx_intr(dummy)
u_short control;
struct intrframe *frame;
+ mtx_enter(&Giant, MTX_DEF);
if (PCPU_GET(npxproc) == NULL || !npx_exists) {
printf("npxintr: npxproc = %p, curproc = %p, npx_exists = %d\n",
PCPU_GET(npxproc), curproc, npx_exists);
@@ -834,6 +837,7 @@ npx_intr(dummy)
*/
psignal(curproc, SIGFPE);
}
+ mtx_exit(&Giant, MTX_DEF);
}
/*