[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150629151402.GJ19282@twins.programming.kicks-ass.net>
Date: Mon, 29 Jun 2015 17:14:02 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Tejun Heo <tj@...nel.org>
Cc: Nicholas Mc Guire <der.herr@...r.at>, oleg@...hat.com,
paulmck@...ux.vnet.ibm.com, mingo@...hat.com,
linux-kernel@...r.kernel.org, dave@...olabs.net, riel@...hat.com,
viro@...IV.linux.org.uk, torvalds@...ux-foundation.org
Subject: Re: [RFC][PATCH 05/13] percpu-rwsem: Optimize readers and reduce
global impact
On Mon, Jun 29, 2015 at 11:12:20AM -0400, Tejun Heo wrote:
> Hello, Peter.
>
> On Mon, Jun 29, 2015 at 11:32:19AM +0200, Peter Zijlstra wrote:
> > Agreed, luckily we already have the infrastructure for this, something
> > like so?
> >
> > --- a/include/linux/percpu-defs.h
> > +++ b/include/linux/percpu-defs.h
> > @@ -287,6 +287,16 @@ do { \
> > preempt_enable(); \
> > } while (0)
> >
> > +#define per_cpu_sum(var) \
> > +({ \
> > + typeof(var) __sum = 0; \
> > + int cpu; \
>
> Why not __cpu?
I've no idea, __cpu is indeed more consistent, consider it changed.
--
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