Just assert that the lock is held here, rather than taking it out and

dropping it.

Sponsored by: Netflix
This commit is contained in:
Warner Losh 2018-04-13 16:45:35 +00:00
parent 56c989dff2
commit c67f3c609b
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=332476

View File

@ -4652,9 +4652,8 @@ dadone(struct cam_periph *periph, union ccb *done_ccb)
(error_code == SSD_CURRENT_ERROR ||
error_code == SSD_DESC_CURRENT_ERROR) &&
(sense_key == SSD_KEY_ILLEGAL_REQUEST)))) {
cam_periph_lock(periph);
cam_periph_assert(periph, MA_OWNED);
softc->flags &= ~DA_FLAG_CAN_RC16;
cam_periph_unlock(periph);
free(rdcap, M_SCSIDA);
xpt_release_ccb(done_ccb);
softc->state = DA_STATE_PROBE_RC;