Commit 996bfdf1 authored by James Bottomley's avatar James Bottomley Committed by Christoph Hellwig

fix queue plug performance problem found by akpm

Fix is to only plug on prep deferral if the device queue is empty
(otherwise we can rely on returning I/O to restart the queue)
parent a1a477f9
...@@ -984,9 +984,10 @@ void scsi_request_fn(request_queue_t * q) ...@@ -984,9 +984,10 @@ void scsi_request_fn(request_queue_t * q)
break; break;
if(!req) { if(!req) {
/* can happen if the prep fails /* If the device is busy, a returning I/O
* FIXME: elv_next_request() should be plugging the * will restart the queue. Otherwise, we have
* queue */ * to plug the queue */
if(SDpnt->device_busy == 0)
blk_plug_device(q); blk_plug_device(q);
break; break;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment