]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.14-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 9 Feb 2018 13:37:01 +0000 (14:37 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 9 Feb 2018 13:37:01 +0000 (14:37 +0100)
added patches:
scsi-storvsc-missing-error-code-in-storvsc_probe.patch

queue-4.14/scsi-storvsc-missing-error-code-in-storvsc_probe.patch [new file with mode: 0644]
queue-4.14/series

diff --git a/queue-4.14/scsi-storvsc-missing-error-code-in-storvsc_probe.patch b/queue-4.14/scsi-storvsc-missing-error-code-in-storvsc_probe.patch
new file mode 100644 (file)
index 0000000..838c36a
--- /dev/null
@@ -0,0 +1,38 @@
+From ca8dc694045e9aa248e9916e0f614deb0494cb3d Mon Sep 17 00:00:00 2001
+From: Dan Carpenter <dan.carpenter@oracle.com>
+Date: Tue, 16 Jan 2018 13:40:22 +0300
+Subject: scsi: storvsc: missing error code in storvsc_probe()
+
+From: Dan Carpenter <dan.carpenter@oracle.com>
+
+commit ca8dc694045e9aa248e9916e0f614deb0494cb3d upstream.
+
+We should set the error code if fc_remote_port_add() fails.
+
+Cc: <stable@vger.kernel.org> #v4.12+
+Fixes: daf0cd445a21 ("scsi: storvsc: Add support for FC rport.")
+Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
+Reviewed-by: Cathy Avery <cavery@redhat.com>
+Acked-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+Signed-off-by: Long Li <longli@microsoft.com>
+
+---
+ drivers/scsi/storvsc_drv.c |    4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/drivers/scsi/storvsc_drv.c
++++ b/drivers/scsi/storvsc_drv.c
+@@ -1826,8 +1826,10 @@ static int storvsc_probe(struct hv_devic
+               fc_host_node_name(host) = stor_device->node_name;
+               fc_host_port_name(host) = stor_device->port_name;
+               stor_device->rport = fc_remote_port_add(host, 0, &ids);
+-              if (!stor_device->rport)
++              if (!stor_device->rport) {
++                      ret = -ENOMEM;
+                       goto err_out3;
++              }
+       }
+ #endif
+       return 0;
index 05ed5ac410cc90dc553e167dc57ddbcc923efb9b..a02c5cdc26c93be81936a92d9ad16517551d43f2 100644 (file)
@@ -19,3 +19,4 @@ media-soc_camera-soc_scale_crop-add-missing-module_description-author-license.pa
 crypto-tcrypt-fix-s-g-table-for-test_aead_speed.patch
 arch-define-weak-abort.patch
 kernel-exit.c-export-abort-to-modules.patch
+scsi-storvsc-missing-error-code-in-storvsc_probe.patch