public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
To: Amit Shah <amit.shah@redhat.com>
Cc: Pranith Kumar <bobby.prani@gmail.com>,
	Josh Triplett <josh@joshtriplett.org>,
	Steven Rostedt <rostedt@goodmis.org>,
	Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
	Lai Jiangshan <laijs@cn.fujitsu.com>,
	"open list:READ-COPY UPDATE..." <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] rcu: Make nocb leader kthreads process pending callbacks after spawning
Date: Thu, 28 Aug 2014 05:58:41 -0700	[thread overview]
Message-ID: <20140828125841.GB4774@linux.vnet.ibm.com> (raw)
In-Reply-To: <20140828054649.GJ13052@grmbl.mre>

On Thu, Aug 28, 2014 at 11:16:49AM +0530, Amit Shah wrote:
> On (Wed) 27 Aug 2014 [16:43:40], Pranith Kumar wrote:
> > The nocb callbacks generated before the nocb kthreads are spawned are
> > enqueued in the nocb queue for later processing. Commit fbce7497ee5af ("rcu:
> > Parallelize and economize NOCB kthread wakeups") introduced nocb leader kthreads
> > which checked the nocb_leader_wake flag to see if there were any such pending
> > callbacks. A case was reported in which newly spawned leader kthreads were not
> > processing the pending callbacks as this flag was not set, which led to a boot
> > hang.
> > 
> > The following commit ensures that the newly spawned nocb kthreads process the
> > pending callbacks by allowing the kthreads to run immediately after spawning
> > instead of waiting. This is done by inverting the logic of nocb_leader_wake
> > tests to nocb_leader_sleep which allows us to use the default initialization of
> > this flag to 0 to let the kthreads run.
> > 
> > Reported-by: Amit Shah <amit.shah@redhat.com>
> > Signed-off-by: Pranith Kumar <bobby.prani@gmail.com>
> > Link: http://www.spinics.net/lists/kernel/msg1802899.html
> > ---
> >  kernel/rcu/tree.h        |  2 +-
> >  kernel/rcu/tree_plugin.h | 24 ++++++++++++------------
> >  2 files changed, 13 insertions(+), 13 deletions(-)
> 
> I'd have split this into two patches: one for the variable rename and
> one for fixing the bug.
> 
> However, the backport Paul posted does work fine for me on master, so
> you can add my
> 
> Tested-by: Amit Shah <amit.shah@redhat.com>

Thank you again, Amit, both for finding this problem and for your
testing efforts!

							Thanx, Paul


      reply	other threads:[~2014-08-28 12:58 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-27 20:43 [PATCH] rcu: Make nocb leader kthreads process pending callbacks after spawning Pranith Kumar
2014-08-27 21:47 ` Paul E. McKenney
2014-08-27 23:08   ` Pranith Kumar
2014-08-27 23:24     ` Paul E. McKenney
2014-08-28  5:46 ` Amit Shah
2014-08-28 12:58   ` Paul E. McKenney [this message]

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=20140828125841.GB4774@linux.vnet.ibm.com \
    --to=paulmck@linux.vnet.ibm.com \
    --cc=amit.shah@redhat.com \
    --cc=bobby.prani@gmail.com \
    --cc=josh@joshtriplett.org \
    --cc=laijs@cn.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=rostedt@goodmis.org \
    /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