diff options
| author | Thomas Gleixner <tglx@linutronix.de> | 2015-01-14 09:11:16 +0100 |
|---|---|---|
| committer | Michael Kerrisk <mtk.manpages@gmail.com> | 2015-12-15 14:39:42 +0100 |
| commit | e0547e70aee125c97c6a9729d57375594fa1402c (patch) | |
| tree | 1b3b241b9d3e24f79d523bd84b5c3fa25f968980 /man2/futex.2 | |
| parent | dcdfde2633442ed55f99e39cd277b80684445605 (diff) | |
| download | man-pages-e0547e70aee125c97c6a9729d57375594fa1402c.tar.gz | |
futex.2: Document FUTEX_LOCK_PI
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Diffstat (limited to 'man2/futex.2')
| -rw-r--r-- | man2/futex.2 | 33 |
1 files changed, 31 insertions, 2 deletions
diff --git a/man2/futex.2 b/man2/futex.2 index bdb28e7678..7b4a9a0a80 100644 --- a/man2/futex.2 +++ b/man2/futex.2 @@ -632,12 +632,41 @@ arguments are ignored. .TP .BR FUTEX_LOCK_PI " (since Linux 2.6.18)" .\" commit c87e2837be82df479a6bae9f155c43516d2feebc -.\" FIXME to complete .\" .\" FIXME Employs 'timeout' argument, with absolute time value on .\" CLOCK_REALTIME clock; 'timeout' can be NULL .\" -[As yet undocumented] +This operation reads from the futex address provided by the +.I uaddr +argument, which contains the namespace-specific thread ID (TID) +of the lock owner. +If the TID is 0, then the kernel tries to set the waiter's TID atomically. +If the TID is nonzero or the take over fails, +the kernel sets atomically the +.B FUTEX_WAITERS +bit, which signals the owner that it cannot unlock the futex in +user space atomically by transitioning from TID to 0. +After that, the kernel tries to find the task which is +associated with the owner TID, creates or reuses kernel state on behalf +of the owner and attaches the waiter to it. +The enqueing of the waiter is in descending priority order if more +than one waiter exists. +The owner inherits either the priority or the bandwidth of the waiter. +This inheritance follows the lock chain in the case of +nested locking and performs deadlock detection. + +The +.I timeout +.\" FIXME Is this true?????????????????????? +argument is handled as described in +.BR FUTEX_WAIT . + +The arguments +.IR uaddr2 , +.IR val , +and +.IR val3 +are ignored. .TP .BR FUTEX_UNLOCK_PI " (since Linux 2.6.18)" .\" commit c87e2837be82df479a6bae9f155c43516d2feebc |
