From dba2c14fc5ff2908158bc7a7f351782b0eb64883 Mon Sep 17 00:00:00 2001 From: Tejun Heo Date: Sat, 14 May 2005 00:46:08 +0900 Subject: [PATCH] --- yaml --- r: 2054 b: refs/heads/master c: d8c37e7b9a619855e05d5d4e56c68f799b1f539c h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/scsi/scsi.c | 10 ++++++---- trunk/drivers/scsi/scsi_lib.c | 8 +------- 3 files changed, 8 insertions(+), 12 deletions(-) diff --git a/[refs] b/[refs] index 7a8bc1a42c4b..8ca30f026e5b 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 5b8ef8425898e957243053c26ac2b68bd4bc42ec +refs/heads/master: d8c37e7b9a619855e05d5d4e56c68f799b1f539c diff --git a/trunk/drivers/scsi/scsi.c b/trunk/drivers/scsi/scsi.c index 05d2bd075fd4..0d730f646bce 100644 --- a/trunk/drivers/scsi/scsi.c +++ b/trunk/drivers/scsi/scsi.c @@ -638,10 +638,12 @@ int scsi_dispatch_cmd(struct scsi_cmnd *cmd) } spin_unlock_irqrestore(host->host_lock, flags); if (rtn) { - atomic_inc(&cmd->device->iodone_cnt); - scsi_queue_insert(cmd, - (rtn == SCSI_MLQUEUE_DEVICE_BUSY) ? - rtn : SCSI_MLQUEUE_HOST_BUSY); + if (scsi_delete_timer(cmd)) { + atomic_inc(&cmd->device->iodone_cnt); + scsi_queue_insert(cmd, + (rtn == SCSI_MLQUEUE_DEVICE_BUSY) ? + rtn : SCSI_MLQUEUE_HOST_BUSY); + } SCSI_LOG_MLQUEUE(3, printk("queuecommand : request rejected\n")); } diff --git a/trunk/drivers/scsi/scsi_lib.c b/trunk/drivers/scsi/scsi_lib.c index c3bb28c3feef..9f996499fa9d 100644 --- a/trunk/drivers/scsi/scsi_lib.c +++ b/trunk/drivers/scsi/scsi_lib.c @@ -128,13 +128,7 @@ int scsi_queue_insert(struct scsi_cmnd *cmd, int reason) printk("Inserting command %p into mlqueue\n", cmd)); /* - * We are inserting the command into the ml queue. First, we - * cancel the timer, so it doesn't time out. - */ - scsi_delete_timer(cmd); - - /* - * Next, set the appropriate busy bit for the device/host. + * Set the appropriate busy bit for the device/host. * * If the host/device isn't busy, assume that something actually * completed, and that we should be able to queue a command now.