Changeset 497bd656 in mainline
- Timestamp:
- 2012-11-16T14:49:21Z (12 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 9fe9d296
- Parents:
- 4f5e1c7c
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/synch/condvar.c
r4f5e1c7c r497bd656 91 91 92 92 ipl = waitq_sleep_prepare(&cv->wq); 93 /* Unlock only after the waitq is locked so we don't miss a wakeup. */ 93 94 mutex_unlock(mtx); 94 95 … … 96 97 rc = waitq_sleep_timeout_unsafe(&cv->wq, usec, flags); 97 98 99 waitq_sleep_finish(&cv->wq, rc, ipl); 100 /* Lock only after releasing the waitq to avoid a possible deadlock. */ 98 101 mutex_lock(mtx); 99 waitq_sleep_finish(&cv->wq, rc, ipl);100 102 101 103 return rc; … … 128 130 ipl = waitq_sleep_prepare(&cv->wq); 129 131 132 /* Unlock only after the waitq is locked so we don't miss a wakeup. */ 130 133 spinlock_unlock(lock); 131 134 … … 134 137 135 138 waitq_sleep_finish(&cv->wq, rc, ipl); 136 139 /* Lock only after releasing the waitq to avoid a possible deadlock. */ 137 140 spinlock_lock(lock); 138 141
Note:
See TracChangeset
for help on using the changeset viewer.