[PATCH v2] ring-buffer: Replace this_cpu_*() with __this_cpu_*()

Steven Rostedt rostedt at goodmis.org
Thu Mar 19 09:40:23 PDT 2015


On Thu, 19 Mar 2015 11:33:30 -0500 (CDT)
Christoph Lameter <cl at linux.com> wrote:

> If you are redoing it then please get the comments a bit cleared up. The

What comments should I clear up? This version did not have a comment.
It just switched this_cpu_* to __this_cpu_*, and also updated a
variable algorithm.

-- Steve


> heaviness of the fallback version of this_cpu_read/write can usually
> easily be remedied by arch specific definitions. The per cpu
> offset is somewhere in a register and one needs to define a macro that
> creates an instruction that does a fetch from that register plus
> the current offset into the area that is needed. This is similarly easy
> for the write path. But then its often easier to just use the __this_cpu
> instructions since preemption is often off in these code paths.
> 
> I have had code for IA64 in the past that does this.




More information about the linux-arm-kernel mailing list