mirror of
https://github.com/Mathewnd/Astral.git
synced 2026-11-01 23:18:21 +00:00
kernel: guard pushlock assertions with DEBUG_LOCKS
This commit is contained in:
@@ -141,8 +141,10 @@ static void pushlock_update_waiters(pushlock_t *pushlock, pushlock_t state) {
|
|||||||
|
|
||||||
for (;;) {
|
for (;;) {
|
||||||
pushlock_assert_state(state);
|
pushlock_assert_state(state);
|
||||||
|
#ifdef DEBUG_LOCKS
|
||||||
__assert(state & PUSHLOCK_FLAGS_CONTENDED);
|
__assert(state & PUSHLOCK_FLAGS_CONTENDED);
|
||||||
__assert(state & PUSHLOCK_FLAGS_WAKING);
|
__assert(state & PUSHLOCK_FLAGS_WAKING);
|
||||||
|
#endif
|
||||||
|
|
||||||
head = PUSHLOCK_GET_POINTER(state);
|
head = PUSHLOCK_GET_POINTER(state);
|
||||||
oldest = pushlock_complete_waiter_links(head);
|
oldest = pushlock_complete_waiter_links(head);
|
||||||
|
|||||||
Reference in New Issue
Block a user