summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorotto <otto@openbsd.org>2007-10-18 20:28:26 +0000
committerotto <otto@openbsd.org>2007-10-18 20:28:26 +0000
commit6fa98349e147d76e54250065fbe9dd331d798bfa (patch)
tree660431414363fdf986bb042ca2a15587a4e31185 /sys
parentCorrect possible spl problem in buffer cleaning daemon - the buffer cleaning (diff)
downloadwireguard-openbsd-6fa98349e147d76e54250065fbe9dd331d798bfa.tar.xz
wireguard-openbsd-6fa98349e147d76e54250065fbe9dd331d798bfa.zip
avoid splassert, caused by the fact that iha_main() is called
unprotected by iha_exec_scb(). With help and ok miod@
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/ic/iha.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/dev/ic/iha.c b/sys/dev/ic/iha.c
index 50d01b3fd12..fb04412ab47 100644
--- a/sys/dev/ic/iha.c
+++ b/sys/dev/ic/iha.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: iha.c,v 1.26 2007/04/10 17:47:55 miod Exp $ */
+/* $OpenBSD: iha.c,v 1.27 2007/10/18 20:28:26 otto Exp $ */
/*-------------------------------------------------------------------------
*
* Device driver for the INI-9XXXU/UW or INIC-940/950 PCI SCSI Controller.
@@ -2482,6 +2482,7 @@ iha_done_scb(sc, pScb)
{
struct scsi_sense_data *s1, *s2;
struct scsi_xfer *xs = pScb->SCB_Xs;
+ int s;
if (xs != NULL) {
timeout_del(&xs->stimeout);
@@ -2562,7 +2563,9 @@ iha_done_scb(sc, pScb)
}
xs->flags |= ITSDONE;
+ s = splbio();
scsi_done(xs);
+ splx(s);
}
iha_append_free_scb(sc, pScb);