From: Tejun Heo Date: Wed, 12 May 2010 10:10:39 +0000 (+0200) Subject: ia64: add sparse annotation to __ia64_per_cpu_var() X-Git-Tag: master-2010-06-02~117^2 X-Git-Url: http://pileus.org/git/?a=commitdiff_plain;h=308eb7add8adaca8088c28a3f7610069b70d1ad6;hp=b0c9778b1d07ed3aa7e411db201275553527b1b1;p=~andy%2Flinux ia64: add sparse annotation to __ia64_per_cpu_var() ia64 has its own optimized percpu accessor - __ia64_per_cpu_var(). Add percpu sparse annotations to it. Signed-off-by: Tejun Heo Reviewed-by: Christoph Lameter --- diff --git a/arch/ia64/include/asm/percpu.h b/arch/ia64/include/asm/percpu.h index f7c00a5e0e2..1bd40826569 100644 --- a/arch/ia64/include/asm/percpu.h +++ b/arch/ia64/include/asm/percpu.h @@ -39,7 +39,10 @@ extern void *per_cpu_init(void); * On the positive side, using __ia64_per_cpu_var() instead of __get_cpu_var() is slightly * more efficient. */ -#define __ia64_per_cpu_var(var) var +#define __ia64_per_cpu_var(var) (*({ \ + __verify_pcpu_ptr(&(var)); \ + ((typeof(var) __kernel __force *)&(var)); \ +})) #include