critical_{enter, exit}: add missing compiler barrier
Reported by: markj
This commit is contained in:
parent
952dd10db4
commit
3843df3fdc
@ -238,6 +238,7 @@ critical_enter(void)
|
||||
|
||||
td = (struct thread_lite *)curthread;
|
||||
td->td_critnest++;
|
||||
__compiler_membar();
|
||||
}
|
||||
|
||||
static __inline void
|
||||
@ -248,6 +249,7 @@ critical_exit(void)
|
||||
td = (struct thread_lite *)curthread;
|
||||
KASSERT(td->td_critnest != 0,
|
||||
("critical_exit: td_critnest == 0"));
|
||||
__compiler_membar();
|
||||
td->td_critnest--;
|
||||
__compiler_membar();
|
||||
if (__predict_false(td->td_owepreempt))
|
||||
|
Loading…
x
Reference in New Issue
Block a user