When we are in panic, always go the asynchronous path in g_mirror_destroy(),

otherwise the system will hang.

This is a temporarily least intrusive crutch to get certain panicing systems
dumping. The proper fix should question is g_mirror_destroy() should be called
on a panicing system at all.

Discussed with:	mav
This commit is contained in:
Gleb Smirnoff 2016-06-01 22:11:54 +00:00
parent 12017ca883
commit a7c5163b5f
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=301173

View File

@ -2989,7 +2989,8 @@ g_mirror_destroy(struct g_mirror_softc *sc, int how)
sx_assert(&sc->sc_lock, SX_XLOCKED);
pp = sc->sc_provider;
if (pp != NULL && (pp->acr != 0 || pp->acw != 0 || pp->ace != 0)) {
if (pp != NULL && (pp->acr != 0 || pp->acw != 0 || pp->ace != 0 ||
SCHEDULER_STOPPED())) {
switch (how) {
case G_MIRROR_DESTROY_SOFT:
G_MIRROR_DEBUG(1,