public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Document the fact that RCU callbacks can run in parallel
@ 2007-06-07 16:05 Paul E. McKenney
  0 siblings, 0 replies; only message in thread
From: Paul E. McKenney @ 2007-06-07 16:05 UTC (permalink / raw)
  To: linux-kernel; +Cc: rostedt, akpm, dipankar

Add an item to the RCU documentation checklist noting that RCU callbacks
can run in parallel.

Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
---

 checklist.txt |   10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff -urpNa -X dontdiff linux-2.6.21/Documentation/RCU/checklist.txt linux-2.6.21-RCUdoc/Documentation/RCU/checklist.txt
--- linux-2.6.21/Documentation/RCU/checklist.txt	2007-04-25 20:08:32.000000000 -0700
+++ linux-2.6.21-RCUdoc/Documentation/RCU/checklist.txt	2007-06-07 08:58:52.000000000 -0700
@@ -222,7 +222,15 @@ over a rather long period of time, but i
 	deadlock as soon as the RCU callback happens to interrupt that
 	acquisition's critical section.
 
-13.	SRCU (srcu_read_lock(), srcu_read_unlock(), and synchronize_srcu())
+13.	RCU callbacks can be and are executed in parallel.  In many cases,
+	the callback code simply wrappers around kfree(), so that this
+	is not an issue (or, more accurately, to the extent that it is
+	an issue, the memory-allocator locking handles it).  However,
+	if the callbacks do manipulate a shared data structure, they
+	must use whatever locking or other synchronization is required
+	to safely access and/or modify that data structure.
+
+14.	SRCU (srcu_read_lock(), srcu_read_unlock(), and synchronize_srcu())
 	may only be invoked from process context.  Unlike other forms of
 	RCU, it -is- permissible to block in an SRCU read-side critical
 	section (demarked by srcu_read_lock() and srcu_read_unlock()),

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-06-07 16:06 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-07 16:05 [PATCH] Document the fact that RCU callbacks can run in parallel Paul E. McKenney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox