diff options
author | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2015-10-07 18:52:25 -0400 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2015-12-05 15:33:26 -0500 |
commit | a4b575627e8d1a2498a921940813266d4e26ff56 (patch) | |
tree | 297bf78c5c5c4ca2bc7530ef6f2a5a2fca7359dd /Documentation/RCU | |
parent | 0825458b1dbc39ec6840ee2e45b1fedb1b4b4ca1 (diff) |
documentation: Expand on scheduler/RCU deadlock requirements
This commit adds a second option for avoiding scheduler/RCU deadlocks,
namely that preemption be disabled across the entire RCU read-side
critical section in question.
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Diffstat (limited to 'Documentation/RCU')
-rw-r--r-- | Documentation/RCU/Design/Requirements/Requirements.html | 14 | ||||
-rw-r--r-- | Documentation/RCU/Design/Requirements/Requirements.htmlx | 14 |
2 files changed, 18 insertions, 10 deletions
diff --git a/Documentation/RCU/Design/Requirements/Requirements.html b/Documentation/RCU/Design/Requirements/Requirements.html index 105247149975..ab513ed229d7 100644 --- a/Documentation/RCU/Design/Requirements/Requirements.html +++ b/Documentation/RCU/Design/Requirements/Requirements.html | |||
@@ -1942,12 +1942,16 @@ RCU depends on the scheduler, and the scheduler uses RCU to | |||
1942 | protect some of its data structures. | 1942 | protect some of its data structures. |
1943 | This means the scheduler is forbidden from acquiring | 1943 | This means the scheduler is forbidden from acquiring |
1944 | the runqueue locks and the priority-inheritance locks | 1944 | the runqueue locks and the priority-inheritance locks |
1945 | in the middle of an outermost RCU read-side critical section unless | 1945 | in the middle of an outermost RCU read-side critical section unless either |
1946 | it also releases them before exiting that same | 1946 | (1) it releases them before exiting that same |
1947 | RCU read-side critical section. | 1947 | RCU read-side critical section, or |
1948 | This same prohibition also applies to any lock that is acquired | 1948 | (2) preemption is disabled across |
1949 | that entire RCU read-side critical section. | ||
1950 | This same prohibition also applies (recursively!) to any lock that is acquired | ||
1949 | while holding any lock to which this prohibition applies. | 1951 | while holding any lock to which this prohibition applies. |
1950 | Violating this rule results in deadlock. | 1952 | Adhering to this rule prevents preemptible RCU from invoking |
1953 | <tt>rcu_read_unlock_special()</tt> while either runqueue or | ||
1954 | priority-inheritance locks are held, thus avoiding deadlock. | ||
1951 | 1955 | ||
1952 | <p> | 1956 | <p> |
1953 | For RCU's part, the preemptible-RCU <tt>rcu_read_unlock()</tt> | 1957 | For RCU's part, the preemptible-RCU <tt>rcu_read_unlock()</tt> |
diff --git a/Documentation/RCU/Design/Requirements/Requirements.htmlx b/Documentation/RCU/Design/Requirements/Requirements.htmlx index 5b76e21fa092..f7c817f235e0 100644 --- a/Documentation/RCU/Design/Requirements/Requirements.htmlx +++ b/Documentation/RCU/Design/Requirements/Requirements.htmlx | |||
@@ -2109,12 +2109,16 @@ RCU depends on the scheduler, and the scheduler uses RCU to | |||
2109 | protect some of its data structures. | 2109 | protect some of its data structures. |
2110 | This means the scheduler is forbidden from acquiring | 2110 | This means the scheduler is forbidden from acquiring |
2111 | the runqueue locks and the priority-inheritance locks | 2111 | the runqueue locks and the priority-inheritance locks |
2112 | in the middle of an outermost RCU read-side critical section unless | 2112 | in the middle of an outermost RCU read-side critical section unless either |
2113 | it also releases them before exiting that same | 2113 | (1) it releases them before exiting that same |
2114 | RCU read-side critical section. | 2114 | RCU read-side critical section, or |
2115 | This same prohibition also applies to any lock that is acquired | 2115 | (2) preemption is disabled across |
2116 | that entire RCU read-side critical section. | ||
2117 | This same prohibition also applies (recursively!) to any lock that is acquired | ||
2116 | while holding any lock to which this prohibition applies. | 2118 | while holding any lock to which this prohibition applies. |
2117 | Violating this rule results in deadlock. | 2119 | Adhering to this rule prevents preemptible RCU from invoking |
2120 | <tt>rcu_read_unlock_special()</tt> while either runqueue or | ||
2121 | priority-inheritance locks are held, thus avoiding deadlock. | ||
2118 | 2122 | ||
2119 | <p> | 2123 | <p> |
2120 | For RCU's part, the preemptible-RCU <tt>rcu_read_unlock()</tt> | 2124 | For RCU's part, the preemptible-RCU <tt>rcu_read_unlock()</tt> |