Commit 3ac0ad83 authored by Andrey Vagin's avatar Andrey Vagin Committed by Pavel Emelyanov

locks: add futex_wait_while_eq

 Wait while futex @f value is equal to @v
Signed-off-by: 's avatarAndrey Vagin <avagin@openvz.org>
Signed-off-by: 's avatarPavel Emelyanov <xemul@parallels.com>
parent 001be2ab
...@@ -95,6 +95,10 @@ static inline void futex_wait_while_gt(futex_t *f, u32 v) ...@@ -95,6 +95,10 @@ static inline void futex_wait_while_gt(futex_t *f, u32 v)
static inline void futex_wait_while_lt(futex_t *f, u32 v) static inline void futex_wait_while_lt(futex_t *f, u32 v)
{ futex_wait_if_cond(f, v, >=); } { futex_wait_if_cond(f, v, >=); }
/* Wait while futex @f value is equal to @v */
static inline void futex_wait_while_eq(futex_t *f, u32 v)
{ futex_wait_if_cond(f, v, !=); }
/* Wait while futex @f value is @v */ /* Wait while futex @f value is @v */
static inline void futex_wait_while(futex_t *f, u32 v) static inline void futex_wait_while(futex_t *f, u32 v)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment