aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/kprobes.h
diff options
context:
space:
mode:
authorChristoph Lameter <cl@linux.com>2010-12-06 12:16:25 -0500
committerTejun Heo <tj@kernel.org>2010-12-17 09:07:19 -0500
commitb76834bc1b6db0a0923eed85c81b1113021b0612 (patch)
treeb68c24d71ad0e6f26b317a2ef03c6139d31b8114 /include/linux/kprobes.h
parent4a6f4fe8377720e5a279fdbb769946c242e936d3 (diff)
kprobes: Use this_cpu_ops
Use this_cpu ops in various places to optimize per cpu data access. Cc: Jason Baron <jbaron@redhat.com> Cc: Namhyung Kim <namhyung@gmail.com> Acked-by: H. Peter Anvin <hpa@zytor.com> Signed-off-by: Christoph Lameter <cl@linux.com> Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'include/linux/kprobes.h')
-rw-r--r--include/linux/kprobes.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/kprobes.h b/include/linux/kprobes.h
index e7d1b2e0070d..0c251e9f0507 100644
--- a/include/linux/kprobes.h
+++ b/include/linux/kprobes.h
@@ -303,12 +303,12 @@ struct hlist_head * kretprobe_inst_table_head(struct task_struct *tsk);
303/* kprobe_running() will just return the current_kprobe on this CPU */ 303/* kprobe_running() will just return the current_kprobe on this CPU */
304static inline struct kprobe *kprobe_running(void) 304static inline struct kprobe *kprobe_running(void)
305{ 305{
306 return (__get_cpu_var(current_kprobe)); 306 return (__this_cpu_read(current_kprobe));
307} 307}
308 308
309static inline void reset_current_kprobe(void) 309static inline void reset_current_kprobe(void)
310{ 310{
311 __get_cpu_var(current_kprobe) = NULL; 311 __this_cpu_write(current_kprobe, NULL);
312} 312}
313 313
314static inline struct kprobe_ctlblk *get_kprobe_ctlblk(void) 314static inline struct kprobe_ctlblk *get_kprobe_ctlblk(void)