diff options
author | 2022-05-31 18:04:12 +0800 | |
---|---|---|
committer | 2022-06-03 20:09:29 +0800 | |
commit | 46859ac8af52ae599e1b51992ddef3eb43f295fc (patch) | |
tree | c1e6640316d5d8748bea046b71d2260b81cbe314 /arch/loongarch/kernel/asm-offsets.c | |
parent | LoongArch: Add VDSO and VSYSCALL support (diff) | |
download | linux-46859ac8af52ae599e1b51992ddef3eb43f295fc.tar.gz linux-46859ac8af52ae599e1b51992ddef3eb43f295fc.tar.bz2 linux-46859ac8af52ae599e1b51992ddef3eb43f295fc.zip |
LoongArch: Add multi-processor (SMP) support
LoongArch-based procesors have 4, 8 or 16 cores per package. This patch
adds multi-processor (SMP) support for LoongArch.
Reviewed-by: WANG Xuerui <git@xen0n.name>
Reviewed-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
Diffstat (limited to 'arch/loongarch/kernel/asm-offsets.c')
-rw-r--r-- | arch/loongarch/kernel/asm-offsets.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/arch/loongarch/kernel/asm-offsets.c b/arch/loongarch/kernel/asm-offsets.c index 3531e3c60a6e..bfb65eb2844f 100644 --- a/arch/loongarch/kernel/asm-offsets.c +++ b/arch/loongarch/kernel/asm-offsets.c @@ -252,3 +252,13 @@ void output_signal_defines(void) DEFINE(_SIGXFSZ, SIGXFSZ); BLANK(); } + +#ifdef CONFIG_SMP +void output_smpboot_defines(void) +{ + COMMENT("Linux smp cpu boot offsets."); + OFFSET(CPU_BOOT_STACK, secondary_data, stack); + OFFSET(CPU_BOOT_TINFO, secondary_data, thread_info); + BLANK(); +} +#endif |