]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blame - releases/3.16.3/drivers-scsi-storvsc-correctly-handle-test_unit_ready-failure.patch
4.9-stable patches
[thirdparty/kernel/stable-queue.git] / releases / 3.16.3 / drivers-scsi-storvsc-correctly-handle-test_unit_ready-failure.patch
CommitLineData
033b5a72
GKH
1From 3533f8603d28b77c62d75ec899449a99bc6b77a1 Mon Sep 17 00:00:00 2001
2From: "K. Y. Srinivasan" <kys@microsoft.com>
3Date: Sat, 12 Jul 2014 09:48:32 -0700
4Subject: drivers: scsi: storvsc: Correctly handle TEST_UNIT_READY failure
5
6From: "K. Y. Srinivasan" <kys@microsoft.com>
7
8commit 3533f8603d28b77c62d75ec899449a99bc6b77a1 upstream.
9
10On some Windows hosts on FC SANs, TEST_UNIT_READY can return SRB_STATUS_ERROR.
11Correctly handle this. Note that there is sufficient sense information to
12support scsi error handling even in this case.
13
14Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
15Reviewed-by: Hannes Reinecke <hare@suse.de>
16Signed-off-by: Christoph Hellwig <hch@lst.de>
17Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
18
19---
20 drivers/scsi/storvsc_drv.c | 7 +++++++
21 1 file changed, 7 insertions(+)
22
23--- a/drivers/scsi/storvsc_drv.c
24+++ b/drivers/scsi/storvsc_drv.c
25@@ -1018,6 +1018,13 @@ static void storvsc_handle_error(struct
26 case ATA_12:
27 set_host_byte(scmnd, DID_PASSTHROUGH);
28 break;
29+ /*
30+ * On Some Windows hosts TEST_UNIT_READY command can return
31+ * SRB_STATUS_ERROR, let the upper level code deal with it
32+ * based on the sense information.
33+ */
34+ case TEST_UNIT_READY:
35+ break;
36 default:
37 set_host_byte(scmnd, DID_TARGET_FAILURE);
38 }