Damien, > Releasing a zone write lock only when the write commnand that acquired > the lock completes can cause deadlocks due to potential command > reordering if the lock owning request is requeued and not > executed. This problem exists only with the scsi-mq path as, unlike > the legacy path, requests are moved out of the dispatch queue before > being prepared and so before locking a zone for a write command. > > Since sd_uninit_cmnd() is now always called when a request is > requeued, call sd_zbc_write_unlock_zone() from that function for write > requests that acquired a zone lock instead of from > sd_done(). Acquisition of a zone lock by a write command is indicated > using the new command flag SCMD_ZONE_WRITE_LOCK. Applied to 4.13/scsi-fixes. Thanks! -- Martin K. Petersen Oracle Linux Engineering