Commit a8be57ca authored by Matthew Wilcox's avatar Matthew Wilcox Committed by James Bottomley

scsi: remove device_request_lock

The static device_request_lock doesn't protect anything; remove it.
Signed-off-by: default avatarMatthew Wilcox <matthew@wil.cx>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@SteelEye.com>
parent e59d89da
......@@ -936,12 +936,9 @@ EXPORT_SYMBOL(scsi_finish_command);
* the right thing depending on whether or not the device is
* currently active and whether or not it even has the
* command blocks built yet.
*
* XXX(hch): What exactly is device_request_lock trying to protect?
*/
void scsi_adjust_queue_depth(struct scsi_device *sdev, int tagged, int tags)
{
static DEFINE_SPINLOCK(device_request_lock);
unsigned long flags;
/*
......@@ -950,8 +947,7 @@ void scsi_adjust_queue_depth(struct scsi_device *sdev, int tagged, int tags)
if (tags <= 0)
return;
spin_lock_irqsave(&device_request_lock, flags);
spin_lock(sdev->request_queue->queue_lock);
spin_lock_irqsave(sdev->request_queue->queue_lock, flags);
/* Check to see if the queue is managed by the block layer
* if it is, and we fail to adjust the depth, exit */
......@@ -980,8 +976,7 @@ void scsi_adjust_queue_depth(struct scsi_device *sdev, int tagged, int tags)
break;
}
out:
spin_unlock(sdev->request_queue->queue_lock);
spin_unlock_irqrestore(&device_request_lock, flags);
spin_unlock_irqrestore(sdev->request_queue->queue_lock, flags);
}
EXPORT_SYMBOL(scsi_adjust_queue_depth);
......
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