From: Mike Sterling <steelforce@gmail.com>
To: devel@linuxdriverproject.org, virtualization@lists.osdl.org,
gregkh@suse.de, linux-kernel@vger.kernel.org
Cc: Mike Sterling <mike.sterling@microsoft.com>,
"K.Y. Srinivasan" <kys@microsoft.com>,
Haiyang Zhang <haiyangz@microsoft.com>
Subject: [PATCH 1/1] staging: hv: Add support for >2 TB LUN in storage driver.
Date: Thu, 1 Sep 2011 14:11:52 -0700 [thread overview]
Message-ID: <1314911512-1079-1-git-send-email-mike.sterling@microsoft.com> (raw)
If a LUN larger than 2 TB is attached to a Linux VM on Hyper-V, we currently
report a maximum size of 2 TB. This patch resolves the issue in hv_storvsc.
Thanks to Robert Scheck <robert.scheck@etes.de> for reporting the issue.
Signed-off-by: Mike Sterling <mike.sterling@microsoft.com>
Signed-off-by: K.Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
---
drivers/staging/hv/hyperv_storage.h | 1 +
drivers/staging/hv/storvsc_drv.c | 2 ++
2 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/staging/hv/hyperv_storage.h b/drivers/staging/hv/hyperv_storage.h
index a01f9a0..5af82f4 100644
--- a/drivers/staging/hv/hyperv_storage.h
+++ b/drivers/staging/hv/hyperv_storage.h
@@ -218,6 +218,7 @@ struct vstor_packet {
#define STORVSC_MAX_LUNS_PER_TARGET 64
#define STORVSC_MAX_TARGETS 1
#define STORVSC_MAX_CHANNELS 1
+#define STORVSC_MAX_CMD_LEN 16
struct hv_storvsc_request;
diff --git a/drivers/staging/hv/storvsc_drv.c b/drivers/staging/hv/storvsc_drv.c
index 7effaf3..26983ac 100644
--- a/drivers/staging/hv/storvsc_drv.c
+++ b/drivers/staging/hv/storvsc_drv.c
@@ -701,6 +701,8 @@ static int storvsc_probe(struct hv_device *device)
host->max_id = STORVSC_MAX_TARGETS;
/* max # of channels */
host->max_channel = STORVSC_MAX_CHANNELS - 1;
+ /* max cmd length */
+ host->max_cmd_len = STORVSC_MAX_CMD_LEN;
/* Register the HBA and start the scsi bus scan */
ret = scsi_add_host(host, &device->device);
--
1.7.1
next reply other threads:[~2011-09-01 21:11 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-01 21:11 Mike Sterling [this message]
2011-09-01 20:59 ` [PATCH 1/1] staging: hv: Add support for >2 TB LUN in storage driver Greg KH
-- strict thread matches above, loose matches on Subject: below --
2011-09-01 22:11 Mike Sterling
2011-09-01 22:22 ` Greg KH
2011-09-06 15:33 ` Mike Sterling
2011-09-06 19:06 ` Greg KH
2011-09-06 19:14 ` Mike Sterling
2011-09-06 23:10 [PATCH 1/1] Staging: " Mike Sterling
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=1314911512-1079-1-git-send-email-mike.sterling@microsoft.com \
--to=steelforce@gmail.com \
--cc=devel@linuxdriverproject.org \
--cc=gregkh@suse.de \
--cc=haiyangz@microsoft.com \
--cc=kys@microsoft.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mike.sterling@microsoft.com \
--cc=virtualization@lists.osdl.org \
/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).