Commit 43bda69e authored by Uros Bizjak's avatar Uros Bizjak Committed by Ingo Molnar

x86/percpu: Define PER_CPU_VAR macro also for !__ASSEMBLY__

Some C source files define 'asm' statements that use PER_CPU_VAR,
so make PER_CPU_VAR macro available also without __ASSEMBLY__.
Signed-off-by: default avatarUros Bizjak <ubizjak@gmail.com>
Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/20231105213731.1878100-2-ubizjak@gmail.com
parent 0548eb06
...@@ -84,10 +84,15 @@ ...@@ -84,10 +84,15 @@
}) })
#endif /* CONFIG_USE_X86_SEG_SUPPORT */ #endif /* CONFIG_USE_X86_SEG_SUPPORT */
#define PER_CPU_VAR(var) %__percpu_seg:(var)__percpu_rel
#else /* CONFIG_SMP */ #else /* CONFIG_SMP */
#define __percpu_seg_override #define __percpu_seg_override
#define __percpu_prefix "" #define __percpu_prefix ""
#define __force_percpu_prefix "" #define __force_percpu_prefix ""
#define PER_CPU_VAR(var) (var)__percpu_rel
#endif /* CONFIG_SMP */ #endif /* CONFIG_SMP */
#define __my_cpu_type(var) typeof(var) __percpu_seg_override #define __my_cpu_type(var) typeof(var) __percpu_seg_override
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment