]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: core: Do not truncate INQUIRY data on modern devices
authorMartin K. Petersen <martin.petersen@oracle.com>
Wed, 2 Mar 2022 05:35:48 +0000 (00:35 -0500)
committerMartin K. Petersen <martin.petersen@oracle.com>
Mon, 2 May 2022 20:59:11 +0000 (16:59 -0400)
commit5d3e5ab378c873bca8ee354ced778d00982c6e6c
treeac3f1a1ec2a1c600f1394c9819cc136eab9eeeb9
parent8cd15936cae9c80e3437aca04e88a393e54929f6
scsi: core: Do not truncate INQUIRY data on modern devices

Low-level device drivers have had the ability to limit the size of an
INQUIRY for many years. This made sense for a wide variety of legacy
devices. However, we are unnecessarily truncating the INQUIRY response for
many modern devices. This prevents us from consulting fields beyond the
first 36 bytes.

If a device reports that it supports a larger INQUIRY response, and the
device also reports that it implements SPC-4 or newer, allow the larger
INQUIRY to proceed.

Link: https://lore.kernel.org/r/20220302053559.32147-4-martin.petersen@oracle.com
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/scsi_scan.c