aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/sd.c
diff options
context:
space:
mode:
authorMike Christie <mchristi@redhat.com>2010-08-11 12:06:25 -0400
committerJames Bottomley <James.Bottomley@suse.de>2010-09-05 13:57:04 -0400
commite3b3e6246726cd05950677ed843010b8e8c5884c (patch)
tree587375d4709159d4fe435dabedc6f3fcf0ab71f8 /drivers/scsi/sd.c
parent1c1acab0367d88ad5da2b9db2efdf2699113ec88 (diff)
[SCSI] scsi/block: increase flush/sync timeout
We have been seeing the flush request timeout with a wide range of hardware from tgt+iser to FC targets from a major vendor. After discussions about if the value should be configurable and what the best value should be, this patch just increases the flush/sync cache timeout to 1 minute. 2 minutes was determined to be too long, and making it configurable was troublesome for users. This patch was made over Linus's tree. It is not made over scsi-misc or scsi-rc-fixes, because Linus's had block layer changes that my patch was built over. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Acked-by: Jens Axboe <jaxboe@fusionio.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/sd.c')
-rw-r--r--drivers/scsi/sd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c
index 2714becc2eaf..8c9b275f71a7 100644
--- a/drivers/scsi/sd.c
+++ b/drivers/scsi/sd.c
@@ -477,7 +477,7 @@ static int scsi_setup_discard_cmnd(struct scsi_device *sdp, struct request *rq)
477 477
478static int scsi_setup_flush_cmnd(struct scsi_device *sdp, struct request *rq) 478static int scsi_setup_flush_cmnd(struct scsi_device *sdp, struct request *rq)
479{ 479{
480 rq->timeout = SD_TIMEOUT; 480 rq->timeout = SD_FLUSH_TIMEOUT;
481 rq->retries = SD_MAX_RETRIES; 481 rq->retries = SD_MAX_RETRIES;
482 rq->cmd[0] = SYNCHRONIZE_CACHE; 482 rq->cmd[0] = SYNCHRONIZE_CACHE;
483 rq->cmd_len = 10; 483 rq->cmd_len = 10;
@@ -1072,7 +1072,7 @@ static int sd_sync_cache(struct scsi_disk *sdkp)
1072 * flush everything. 1072 * flush everything.
1073 */ 1073 */
1074 res = scsi_execute_req(sdp, cmd, DMA_NONE, NULL, 0, &sshdr, 1074 res = scsi_execute_req(sdp, cmd, DMA_NONE, NULL, 0, &sshdr,
1075 SD_TIMEOUT, SD_MAX_RETRIES, NULL); 1075 SD_FLUSH_TIMEOUT, SD_MAX_RETRIES, NULL);
1076 if (res == 0) 1076 if (res == 0)
1077 break; 1077 break;
1078 } 1078 }