Be more conservative in using READ CAPACITY(16) command. Previous code
checked PROTECT bit in INQUIRY data for all SPC devices, while it is defined only since SPC-3. But there are some SPC-2 USB devices were reported, that have PROTECT bit set, return no error for READ CAPACITY(16) command, but return wrong sector count value in response. MFC after: 3 days
This commit is contained in:
parent
03c053c63d
commit
4409a9b5ec
@ -1631,9 +1631,7 @@ daregister(struct cam_periph *periph, void *arg)
|
||||
softc->minimum_cmd_size = 16;
|
||||
|
||||
/* Predict whether device may support READ CAPACITY(16). */
|
||||
if (SID_ANSI_REV(&cgd->inq_data) >= SCSI_REV_SPC3 ||
|
||||
(SID_ANSI_REV(&cgd->inq_data) >= SCSI_REV_SPC &&
|
||||
(cgd->inq_data.spc3_flags & SPC3_SID_PROTECT))) {
|
||||
if (SID_ANSI_REV(&cgd->inq_data) >= SCSI_REV_SPC3) {
|
||||
softc->flags |= DA_FLAG_CAN_RC16;
|
||||
softc->state = DA_STATE_PROBE2;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user