MFp4:
If we panicked with SIM lock held, do not try to flush caches. Extra lock recursing will not make debugging easier.
This commit is contained in:
parent
4bc9493e7c
commit
21cc85878c
@ -1040,6 +1040,9 @@ adashutdown(void * arg, int howto)
|
||||
TAILQ_FOREACH(periph, &adadriver.units, unit_links) {
|
||||
union ccb ccb;
|
||||
|
||||
/* If we paniced with lock held - not recurse here. */
|
||||
if (cam_periph_owned(periph))
|
||||
continue;
|
||||
cam_periph_lock(periph);
|
||||
softc = (struct ada_softc *)periph->softc;
|
||||
/*
|
||||
|
@ -190,5 +190,11 @@ cam_periph_unlock(struct cam_periph *periph)
|
||||
mtx_unlock(periph->sim->mtx);
|
||||
}
|
||||
|
||||
static __inline int
|
||||
cam_periph_owned(struct cam_periph *periph)
|
||||
{
|
||||
return (mtx_owned(periph->sim->mtx));
|
||||
}
|
||||
|
||||
#endif /* _KERNEL */
|
||||
#endif /* _CAM_CAM_PERIPH_H */
|
||||
|
Loading…
Reference in New Issue
Block a user