public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@osdl.org>
To: dipankar@in.ibm.com
Cc: linux-kernel@vger.kernel.org,
	Paul E McKenney <paulmck@us.ibm.com>, Ingo Molnar <mingo@elte.hu>
Subject: Re: [-mm PATCH] RCU: debug sleep check
Date: Sun, 24 Sep 2006 14:44:40 -0700	[thread overview]
Message-ID: <20060924144440.ca7e6464.akpm@osdl.org> (raw)
In-Reply-To: <20060924213508.GG13432@in.ibm.com>

On Mon, 25 Sep 2006 03:05:08 +0530
Dipankar Sarma <dipankar@in.ibm.com> wrote:

> On Sun, Sep 24, 2006 at 11:56:46AM -0700, Andrew Morton wrote:
> > On Mon, 25 Sep 2006 00:05:09 +0530
> > Dipankar Sarma <dipankar@in.ibm.com> wrote:
> > 
> > > Add a debug check for rcu read-side critical section code calling
> > > a function that might sleep which is illegal. The check is enabled only
> > > if CONFIG_DEBUG_SPINLOCK_SLEEP is set.
> > > 
> > 
> > Does this actually change anything?  rcu_read_lock is preempt_disable(), and
> > might_sleep() already triggers if called inside preempt_disable().
> 
> It makes a difference if CONFIG_PREEMPT=n. AFAICS, preempt_disable()
> is a nop then and rcu needs its own check for sleeping while
> in read-side critical section.

Right.  I think enough people run with CONFIG_PREEMPT=y to make this
change rather unnecessary.

And if there are developers out there who are testing their code without an
effective CONFIG_DEBUG_SPINLOCK_SLEEP, then *that* is what we need to fix,
no?


  reply	other threads:[~2006-09-24 21:44 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-23 15:29 [-mm PATCH] RCU: various patches Dipankar Sarma
2006-09-23 15:31 ` [-mm PATCH 1/4] RCU: split classic rcu Dipankar Sarma
2006-09-25 16:54   ` Christoph Hellwig
2006-09-27 16:32     ` Paul E. McKenney
2006-09-28 14:26       ` Christoph Hellwig
2006-09-28 14:44         ` Dipankar Sarma
2006-09-23 15:34 ` [-mm PATCH 2/4]RCU: softirq for RCU Dipankar Sarma
2006-09-23 15:35 ` [-mm PATCH 3/4] RCU: preemptible RCU Dipankar Sarma
2006-09-23 15:36 ` [-mm PATCH 4/4] RCU: preempt rcu trace Dipankar Sarma
2006-09-23 18:56 ` [-mm PATCH] RCU: various patches Dipankar Sarma
2006-09-24  3:01   ` Dipankar Sarma
2006-09-24 14:38     ` Dipankar Sarma
2006-09-24 18:35 ` [-mm PATCH] RCU: debug sleep check Dipankar Sarma
2006-09-24 18:56   ` Andrew Morton
2006-09-24 21:35     ` Dipankar Sarma
2006-09-24 21:44       ` Andrew Morton [this message]
2006-09-24 21:58         ` Dipankar Sarma
2006-09-25 18:08   ` Paul E. McKenney

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=20060924144440.ca7e6464.akpm@osdl.org \
    --to=akpm@osdl.org \
    --cc=dipankar@in.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=paulmck@us.ibm.com \
    /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