public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
To: Lai Jiangshan <laijs@cn.fujitsu.com>
Cc: LKML <linux-kernel@vger.kernel.org>, Ingo Molnar <mingo@elte.hu>
Subject: Re: [PATCH] rcu: call __rcu_read_unlock() in exit_rcu()
Date: Sun, 9 Jan 2011 18:15:59 -0800	[thread overview]
Message-ID: <20110110021559.GG2383@linux.vnet.ibm.com> (raw)
In-Reply-To: <4D22DB19.3000300@cn.fujitsu.com>

On Tue, Jan 04, 2011 at 04:32:25PM +0800, Lai Jiangshan wrote:
> 
> rcu_read_unlock() is a wrapper of many things:
> 	the core __rcu_read_unlock(), debugs...etc.
> 
> It is better that we only calls the core __rcu_read_unlock() here.

Hello, Lai!

Last time I checked, a task exiting in an RCU read-side critical section
got an error before it got to this point.  That said, the "__" does a
good job of indicating that this is not a normal end of an RCU read-side
critical section.

I have queued this at least for the moment, and also created a TINY_RCU
counterpart.

							Thanx, Paul

> signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com>
> ---
> diff --git a/kernel/rcutree_plugin.h b/kernel/rcutree_plugin.h
> index a363871..94035a0 100644
> --- a/kernel/rcutree_plugin.h
> +++ b/kernel/rcutree_plugin.h
> @@ -802,7 +802,7 @@ void exit_rcu(void)
>  	if (t->rcu_read_lock_nesting == 0)
>  		return;
>  	t->rcu_read_lock_nesting = 1;
> -	rcu_read_unlock();
> +	__rcu_read_unlock();
>  }
> 
>  #else /* #ifdef CONFIG_TREE_PREEMPT_RCU */

      reply	other threads:[~2011-01-10  5:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-04  8:32 [PATCH] rcu: call __rcu_read_unlock() in exit_rcu() Lai Jiangshan
2011-01-10  2:15 ` 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=20110110021559.GG2383@linux.vnet.ibm.com \
    --to=paulmck@linux.vnet.ibm.com \
    --cc=laijs@cn.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    /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