1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-04 12:52:15 +00:00

Do not wait for HA thread shutdown if scheduler is stopped.

This wait loop made system hang on panic instead of reboot.

MFC after:	1 week
This commit is contained in:
Alexander Motin 2017-01-10 20:16:16 +00:00
parent 759e131362
commit 4982dca18d
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=311892

View File

@ -1001,7 +1001,7 @@ ctl_ha_msg_shutdown(struct ctl_softc *ctl_softc)
softc->ha_shutdown = 1;
softc->ha_wakeup = 1;
wakeup(&softc->ha_wakeup);
while (softc->ha_shutdown < 2) {
while (softc->ha_shutdown < 2 && !SCHEDULER_STOPPED()) {
msleep(&softc->ha_wakeup, &softc->ha_lock, 0,
"shutdown", hz);
}