Commit e6c4bc66 authored by Keith Mange's avatar Keith Mange Committed by James Bottomley

storvsc: use storage protocol version to determine storage capabilities

Use storage protocol version instead of vmbus protocol
version when determining storage capabilities.
Tested-by: default avatarAlex Ng <alexng@microsoft.com>
Signed-off-by: default avatarKeith Mange <keith.mange@microsoft.com>
Signed-off-by: default avatarK. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: default avatarJames Bottomley <JBottomley@Odin.com>
parent cb11fead
...@@ -1041,7 +1041,7 @@ static int storvsc_channel_init(struct hv_device *device) ...@@ -1041,7 +1041,7 @@ static int storvsc_channel_init(struct hv_device *device)
* support multi-channel. * support multi-channel.
*/ */
max_chns = vstor_packet->storage_channel_properties.max_channel_cnt; max_chns = vstor_packet->storage_channel_properties.max_channel_cnt;
if (vmbus_proto_version >= VERSION_WIN8) { if (vmstor_proto_version >= VMSTOR_PROTO_VERSION_WIN8) {
if (vstor_packet->storage_channel_properties.flags & if (vstor_packet->storage_channel_properties.flags &
STORAGE_CHANNEL_SUPPORTS_MULTI_CHANNEL) STORAGE_CHANNEL_SUPPORTS_MULTI_CHANNEL)
process_sub_channels = true; process_sub_channels = true;
...@@ -1483,9 +1483,9 @@ static int storvsc_device_configure(struct scsi_device *sdevice) ...@@ -1483,9 +1483,9 @@ static int storvsc_device_configure(struct scsi_device *sdevice)
* if the device is a MSFT virtual device. * if the device is a MSFT virtual device.
*/ */
if (!strncmp(sdevice->vendor, "Msft", 4)) { if (!strncmp(sdevice->vendor, "Msft", 4)) {
switch (vmbus_proto_version) { switch (vmstor_proto_version) {
case VERSION_WIN8: case VMSTOR_PROTO_VERSION_WIN8:
case VERSION_WIN8_1: case VMSTOR_PROTO_VERSION_WIN8_1:
sdevice->scsi_level = SCSI_SPC_3; sdevice->scsi_level = SCSI_SPC_3;
break; break;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment