xref: /kernel/linux/linux-5.10/arch/sparc/include/asm/percpu_64.h
  • Home
  • History
  • Annotate Annotate
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
  • only in /kernel/linux/linux-5.10/arch/sparc/include/asm/
18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */
28c2ecf20Sopenharmony_ci#ifndef __ARCH_SPARC64_PERCPU__
38c2ecf20Sopenharmony_ci#define __ARCH_SPARC64_PERCPU__
48c2ecf20Sopenharmony_ci
58c2ecf20Sopenharmony_ci#include <linux/compiler.h>
68c2ecf20Sopenharmony_ci
78c2ecf20Sopenharmony_ci#ifndef BUILD_VDSO
88c2ecf20Sopenharmony_ciregister unsigned long __local_per_cpu_offset asm("g5");
98c2ecf20Sopenharmony_ci#endif
108c2ecf20Sopenharmony_ci
118c2ecf20Sopenharmony_ci#ifdef CONFIG_SMP
128c2ecf20Sopenharmony_ci
138c2ecf20Sopenharmony_ci#include <asm/trap_block.h>
148c2ecf20Sopenharmony_ci
158c2ecf20Sopenharmony_ci#define __per_cpu_offset(__cpu) \
168c2ecf20Sopenharmony_ci	(trap_block[(__cpu)].__per_cpu_base)
178c2ecf20Sopenharmony_ci#define per_cpu_offset(x) (__per_cpu_offset(x))
188c2ecf20Sopenharmony_ci
198c2ecf20Sopenharmony_ci#define __my_cpu_offset __local_per_cpu_offset
208c2ecf20Sopenharmony_ci
218c2ecf20Sopenharmony_ci#else /* ! SMP */
228c2ecf20Sopenharmony_ci
238c2ecf20Sopenharmony_ci#endif	/* SMP */
248c2ecf20Sopenharmony_ci
258c2ecf20Sopenharmony_ci#include <asm-generic/percpu.h>
268c2ecf20Sopenharmony_ci
278c2ecf20Sopenharmony_ci#endif /* __ARCH_SPARC64_PERCPU__ */
28

Indexes created Thu Nov 07 10:32:03 CST 2024