Don't recursively panic when we call mi_switch() in a critical section,
even though calling mi_switch() after a panic is likely a bug anyway as the recursive panic only serves to make things worse.
This commit is contained in:
parent
ad942ef63f
commit
b80ed61487
@ -287,7 +287,7 @@ mi_switch(int flags, struct thread *newtd)
|
||||
#endif
|
||||
KASSERT(td->td_critnest == 1 || (td->td_critnest == 2 &&
|
||||
(td->td_pflags & TDP_OWEPREEMPT) != 0 && (flags & SW_INVOL) != 0 &&
|
||||
newtd == NULL),
|
||||
newtd == NULL) || panicstr,
|
||||
("mi_switch: switch in a critical section"));
|
||||
KASSERT((flags & (SW_INVOL | SW_VOL)) != 0,
|
||||
("mi_switch: switch must be voluntary or involuntary"));
|
||||
|
Loading…
Reference in New Issue
Block a user