Skip to content

Commit

Permalink
scsi: storvsc: Retrieve information about the capability of the target
Browse files Browse the repository at this point in the history
The storage protocol informs the guest of the I/O capabilities of the storage
stack. Retrieve this information and use it in the guest.

Signed-off-by: K. Y. Srinivasan <[email protected]>
Reviewed-by: Long Li <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
  • Loading branch information
kattisrinivasan authored and James Bottomley committed Apr 9, 2015
1 parent 0147dab commit 5117b93
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions drivers/scsi/storvsc_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,10 @@ struct storvsc_device {
unsigned char path_id;
unsigned char target_id;

/*
* Max I/O, the device can support.
*/
u32 max_transfer_bytes;
/* Used for vsc/vsp channel reset process */
struct storvsc_cmd_request init_request;
struct storvsc_cmd_request reset_request;
Expand Down Expand Up @@ -974,6 +978,8 @@ static int storvsc_channel_init(struct hv_device *device)
STORAGE_CHANNEL_SUPPORTS_MULTI_CHANNEL)
process_sub_channels = true;
}
stor_device->max_transfer_bytes =
vstor_packet->storage_channel_properties.max_transfer_bytes;

memset(vstor_packet, 0, sizeof(struct vstor_packet));
vstor_packet->operation = VSTOR_OPERATION_END_INITIALIZATION;
Expand Down

0 comments on commit 5117b93

Please sign in to comment.