LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* x86: mis-named percpu_xchg_op() after switch to cmpxchg?
@ 2011-02-07 11:01 Jan Beulich
  2011-02-07 17:17 ` Christoph Lameter
  0 siblings, 1 reply; 2+ messages in thread
From: Jan Beulich @ 2011-02-07 11:01 UTC (permalink / raw)
  To: tj, cl; +Cc: mingo, tglx, linux-kernel, hpa

Other than its name implies, with the switch to use cmpxchg instead of
xchg (commit 8270137a0d50507a5b40f880db636527045b8466) this
macro is no longer suitable for accessing anything that may be written
by other than the local CPU (i.e. anything but the various this_cpu
accessors). Shouldn't it therefore get renamed to eg this_cpu_xchg_op()?

Jan


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: x86: mis-named percpu_xchg_op() after switch to cmpxchg?
  2011-02-07 11:01 x86: mis-named percpu_xchg_op() after switch to cmpxchg? Jan Beulich
@ 2011-02-07 17:17 ` Christoph Lameter
  0 siblings, 0 replies; 2+ messages in thread
From: Christoph Lameter @ 2011-02-07 17:17 UTC (permalink / raw)
  To: Jan Beulich; +Cc: tj, mingo, tglx, linux-kernel, hpa

On Mon, 7 Feb 2011, Jan Beulich wrote:

> Other than its name implies, with the switch to use cmpxchg instead of
> xchg (commit 8270137a0d50507a5b40f880db636527045b8466) this
> macro is no longer suitable for accessing anything that may be written
> by other than the local CPU (i.e. anything but the various this_cpu
> accessors). Shouldn't it therefore get renamed to eg this_cpu_xchg_op()?

No. The intend of the percpu_xchg_op was also to provide local cpu only
semantics. percpu_xx operations in general have the same semantics as
this_cpu operations.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-02-07 17:17 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-02-07 11:01 x86: mis-named percpu_xchg_op() after switch to cmpxchg? Jan Beulich
2011-02-07 17:17 ` Christoph Lameter

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).