diff options
author | Martin K. Petersen <martin.petersen@oracle.com> | 2022-03-02 08:35:49 +0300 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2022-05-02 23:59:10 +0300 |
commit | e17d63403076affccd72d195f93bbf3f39514005 (patch) | |
tree | faf3a163106234c3195c14bc354f0e58221ec692 /include/scsi | |
parent | c92a6b5d63359dd6d2ce6ea88ecd8e31dd769f6b (diff) | |
download | linux-e17d63403076affccd72d195f93bbf3f39514005.tar.xz |
scsi: core: Pick suitable allocation length in scsi_report_opcode()
Some devices hang when a buffer size larger than expected is passed in the
ALLOCATION LENGTH field. For REPORT SUPPORTED OPERATION CODES we currently
only request a single command descriptor at a time and therefore the actual
size of the command is known ahead of time. Limit the ALLOCATION LENGTH to
the header size plus the command length of the opcode we are asking about.
Link: https://lore.kernel.org/r/20220302053559.32147-5-martin.petersen@oracle.com
Reviewed-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'include/scsi')
0 files changed, 0 insertions, 0 deletions