mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
In ntoskrnl_unlock_dpc(), use atomic_store instead of atomic_cmpset
to give up the spinlock. Suggested by: bde
This commit is contained in:
parent
cd4db58afd
commit
e1c0113ffd
1 changed files with 2 additions and 2 deletions
|
|
@ -1029,7 +1029,7 @@ ntoskrnl_lock_dpc(/*lock*/ void)
|
|||
__asm__ __volatile__ ("" : "=c" (lock));
|
||||
|
||||
while (atomic_cmpset_acq_int((volatile u_int *)lock, 0, 1) == 0)
|
||||
/* do nothing */;
|
||||
/* sit and spin */;
|
||||
|
||||
return;
|
||||
}
|
||||
|
|
@ -1041,7 +1041,7 @@ ntoskrnl_unlock_dpc(/*lock*/ void)
|
|||
|
||||
__asm__ __volatile__ ("" : "=c" (lock));
|
||||
|
||||
atomic_cmpset_rel_int((volatile u_int *)lock, 1, 0);
|
||||
atomic_store_rel_int((volatile u_int *)lock, 0);
|
||||
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue