From 2c3c1048746a4622d8c89a29670120dc8fab93c4 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 20:49:45 +0200 Subject: Adding upstream version 6.1.76. Signed-off-by: Daniel Baumann --- arch/sparc/include/asm/percpu_64.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 arch/sparc/include/asm/percpu_64.h (limited to 'arch/sparc/include/asm/percpu_64.h') diff --git a/arch/sparc/include/asm/percpu_64.h b/arch/sparc/include/asm/percpu_64.h new file mode 100644 index 000000000..a8786a4b9 --- /dev/null +++ b/arch/sparc/include/asm/percpu_64.h @@ -0,0 +1,27 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +#ifndef __ARCH_SPARC64_PERCPU__ +#define __ARCH_SPARC64_PERCPU__ + +#include + +#ifndef BUILD_VDSO +register unsigned long __local_per_cpu_offset asm("g5"); +#endif + +#ifdef CONFIG_SMP + +#include + +#define __per_cpu_offset(__cpu) \ + (trap_block[(__cpu)].__per_cpu_base) +#define per_cpu_offset(x) (__per_cpu_offset(x)) + +#define __my_cpu_offset __local_per_cpu_offset + +#else /* ! SMP */ + +#endif /* SMP */ + +#include + +#endif /* __ARCH_SPARC64_PERCPU__ */ -- cgit v1.2.3