]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: repurpose the last argument from print_opcode_name()
authorHannes Reinecke <hare@suse.de>
Fri, 24 Oct 2014 12:26:57 +0000 (14:26 +0200)
committerChristoph Hellwig <hch@lst.de>
Wed, 12 Nov 2014 10:16:03 +0000 (11:16 +0100)
commitcca68ae9bcff13616c2eb6c362e1b1ae890aa58b
treeb6f3e5f7ed4879e19fb898774dcd2db8e6e3c43c
parent0e9c3eaafb28ebe12e1fd9c5d5aa6e7a113288c4
scsi: repurpose the last argument from print_opcode_name()

print_opcode_name() was only ever called with a '0' argument
from LLDDs and ULDs which were _not_ supporting variable length
CDBs, so the 'if' clause was never triggered.
Instead we should be using the last argument to specify
the cdb length to avoid accidental overflow when reading
the cdb buffer.

Signed-off-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Robert Elliott <elliott@hp.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
drivers/scsi/arm/fas216.c
drivers/scsi/ch.c
drivers/scsi/constants.c
drivers/scsi/sr_ioctl.c
include/scsi/scsi_dbg.h