diff options
author | Christoph Hellwig <hch@lst.de> | 2014-11-03 14:09:02 +0100 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2014-11-12 11:19:43 +0100 |
commit | 2ecb204d07ac8debe3893c362415919bc78bebd6 (patch) | |
tree | eef99b324201b21de358dffdab8bfc0453358d5f /drivers/usb/storage | |
parent | e2eddf4d530df745019fded0fedfb78f6d3e33ca (diff) |
scsi: always assign block layer tags if enabled
Allow a driver to ask for block layer tags by setting .use_blk_tags in the
host template, in which case it will always see a valid value in
request->tag, similar to the behavior when using blk-mq. This means even
SCSI "untagged" commands will now have a tag, which is especially useful
when using a host-wide tag map.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Mike Christie <michaelc@cs.wisc.edu>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Diffstat (limited to 'drivers/usb/storage')
-rw-r--r-- | drivers/usb/storage/uas.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/storage/uas.c b/drivers/usb/storage/uas.c index 1bc5df4200a..ee69b82fc7d 100644 --- a/drivers/usb/storage/uas.c +++ b/drivers/usb/storage/uas.c @@ -799,8 +799,7 @@ static int uas_slave_configure(struct scsi_device *sdev) if (devinfo->flags & US_FL_NO_REPORT_OPCODES) sdev->no_report_opcodes = 1; - scsi_set_tag_type(sdev, MSG_ORDERED_TAG); - scsi_activate_tcq(sdev, devinfo->qdepth - 2); + scsi_adjust_queue_depth(sdev, MSG_ORDERED_TAG, devinfo->qdepth - 2); return 0; } @@ -824,6 +823,7 @@ static struct scsi_host_template uas_host_template = { * allocator. */ .disable_blk_mq = true, + .use_blk_tags = 1, }; #define UNUSUAL_DEV(id_vendor, id_product, bcdDeviceMin, bcdDeviceMax, \ |