public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
To: Josh Triplett <josh@joshtriplett.org>
Cc: linux-kernel@vger.kernel.org, mingo@kernel.org,
	laijs@cn.fujitsu.com, dipankar@in.ibm.com,
	akpm@linux-foundation.org, mathieu.desnoyers@efficios.com,
	niv@us.ibm.com, tglx@linutronix.de, peterz@infradead.org,
	rostedt@goodmis.org, dhowells@redhat.com, edumazet@google.com,
	darren@dvhart.com, fweisbec@gmail.com, oleg@redhat.com,
	sbw@mit.edu
Subject: Re: [PATCH tip/core/rcu 1/6] documentation: Document call_rcu() safety mechanisms and limitations
Date: Mon, 17 Feb 2014 14:52:28 -0800	[thread overview]
Message-ID: <20140217225228.GL4250@linux.vnet.ibm.com> (raw)
In-Reply-To: <20140217213918.GA7941@thin>

On Mon, Feb 17, 2014 at 01:39:30PM -0800, Josh Triplett wrote:
> On Mon, Feb 17, 2014 at 01:26:48PM -0800, Paul E. McKenney wrote:
> > From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
> > 
> > The call_rcu() family of primitives will take action to accelerate
> > grace periods when the number of callbacks pending on a given CPU
> > becomes excessive.  Although this safety mechanism can be useful,
> > it is no substitute for users of call_rcu() having rate-limit controls
> > in place.  This commit adds this nuance to the documentation.
> > 
> > Reported-by: "Michael S. Tsirkin" <mst@redhat.com>
> > Reported-by: Gleb Natapov <gleb@redhat.com>
> > Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
> 
> Grammatical nit below; otherwise:
> Reviewed-by: Josh Triplett <josh@joshtriplett.org>
> 
> >  Documentation/RCU/checklist.txt | 19 ++++++++++++++-----
> >  1 file changed, 14 insertions(+), 5 deletions(-)
> > 
> > diff --git a/Documentation/RCU/checklist.txt b/Documentation/RCU/checklist.txt
> > index 91266193b8f4..5733e31836b5 100644
> > --- a/Documentation/RCU/checklist.txt
> > +++ b/Documentation/RCU/checklist.txt
> > @@ -256,10 +256,11 @@ over a rather long period of time, but improvements are always welcome!
> >  		variations on this theme.
> >  
> >  	b.	Limiting update rate.  For example, if updates occur only
> > -		once per hour, then no explicit rate limiting is required,
> > -		unless your system is already badly broken.  The dcache
> > -		subsystem takes this approach -- updates are guarded
> > -		by a global lock, limiting their rate.
> > +		once per hour, then no explicit rate limiting is
> > +		required, unless your system is already badly broken.
> > +		Older versions of the dcache subsystem takes this
> > +		approach -- updates were guarded by a global lock,
> > +		limiting their rate.
> 
> s/takes/take/ to match the change from the singular "The dcache
> subsystem" to the plural "Older versions of the dcache subsystem"
> 
> (You might also change " -- updates are guarded by" to ", guarding
> updates with".)

Took both suggested changes and applied your Reviewed-by.  Thank you!

							Thanx, Paul

> >  	c.	Trusted update -- if updates can only be done manually by
> >  		superuser or some other trusted user, then it might not
> > @@ -268,7 +269,8 @@ over a rather long period of time, but improvements are always welcome!
> >  		the machine.
> >  
> >  	d.	Use call_rcu_bh() rather than call_rcu(), in order to take
> > -		advantage of call_rcu_bh()'s faster grace periods.
> > +		advantage of call_rcu_bh()'s faster grace periods.  (This
> > +		is only a partial solution, though.)
> >  
> >  	e.	Periodically invoke synchronize_rcu(), permitting a limited
> >  		number of updates per grace period.
> > @@ -276,6 +278,13 @@ over a rather long period of time, but improvements are always welcome!
> >  	The same cautions apply to call_rcu_bh(), call_rcu_sched(),
> >  	call_srcu(), and kfree_rcu().
> >  
> > +	Note that although these primitives do take action to avoid memory
> > +	exhaustion when any given CPU has too many callbacks, a determined
> > +	user could still exhaust memory.  This is especially the case
> > +	if a system with a large number of CPUs has been configured to
> > +	offload all of its RCU callbacks onto a single CPU, or if the
> > +	system has relatively little free memory.
> > +
> >  9.	All RCU list-traversal primitives, which include
> >  	rcu_dereference(), list_for_each_entry_rcu(), and
> >  	list_for_each_safe_rcu(), must be either within an RCU read-side
> > -- 
> > 1.8.1.5
> > 
> 


  reply	other threads:[~2014-02-17 22:52 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-17 21:26 [PATCH tip/core/rcu 0/6] Documentation changes for 3.15 Paul E. McKenney
2014-02-17 21:26 ` [PATCH tip/core/rcu 1/6] documentation: Document call_rcu() safety mechanisms and limitations Paul E. McKenney
2014-02-17 21:26   ` [PATCH tip/core/rcu 2/6] Documentation/memory-barriers.txt: ACCESS_ONCE() provides cache coherence Paul E. McKenney
2014-02-17 21:40     ` Josh Triplett
2014-02-17 22:52       ` Paul E. McKenney
2014-02-17 21:26   ` [PATCH tip/core/rcu 3/6] Documentation/memory-barriers.txt: Conditional must use prior load Paul E. McKenney
2014-02-17 21:26   ` [PATCH tip/core/rcu 4/6] Documentation/kernel-per-CPU-kthreads.txt: Workqueue affinity Paul E. McKenney
2014-02-17 21:26   ` [PATCH tip/core/rcu 5/6] Documentation/memory-barriers.txt: Need barriers() for some control dependencies Paul E. McKenney
2014-02-17 21:46     ` Josh Triplett
2014-02-17 22:58       ` Paul E. McKenney
2014-02-18  0:02         ` Josh Triplett
2014-02-18  0:17           ` Paul E. McKenney
2014-02-18  0:45             ` Josh Triplett
2014-02-18  1:21               ` Paul E. McKenney
2014-02-18  3:29                 ` Josh Triplett
2014-02-18  4:57                   ` Paul E. McKenney
2014-02-17 21:26   ` [PATCH tip/core/rcu 6/6] documentation: Fix some inconsistencies in RTFP.txt Paul E. McKenney
2014-02-17 21:39   ` [PATCH tip/core/rcu 1/6] documentation: Document call_rcu() safety mechanisms and limitations Josh Triplett
2014-02-17 22:52     ` Paul E. McKenney [this message]
2014-02-17 21:47 ` [PATCH tip/core/rcu 0/6] Documentation changes for 3.15 Josh Triplett

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140217225228.GL4250@linux.vnet.ibm.com \
    --to=paulmck@linux.vnet.ibm.com \
    --cc=akpm@linux-foundation.org \
    --cc=darren@dvhart.com \
    --cc=dhowells@redhat.com \
    --cc=dipankar@in.ibm.com \
    --cc=edumazet@google.com \
    --cc=fweisbec@gmail.com \
    --cc=josh@joshtriplett.org \
    --cc=laijs@cn.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=mingo@kernel.org \
    --cc=niv@us.ibm.com \
    --cc=oleg@redhat.com \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=sbw@mit.edu \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox