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>
This commit is contained in:
committed by
Tejun Heo
parent
4a6f4fe837
commit
b76834bc1b
@@ -303,12 +303,12 @@ struct hlist_head * kretprobe_inst_table_head(struct task_struct *tsk);
|
||||
/* kprobe_running() will just return the current_kprobe on this CPU */
|
||||
static inline struct kprobe *kprobe_running(void)
|
||||
{
|
||||
return (__get_cpu_var(current_kprobe));
|
||||
return (__this_cpu_read(current_kprobe));
|
||||
}
|
||||
|
||||
static inline void reset_current_kprobe(void)
|
||||
{
|
||||
__get_cpu_var(current_kprobe) = NULL;
|
||||
__this_cpu_write(current_kprobe, NULL);
|
||||
}
|
||||
|
||||
static inline struct kprobe_ctlblk *get_kprobe_ctlblk(void)
|
||||
|
Reference in New Issue
Block a user