Don't perform an mi_switch() when we release Giant during cpu_exit(). We
are about to call cpu_switch() anyways. Found by: witness
This commit is contained in:
parent
5f90cac7f1
commit
7e4b7c97de
@ -255,7 +255,8 @@ cpu_exit(p)
|
||||
|
||||
(void) splhigh();
|
||||
mtx_enter(&sched_lock, MTX_SPIN);
|
||||
mtx_exit(&Giant, MTX_DEF);
|
||||
mtx_exit(&Giant, MTX_DEF | MTX_NOSWITCH);
|
||||
mtx_assert(&Giant, MA_NOTOWNED);
|
||||
cnt.v_swtch++;
|
||||
cpu_switch();
|
||||
panic("cpu_exit");
|
||||
|
@ -304,7 +304,8 @@ cpu_exit(p)
|
||||
|
||||
(void) splhigh();
|
||||
mtx_enter(&sched_lock, MTX_SPIN);
|
||||
mtx_exit(&Giant, MTX_DEF);
|
||||
mtx_exit(&Giant, MTX_DEF | MTX_NOSWITCH);
|
||||
mtx_assert(&Giant, MA_NOTOWNED);
|
||||
cnt.v_swtch++;
|
||||
cpu_switch();
|
||||
panic("cpu_exit");
|
||||
|
@ -255,7 +255,8 @@ cpu_exit(p)
|
||||
|
||||
(void) splhigh();
|
||||
mtx_enter(&sched_lock, MTX_SPIN);
|
||||
mtx_exit(&Giant, MTX_DEF);
|
||||
mtx_exit(&Giant, MTX_DEF | MTX_NOSWITCH);
|
||||
mtx_assert(&Giant, MA_NOTOWNED);
|
||||
cnt.v_swtch++;
|
||||
cpu_switch();
|
||||
panic("cpu_exit");
|
||||
|
@ -255,7 +255,8 @@ cpu_exit(p)
|
||||
|
||||
(void) splhigh();
|
||||
mtx_enter(&sched_lock, MTX_SPIN);
|
||||
mtx_exit(&Giant, MTX_DEF);
|
||||
mtx_exit(&Giant, MTX_DEF | MTX_NOSWITCH);
|
||||
mtx_assert(&Giant, MA_NOTOWNED);
|
||||
cnt.v_swtch++;
|
||||
cpu_switch();
|
||||
panic("cpu_exit");
|
||||
|
Loading…
x
Reference in New Issue
Block a user