Enabled the LUN check for ATAPI MO, ZIP, and CD-ROM drives.
This commit is contained in:
@@ -1182,12 +1182,10 @@ zip_pre_execution_check(zip_t *dev, uint8_t *cdb)
|
||||
{
|
||||
int ready = 0;
|
||||
|
||||
if (dev->drv->bus_type == ZIP_BUS_SCSI) {
|
||||
if ((cdb[0] != GPCMD_REQUEST_SENSE) && (dev->cur_lun == SCSI_LUN_USE_CDB) && (cdb[1] & 0xe0)) {
|
||||
zip_log("ZIP %i: Attempting to execute a unknown command targeted at SCSI LUN %i\n", dev->id, ((dev->request_length >> 5) & 7));
|
||||
zip_invalid_lun(dev);
|
||||
return 0;
|
||||
}
|
||||
if ((cdb[0] != GPCMD_REQUEST_SENSE) && (dev->cur_lun == SCSI_LUN_USE_CDB) && (cdb[1] & 0xe0)) {
|
||||
zip_log("ZIP %i: Attempting to execute a unknown command targeted at SCSI LUN %i\n", dev->id, ((dev->request_length >> 5) & 7));
|
||||
zip_invalid_lun(dev);
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (!(zip_command_flags[cdb[0]] & IMPLEMENTED)) {
|
||||
|
||||
Reference in New Issue
Block a user