Merge branch 'for-linus' of git://git.kernel.dk/linux-2.6-block
* 'for-linus' of git://git.kernel.dk/linux-2.6-block: block: don't delay blk_run_queue_async scsi: remove performance regression due to async queue run blk-throttle: Use task_subsys_state() to determine a task's blkio_cgroup block: rescan partitions on invalidated devices on -ENOMEDIA too cdrom: always check_disk_change() on open block: unexport DISK_EVENT_MEDIA_CHANGE for legacy/fringe drivers
This commit is contained in:
@ -74,8 +74,6 @@ struct kmem_cache *scsi_sdb_cache;
|
||||
*/
|
||||
#define SCSI_QUEUE_DELAY 3
|
||||
|
||||
static void scsi_run_queue(struct request_queue *q);
|
||||
|
||||
/*
|
||||
* Function: scsi_unprep_request()
|
||||
*
|
||||
@ -161,7 +159,7 @@ static int __scsi_queue_insert(struct scsi_cmnd *cmd, int reason, int unbusy)
|
||||
blk_requeue_request(q, cmd->request);
|
||||
spin_unlock_irqrestore(q->queue_lock, flags);
|
||||
|
||||
scsi_run_queue(q);
|
||||
kblockd_schedule_work(q, &device->requeue_work);
|
||||
|
||||
return 0;
|
||||
}
|
||||
@ -438,7 +436,11 @@ static void scsi_run_queue(struct request_queue *q)
|
||||
continue;
|
||||
}
|
||||
|
||||
blk_run_queue_async(sdev->request_queue);
|
||||
spin_unlock(shost->host_lock);
|
||||
spin_lock(sdev->request_queue->queue_lock);
|
||||
__blk_run_queue(sdev->request_queue);
|
||||
spin_unlock(sdev->request_queue->queue_lock);
|
||||
spin_lock(shost->host_lock);
|
||||
}
|
||||
/* put any unprocessed entries back */
|
||||
list_splice(&starved_list, &shost->starved_list);
|
||||
@ -447,6 +449,16 @@ static void scsi_run_queue(struct request_queue *q)
|
||||
blk_run_queue(q);
|
||||
}
|
||||
|
||||
void scsi_requeue_run_queue(struct work_struct *work)
|
||||
{
|
||||
struct scsi_device *sdev;
|
||||
struct request_queue *q;
|
||||
|
||||
sdev = container_of(work, struct scsi_device, requeue_work);
|
||||
q = sdev->request_queue;
|
||||
scsi_run_queue(q);
|
||||
}
|
||||
|
||||
/*
|
||||
* Function: scsi_requeue_command()
|
||||
*
|
||||
|
Reference in New Issue
Block a user