[SCSI] Add a report opcode helper
The REPORT SUPPORTED OPERATION CODES command can be used to query whether a given opcode is supported by a device. Add a helper function that allows us to look up commands. We only issue RSOC if the device reports compliance with SPC-3 or later. But to err on the side of caution we disable the command for ATA, FireWire and USB. Signed-off-by:Martin K. Petersen <martin.petersen@oracle.com> Acked-by:
Mike Snitzer <snitzer@redhat.com> Signed-off-by:
James Bottomley <JBottomley@Parallels.com>
Showing
- drivers/ata/libata-scsi.c 1 addition, 0 deletionsdrivers/ata/libata-scsi.c
- drivers/firewire/sbp2.c 1 addition, 0 deletionsdrivers/firewire/sbp2.c
- drivers/scsi/scsi.c 45 additions, 0 deletionsdrivers/scsi/scsi.c
- drivers/usb/storage/scsiglue.c 3 additions, 0 deletionsdrivers/usb/storage/scsiglue.c
- include/scsi/scsi_device.h 3 additions, 0 deletionsinclude/scsi/scsi_device.h
Loading
Please register or sign in to comment