Messages in this thread Patch in this message | | | Date | Wed, 26 Jan 2000 17:56:12 +0100 | From | Jens Axboe <> | Subject | Re: RFC: request merges with active heads |
| |
On Wed, Jan 26 2000, Jens Axboe wrote: > for the first block and a second with the rest merged. I propose > that we add a RQ_STARTED flag or similar to let ll_rw_blk determine > whether it is safe to merge with the current_request for drivers > that have an active request head.
A better way to handle this, as suggested to me by Eric Youngdale, is to check whether the device is plugged or not. If the device is plugged we can safely assume that the request is currently not being worked and in that case there's no need to skip that entry while merging, because a queue is never plugged while it has entries on it and a request cannot become active while a queue is plugged.
-- * Jens Axboe <axboe@suse.de> * Linux CD-ROM Maintainer * http://www.kernel.dk --- ll_rw_blk.c~ Wed Jan 26 17:48:56 2000 +++ ll_rw_blk.c Wed Jan 26 17:49:57 2000 @@ -589,7 +589,7 @@ goto get_rq; } - if (q->head_active) { + if (q->head_active && !q->plugged) { /* * The scsi disk and cdrom drivers completely remove the request * from the queue when they start processing an entry. For this | |