]> git.baikalelectronics.ru Git - kernel.git/commit
tracing: Use __this_cpu_inc/dec operation instead of __get_cpu_var
authorShan Wei <davidshan@tencent.com>
Mon, 19 Nov 2012 05:21:01 +0000 (13:21 +0800)
committerSteven Rostedt <rostedt@goodmis.org>
Sat, 26 Jan 2013 01:36:54 +0000 (20:36 -0500)
commitc8d0cf7dcf2b07b804978ded359117b05cff60f6
tree241bf19a408130332b123780b55fc8303fee491b
parentff21c2c6ac28e2001e96302fad6993310a057bf0
tracing: Use __this_cpu_inc/dec operation instead of __get_cpu_var

__this_cpu_inc_return() or __this_cpu_dec generates a single instruction,
which is faster than __get_cpu_var operation.

Link: http://lkml.kernel.org/r/50A9C1BD.1060308@gmail.com
Reviewed-by: Christoph Lameter <cl@linux.com>
Signed-off-by: Shan Wei <davidshan@tencent.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
kernel/trace/trace.c