diff options
Diffstat (limited to 'drivers/scsi/scsi.c')
-rw-r--r-- | drivers/scsi/scsi.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/drivers/scsi/scsi.c b/drivers/scsi/scsi.c index ee6be596503d..762a8797e0be 100644 --- a/drivers/scsi/scsi.c +++ b/drivers/scsi/scsi.c | |||
@@ -664,13 +664,14 @@ int scsi_dispatch_cmd(struct scsi_cmnd *cmd) | |||
664 | goto out; | 664 | goto out; |
665 | } | 665 | } |
666 | 666 | ||
667 | /* Check to see if the scsi lld put this device into state SDEV_BLOCK. */ | 667 | /* Check to see if the scsi lld made this device blocked. */ |
668 | if (unlikely(cmd->device->sdev_state == SDEV_BLOCK)) { | 668 | if (unlikely(scsi_device_blocked(cmd->device))) { |
669 | /* | 669 | /* |
670 | * in SDEV_BLOCK, the command is just put back on the device | 670 | * in blocked state, the command is just put back on |
671 | * queue. The suspend state has already blocked the queue so | 671 | * the device queue. The suspend state has already |
672 | * future requests should not occur until the device | 672 | * blocked the queue so future requests should not |
673 | * transitions out of the suspend state. | 673 | * occur until the device transitions out of the |
674 | * suspend state. | ||
674 | */ | 675 | */ |
675 | scsi_queue_insert(cmd, SCSI_MLQUEUE_DEVICE_BUSY); | 676 | scsi_queue_insert(cmd, SCSI_MLQUEUE_DEVICE_BUSY); |
676 | 677 | ||