[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20100628195747.GA30400@linux.vnet.ibm.com>
Date: Mon, 28 Jun 2010 12:57:47 -0700
From: "Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
To: Tejun Heo <tj@...nel.org>
Cc: Lai Jiangshan <laijs@...fujitsu.com>,
Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...e.hu>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] rcu: simplify the usage of percpu data
On Mon, Jun 28, 2010 at 09:56:54AM -0700, Paul E. McKenney wrote:
> On Mon, Jun 28, 2010 at 10:38:39AM +0200, Tejun Heo wrote:
> > On 06/28/2010 10:25 AM, Lai Jiangshan wrote:
> > > &percpu_data is compatible with allocated percpu data.
> > >
> > > And we use it and remove the "rda[NR_CPUS]" array.
> > >
> > > Signed-off-by: Lai Jiangshan <laijs@...fujitsu.com>
> >
> > Looks good to me.
> >
> > Reviewed-by: Tejun Heo <tj@...nel.org>
>
> Thank you both!!! I have queued this.
FYI, I added the patchlet below to make it build for CONFIG_RCU_TRACE
kernels.
Thanx, Paul
------------------------------------------------------------------------
rcu: apply ->rda changes to rcutree_trace.c
The print_rcu_pendings() function used the ->rda[] array, so this
commit makes it instead use per_cpu_ptr().
Signed-off-by: Paul E. McKenney <paulmck@...ux.vnet.ibm.com>
diff --git a/kernel/rcutree_trace.c b/kernel/rcutree_trace.c
index 36c95b4..458e032 100644
--- a/kernel/rcutree_trace.c
+++ b/kernel/rcutree_trace.c
@@ -262,7 +262,7 @@ static void print_rcu_pendings(struct seq_file *m, struct rcu_state *rsp)
struct rcu_data *rdp;
for_each_possible_cpu(cpu) {
- rdp = rsp->rda[cpu];
+ rdp = per_cpu_ptr(rsp->rda, cpu);
if (rdp->beenonline)
print_one_rcu_pending(m, rdp);
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists