summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@s-opensource.com>2017-05-16 09:23:05 -0400
committerJonathan Corbet <corbet@lwn.net>2017-07-14 15:57:59 -0400
commit5da98b8230fb998b0731b2ba3893461ff238a297 (patch)
tree3ed2748067826eecde3bec1e167f63277919132f
parent5426a2cc70be499ea3bc67985c0608c7ac62fe6c (diff)
pi-futex.txt: standardize document format
Each text file under Documentation follows a different format. Some doesn't even have titles! Change its representation to follow the adopted standard, using ReST markups for it to be parseable by Sphinx. This document requires just minor adjustments to match the standard documentation style: - promote document name; - remove extra collons on some chapter titles; - use "-" for a bulleted list. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net>
-rw-r--r--Documentation/pi-futex.txt15
1 files changed, 8 insertions, 7 deletions
diff --git a/Documentation/pi-futex.txt b/Documentation/pi-futex.txt
index 9a5bc8651c29..aafddbee7377 100644
--- a/Documentation/pi-futex.txt
+++ b/Documentation/pi-futex.txt
@@ -1,5 +1,6 @@
1======================
1Lightweight PI-futexes 2Lightweight PI-futexes
2---------------------- 3======================
3 4
4We are calling them lightweight for 3 reasons: 5We are calling them lightweight for 3 reasons:
5 6
@@ -25,8 +26,8 @@ determinism and well-bound latencies. Even in the worst-case, PI will
25improve the statistical distribution of locking related application 26improve the statistical distribution of locking related application
26delays. 27delays.
27 28
28The longer reply: 29The longer reply
29----------------- 30----------------
30 31
31Firstly, sharing locks between multiple tasks is a common programming 32Firstly, sharing locks between multiple tasks is a common programming
32technique that often cannot be replaced with lockless algorithms. As we 33technique that often cannot be replaced with lockless algorithms. As we
@@ -71,8 +72,8 @@ deterministic execution of the high-prio task: any medium-priority task
71could preempt the low-prio task while it holds the shared lock and 72could preempt the low-prio task while it holds the shared lock and
72executes the critical section, and could delay it indefinitely. 73executes the critical section, and could delay it indefinitely.
73 74
74Implementation: 75Implementation
75--------------- 76--------------
76 77
77As mentioned before, the userspace fastpath of PI-enabled pthread 78As mentioned before, the userspace fastpath of PI-enabled pthread
78mutexes involves no kernel work at all - they behave quite similarly to 79mutexes involves no kernel work at all - they behave quite similarly to
@@ -83,8 +84,8 @@ entering the kernel.
83 84
84To handle the slowpath, we have added two new futex ops: 85To handle the slowpath, we have added two new futex ops:
85 86
86 FUTEX_LOCK_PI 87 - FUTEX_LOCK_PI
87 FUTEX_UNLOCK_PI 88 - FUTEX_UNLOCK_PI
88 89
89If the lock-acquire fastpath fails, [i.e. an atomic transition from 0 to 90If the lock-acquire fastpath fails, [i.e. an atomic transition from 0 to
90TID fails], then FUTEX_LOCK_PI is called. The kernel does all the 91TID fails], then FUTEX_LOCK_PI is called. The kernel does all the