diff options
author | Agustina Arzille <avarzille@riseup.net> | 2017-07-21 00:50:34 +0200 |
---|---|---|
committer | Richard Braun <rbraun@sceen.net> | 2017-07-21 00:50:43 +0200 |
commit | 5c2cf8fff7a1d6dc6b88615df5433ddccbbcf51f (patch) | |
tree | 4eb919999949d471204ca8489169351f1390ccb5 /kern/sleepq.h | |
parent | 4278f99adcbcfbd52904c0d8809184afe091c958 (diff) |
kern/mutex: new adaptive spinning mutex implementation
Diffstat (limited to 'kern/sleepq.h')
-rw-r--r-- | kern/sleepq.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/kern/sleepq.h b/kern/sleepq.h index e1f7863b..f55d8c4b 100644 --- a/kern/sleepq.h +++ b/kern/sleepq.h @@ -68,9 +68,15 @@ void sleepq_destroy(struct sleepq *sleepq); * * The condition argument must be true if the synchronization object * is a condition variable. + * + * Note that, in the case of the non-blocking variant, the call may also + * return NULL if internal state shared by unrelated synchronization + * objects is locked. */ struct sleepq * sleepq_acquire(const void *sync_obj, bool condition, unsigned long *flags); +struct sleepq * sleepq_tryacquire(const void *sync_obj, bool condition, + unsigned long *flags); void sleepq_release(struct sleepq *sleepq, unsigned long flags); /* |