summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/scsi_queue.c
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2000-02-16 01:07:24 +0000
committerRalf Baechle <ralf@linux-mips.org>2000-02-16 01:07:24 +0000
commit95db6b748fc86297827fbd9c9ef174d491c9ad89 (patch)
tree27a92a942821cde1edda9a1b088718d436b3efe4 /drivers/scsi/scsi_queue.c
parent45b27b0a0652331d104c953a5b192d843fff88f8 (diff)
Merge with Linux 2.3.40.
Diffstat (limited to 'drivers/scsi/scsi_queue.c')
-rw-r--r--drivers/scsi/scsi_queue.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/scsi/scsi_queue.c b/drivers/scsi/scsi_queue.c
index 4a62566f1..162088204 100644
--- a/drivers/scsi/scsi_queue.c
+++ b/drivers/scsi/scsi_queue.c
@@ -79,6 +79,7 @@ static const char RCSid[] = "$Header: /mnt/ide/home/eric/CVSROOT/linux/drivers/s
int scsi_mlqueue_insert(Scsi_Cmnd * cmd, int reason)
{
struct Scsi_Host *host;
+ unsigned long flags;
SCSI_LOG_MLQUEUE(1, printk("Inserting command %p into mlqueue\n", cmd));
@@ -136,8 +137,10 @@ int scsi_mlqueue_insert(Scsi_Cmnd * cmd, int reason)
* Decrement the counters, since these commands are no longer
* active on the host/device.
*/
+ spin_lock_irqsave(&io_request_lock, flags);
cmd->host->host_busy--;
cmd->device->device_busy--;
+ spin_unlock_irqrestore(&io_request_lock, flags);
/*
* Insert this command at the head of the queue for it's device.