stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
To: Greg KH <gregkh@linuxfoundation.org>
Cc: stable@vger.kernel.org, rostedt@goodmis.org
Subject: Re: [PATCH -stable] rcu: Allow for page faults in NMI handlers
Date: Fri, 13 Oct 2017 09:48:01 -0700	[thread overview]
Message-ID: <20171013164801.GC3521@linux.vnet.ibm.com> (raw)
In-Reply-To: <20171013163352.GA7914@kroah.com>

On Fri, Oct 13, 2017 at 06:33:52PM +0200, Greg KH wrote:
> On Fri, Oct 13, 2017 at 09:25:43AM -0700, Paul E. McKenney wrote:
> > On Fri, Oct 13, 2017 at 11:52:45AM +0200, Greg KH wrote:
> > > On Thu, Oct 12, 2017 at 04:09:28PM -0700, Paul E. McKenney wrote:
> > > > A number of architecture invoke rcu_irq_enter() on exception entry in
> > > > order to allow RCU read-side critical sections in the exception handler
> > > > when the exception is from an idle or nohz_full CPU.  This works, at
> > > > least unless the exception happens in an NMI handler.  In that case,
> > > > rcu_nmi_enter() would already have exited the extended quiescent state,
> > > > which would mean that rcu_irq_enter() would (incorrectly) cause RCU
> > > > to think that it is again in an extended quiescent state.  This will
> > > > in turn result in lockdep splats in response to later RCU read-side
> > > > critical sections.
> > > > 
> > > > This commit therefore causes rcu_irq_enter() and rcu_irq_exit() to
> > > > take no action if there is an rcu_nmi_enter() in effect, thus avoiding
> > > > the unscheduled return to RCU quiescent state.  This in turn should
> > > > make the kernel safe for on-demand RCU voyeurism.
> > > > 
> > > > Link: http://lkml.kernel.org/r/20170922211022.GA18084@linux.vnet.ibm.com
> > > > 
> > > > Cc: stable@vger.kernel.org # 4.2.x
> > > > Fixes: 0be964be0 ("module: Sanitize RCU usage and locking")
> > > > Reported-by: Steven Rostedt <rostedt@goodmis.org>
> > > > Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
> > > > Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
> > > 
> > > This does not apply to the 4.4-stable tree, was this the correct patch I
> > > should be using for that tree?
> > 
> > Hmmm...  Idiot here backported to v4.4 in Linus's tree, which of
> > course might not work...  But it applies to v4.4.92 of -stable:
> > 
> > git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git
> > 
> > Am I still applying it in the wrong place?
> 
> Ugh, no, you are doing the right thing.  I don't know what failed on my
> end, that's what I get for trying to deal with RCU early in the morning
> :)

Believe me, I know that feeling very well!  ;-)

							Thanx, Paul

> I'll go apply this now, sorry for the noise, and thanks for checking and
> the backport.
> 
> greg k-h
> 

  reply	other threads:[~2017-10-13 16:48 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-12 23:09 [PATCH -stable] rcu: Allow for page faults in NMI handlers Paul E. McKenney
2017-10-13  9:52 ` Greg KH
2017-10-13 16:25   ` Paul E. McKenney
2017-10-13 16:33     ` Greg KH
2017-10-13 16:48       ` Paul E. McKenney [this message]
  -- strict thread matches above, loose matches on Subject: below --
2017-10-12 23:08 Paul E. McKenney
2017-10-13  9:53 ` Greg KH

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=20171013164801.GC3521@linux.vnet.ibm.com \
    --to=paulmck@linux.vnet.ibm.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=rostedt@goodmis.org \
    --cc=stable@vger.kernel.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;
as well as URLs for NNTP newsgroup(s).