Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src/sys/dev



Module Name:    src
Committed By:   bouyer
Date:           Sat Oct 30 23:10:37 UTC 2004

Modified Files:
        src/sys/dev/ata: ata.c atavar.h
        src/sys/dev/ic: wdc.c

Log Message:
Allow polled commands to be queued, if ata_exec_xfer() is called in thread
context. For this introduce 3 new xfer tags:
- C_WAIT, equivalent of AT_WAIT
- C_WAITACT, when there is a thread waiting on this xfer to become the active
  one (that is, to be at the head of the queue)
- C_FREE, set by ata_free_xfer() when it can't free the xfer because it's
  still in use. The holder should then free the xfer ASAP.

If ata_exec_xfer() is called with (C_POLL | C_WAIT), and there is already
xfers to be processed, assert C_WAITACT and sleep.
atastart() checks for C_WAITACT, and wakeup the thread waiting for this xfer
to become active if set. atastart() won't process this xfer, it's the
responsability of the thread waked up to handle it.

Fix (the right way) kern/27421 by Martin Husemann.


To generate a diff of this commit:
cvs rdiff -r1.61 -r1.62 src/sys/dev/ata/ata.c
cvs rdiff -r1.64 -r1.65 src/sys/dev/ata/atavar.h
cvs rdiff -r1.216 -r1.217 src/sys/dev/ic/wdc.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index