FUTEX_REQUEUE − wake some waiters, and requeue others
Standard C library (libc, −lc)
#include
<linux/futex.h> /* Definition of FUTEX_*
constants */
#include <sys/syscall.h> /* Definition of
SYS_* constants */
#include <unistd.h>
long
syscall(SYS_futex, uint32_t *uaddr,
FUTEX_REQUEUE,
uint32_t val, uint32_t val2,
uint32_t *uaddr2);
This operation performs the same task as FUTEX_CMP_REQUEUE(2const), except that the futex word isn’t compared.
On error, −1 is returned, and errno is set to indicate the error.
On success, FUTEX_REQUEUE returns the number of waiters that were woken up.
See futex(2).
|
EFAULT |
uaddr2 did not point to a valid user-space address. | ||
|
EINVAL |
uaddr2 does not point to a valid object—that is, the address is not four-byte-aligned. | ||
|
EINVAL |
The kernel detected an inconsistency between the user-space state at uaddr and the kernel state—that is, it detected a waiter which waits in FUTEX_LOCK_PI(2const) or FUTEX_LOCK_PI2(2const) on uaddr. |
Linux.
Linux 2.6.0.
futex(2)