aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Greenman <dg@FreeBSD.org>1993-11-25 06:30:58 +0000
committerDavid Greenman <dg@FreeBSD.org>1993-11-25 06:30:58 +0000
commit57594c8752df99c242856d2ff1735dd7cad36bb5 (patch)
treef01ed7ee8ad68574f1f927bba57e2d5bab37b7c3
parent381fe1aaf4d3cb1ad62f758c15ace6cb07eea97a (diff)
downloadsrc-57594c8752df99c242856d2ff1735dd7cad36bb5.tar.gz
src-57594c8752df99c242856d2ff1735dd7cad36bb5.zip
Patch from Julian Elischer:
Here is the fix for the 'hanging' bug. This bug happenned whenever two operations were already underway on the disk and a third (non-IO) command was requested.. in this case the process submitting the NON-IO command was requested to wait, and a flag set so that on completion of the IO commands, the Non-io command was given priority over any pending IO commands. (the queue is not allowed to drain while there are pending "special" ops). The flag that indicated this was not being reset, so further IO commands were prohibited from that moment on.
Notes
Notes: svn path=/head/; revision=799
-rw-r--r--sys/scsi/scsi_base.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/scsi/scsi_base.c b/sys/scsi/scsi_base.c
index a1361ec25699..da9c2b4d94ad 100644
--- a/sys/scsi/scsi_base.c
+++ b/sys/scsi/scsi_base.c
@@ -8,7 +8,7 @@
* file.
*
* Written by Julian Elischer (julian@dialix.oz.au)
- * $Id: scsi_base.c,v 2.4 93/10/16 00:58:43 julian Exp Locker: julian $
+ * $Id: scsi_base.c,v 1.1 1993/11/18 05:02:51 rgrimes Exp $
*/
#define SPLSD splbio
@@ -109,7 +109,8 @@ free_xs(xs, sc_link, flags)
SC_DEBUG(sc_link, SDEV_DB3, ("free_xs\n"));
/* if was 0 and someone waits, wake them up */
if ((!sc_link->opennings++) && (sc_link->flags & SDEV_WAITING)) {
- wakeup(sc_link);
+ sc_link->flags &= ~SDEV_WAITING;
+ wakeup(sc_link); /* remember, it wakes them ALL up */
} else {
if (sc_link->device->start) {
SC_DEBUG(sc_link, SDEV_DB2, ("calling private start()\n"));