percpu: Replace __get_cpu_var with this_cpu_ptr
One case of using __get_cpu_var in the get_cpu_var macro for address calculation.
Signed-off-by Christoph Lameter <[email protected]>
include/linux/percpu.h +1 -1
@@ -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
Tejun Heo
AppliedPATCH 1/1 percpu: Replace __get_cpu_var with this_cpu_ptr
Applied to percpu/for-3.16 with patch description updated.
Thanks.
--------- 8< ---------
Quoted 1 line
From
fdb9c293decf7e06795f7d9ae409df907c7ae1b6Mon Sep 17 00:00:00 2001
From: Christoph Lameter <[email protected]>
Date: Tue, 15 Apr 2014 12:39:14 -0500
__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 <[email protected]>
Signed-off-by Tejun Heo <[email protected]>
--- include/linux/percpu.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/percpu.h +1 -1
@@ -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
Signature · 1 line
1.9.0