projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c1ea2d0
)
USB: uas: Limit qdepth at the scsi-host level
author
Hans de Goede
<hdegoede@redhat.com>
Tue, 12 Apr 2016 10:27:08 +0000
(12:27 +0200)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Wed, 20 Apr 2016 06:42:07 +0000
(15:42 +0900)
commit
198de51dbc3454d95b015ca0a055b673f85f01bb
upstream.
Commit
64d513ac31bd
("scsi: use host wide tags by default") causes
the SCSI core to queue more commands then we can handle on devices with
multiple LUNs, limit the queue depth at the scsi-host level instead of
per slave to fix this.
BugLink:
https://bugzilla.redhat.com/show_bug.cgi?id=1315013
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/storage/uas.c
patch
|
blob
|
history
diff --git
a/drivers/usb/storage/uas.c
b/drivers/usb/storage/uas.c
index ce0cd6e20d4f2d2be68e519ff46bb67f9497147f..31872bcb0ad82c2e8615fcd8eb913d49781c7d9c 100644
(file)
--- a/
drivers/usb/storage/uas.c
+++ b/
drivers/usb/storage/uas.c
@@
-800,7
+800,6
@@
static int uas_slave_configure(struct scsi_device *sdev)
if (devinfo->flags & US_FL_BROKEN_FUA)
sdev->broken_fua = 1;
- scsi_change_queue_depth(sdev, devinfo->qdepth - 2);
return 0;
}
@@
-932,6
+931,12
@@
static int uas_probe(struct usb_interface *intf, const struct usb_device_id *id)
if (result)
goto set_alt0;
+ /*
+ * 1 tag is reserved for untagged commands +
+ * 1 tag to avoid off by one errors in some bridge firmwares
+ */
+ shost->can_queue = devinfo->qdepth - 2;
+
usb_set_intfdata(intf, shost);
result = scsi_add_host(shost, &intf->dev);
if (result)