summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/sd.c
diff options
context:
space:
mode:
authorK. Y. Srinivasan <kys@microsoft.com>2014-07-18 17:11:27 +0200
committerChristoph Hellwig <hch@lst.de>2014-07-25 17:16:42 -0400
commit26b9fd8b3452dcf0a8862e307ee23f442f63fb51 (patch)
tree22d0fd5c350181ba93b105974379210cc007ef70 /drivers/scsi/sd.c
parentc1d40a527e885a40bb9ea6c46a1b1145d42b66a0 (diff)
downloadop-kernel-dev-26b9fd8b3452dcf0a8862e307ee23f442f63fb51.zip
op-kernel-dev-26b9fd8b3452dcf0a8862e307ee23f442f63fb51.tar.gz
sd: fix a bug in deriving the FLUSH_TIMEOUT from the basic I/O timeout
Commit ID: 7e660100d85af860e7ad763202fff717adcdaacd added code to derive the FLUSH_TIMEOUT from the basic I/O timeout. However, this patch did not use the basic I/O timeout of the device. Fix this bug. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Reviewed-by: James Bottomley <JBottomley@Parallels.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/scsi/sd.c')
-rw-r--r--drivers/scsi/sd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c
index 4d72831..2c2041c 100644
--- a/drivers/scsi/sd.c
+++ b/drivers/scsi/sd.c
@@ -880,7 +880,7 @@ static int sd_setup_flush_cmnd(struct scsi_cmnd *cmd)
cmd->transfersize = 0;
cmd->allowed = SD_MAX_RETRIES;
- rq->timeout *= SD_FLUSH_TIMEOUT_MULTIPLIER;
+ rq->timeout = rq->q->rq_timeout * SD_FLUSH_TIMEOUT_MULTIPLIER;
return BLKPREP_OK;
}
OpenPOWER on IntegriCloud