linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "K. Y. Srinivasan" <kys@microsoft.com>
To: gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org,
	devel@linuxdriverproject.org, ohering@suse.com,
	jbottomley@parallels.com, hch@infradead.org,
	linux-scsi@vger.kernel.org
Cc: "K. Y. Srinivasan" <kys@microsoft.com>
Subject: [PATCH 1/5] Drivers: scsi: storvsc: Increase the value of scsi timeout for storvsc devices
Date: Tue,  4 Jun 2013 12:05:05 -0700	[thread overview]
Message-ID: <1370372709-10098-1-git-send-email-kys@microsoft.com> (raw)
In-Reply-To: <1370372674-10046-1-git-send-email-kys@microsoft.com>

The standard scsi timeout is not appropriate in some of the environments where
Hyper-V is deployed. Set this timeout appropriately for all devices managed
by this driver.

On cloud environments where storage latencies may be unbounded, having the scsi
layer initiating recovery can be problematic since (a) the host is already
implementing a variety of recovery strategies and (b) implementing a recovery
strategy at the VM level may be more appropriate in cases where storage latencies
exceed a certain threshold.

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
---
 drivers/scsi/storvsc_drv.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/drivers/scsi/storvsc_drv.c b/drivers/scsi/storvsc_drv.c
index 16a3a0c..ede8694 100644
--- a/drivers/scsi/storvsc_drv.c
+++ b/drivers/scsi/storvsc_drv.c
@@ -221,6 +221,11 @@ static int storvsc_ringbuffer_size = (20 * PAGE_SIZE);
 module_param(storvsc_ringbuffer_size, int, S_IRUGO);
 MODULE_PARM_DESC(storvsc_ringbuffer_size, "Ring buffer size (bytes)");
 
+/*
+ * Timeout in seconds for all devices managed by this driver.
+ */
+static int storvsc_timeout = 180;
+
 #define STORVSC_MAX_IO_REQUESTS				128
 
 /*
@@ -1204,6 +1209,8 @@ static int storvsc_device_configure(struct scsi_device *sdevice)
 
 	blk_queue_bounce_limit(sdevice->request_queue, BLK_BOUNCE_ANY);
 
+	blk_queue_rq_timeout(sdevice->request_queue, (storvsc_timeout * HZ));
+
 	sdevice->no_write_same = 1;
 
 	return 0;
-- 
1.7.4.1

  reply	other threads:[~2013-06-04 19:05 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-04 19:04 [PATCH V3 0/5] Drivers: scsi: storvsc K. Y. Srinivasan
2013-06-04 19:05 ` K. Y. Srinivasan [this message]
2013-06-04 19:05   ` [PATCH 2/5] Drivers: scsi: storvsc: Update the storage protocol to win8 level K. Y. Srinivasan
2013-06-04 19:05   ` [PATCH 3/5] Drivers: scsi: storvsc: Implement multi-channel support K. Y. Srinivasan
2013-06-27  3:22     ` James Bottomley
2013-06-27 11:50       ` KY Srinivasan
2013-06-04 19:05   ` [PATCH 4/5] Drivers: scsi: storvsc: Support FC devices K. Y. Srinivasan
2013-06-04 19:05   ` [PATCH 5/5] Drivers: scsi: storvsc: Increase the value of STORVSC_MAX_IO_REQUESTS K. Y. Srinivasan
2013-06-11 13:02 ` [PATCH V3 0/5] Drivers: scsi: storvsc KY Srinivasan
2013-06-17 13:32   ` KY Srinivasan
2013-06-26 12:58   ` KY Srinivasan
2013-06-27  3:39     ` James Bottomley

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1370372709-10098-1-git-send-email-kys@microsoft.com \
    --to=kys@microsoft.com \
    --cc=devel@linuxdriverproject.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=hch@infradead.org \
    --cc=jbottomley@parallels.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=ohering@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).