Skip to content

Commit

Permalink
percpu: Replace __get_cpu_var with this_cpu_ptr
Browse files Browse the repository at this point in the history
__this_cpu_ptr is being phased out.  Use raw_cpu_ptr instead which was
introduced in 3.15-rc1.  One case of using __get_cpu_var in the
get_cpu_var macro for address calculation was remaining in
include/linux/percpu.h.

tj: Updated patch description.

Signed-off-by: Christoph Lameter <cl@linux.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
  • Loading branch information
Christoph Lameter authored and htejun committed Apr 15, 2014
1 parent c9eaa44 commit fdb9c29
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/linux/percpu.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
*/
#define get_cpu_var(var) (*({ \
preempt_disable(); \
&__get_cpu_var(var); }))
this_cpu_ptr(&var); }))

/*
* The weird & is necessary because sparse considers (void)(var) to be
Expand Down

0 comments on commit fdb9c29

Please sign in to comment.