Only take out the periph lock when we're modifying the flags of the
authorimp <imp@FreeBSD.org>
Sat, 17 Mar 2018 16:04:06 +0000 (16:04 +0000)
committerimp <imp@FreeBSD.org>
Sat, 17 Mar 2018 16:04:06 +0000 (16:04 +0000)
commitbf523f13ef5a3a6d06e76be0df100ac13b0d1d11
tree5d2a78e03750d1107d2dc203de9ebf5513a5ee50
parent22a89bf952dfa49408d341e0caa894d244462d65
Only take out the periph lock when we're modifying the flags of the
softc for an async unit attention. CAM locks, sometimes, the periph
lock and other times does not. We were taking the lock always and
running into lock recursion issues on a non-recursive lock. Now we
take it selectively. It's not clear why xpt takes the lock selectively
before calling us, though, and that's still under investigation.

Reported by: avg
PR: 226510 (same panic, differnt circumstances)
Sponsored by: Netflix
sys/cam/scsi/scsi_da.c