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.
This commit is contained in:
David Greenman 1993-11-25 06:30:58 +00:00
parent 381fe1aaf4
commit 57594c8752
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=799

View File

@ -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"));