scsi: core: Move command size detection out of the fast path
authorChristoph Hellwig <hch@lst.de>
Mon, 5 Oct 2020 08:41:23 +0000 (10:41 +0200)
committerMartin K. Petersen <martin.petersen@oracle.com>
Thu, 8 Oct 2020 01:48:27 +0000 (21:48 -0400)
commit2ceda20f0a99a74a82b78870f3b3e5fa93087a7f
tree9b77440cfe789b877ce34a791119b1192e6bbaaa
parent3a8dc5bbc8c04db2646ed0842118b0f66659a3db
scsi: core: Move command size detection out of the fast path

We only need to detect the command size for ioctl request from userspace,
which is limited to the passthrough path.  Move the check there instead of
doing it for all queuecommand invocations.

Link: https://lore.kernel.org/r/20201005084130.143273-4-hch@lst.de
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/scsi_lib.c