aboutsummaryrefslogtreecommitdiff
path: root/arch/riscv/lib
diff options
context:
space:
mode:
authorBin Meng <bmeng.cn@gmail.com>2020-04-16 08:09:30 -0700
committerAndes <uboot@andestech.com>2020-04-23 10:14:06 +0800
commit191636e4489885d197e61ad34b48e8c76990735e (patch)
tree897eaa5de125f640a3153016a8ceba4f1a7a4eed /arch/riscv/lib
parent84dc9d26908798c7e9ee5469965c16653593fde5 (diff)
downloadu-boot-191636e4489885d197e61ad34b48e8c76990735e.zip
u-boot-191636e4489885d197e61ad34b48e8c76990735e.tar.gz
u-boot-191636e4489885d197e61ad34b48e8c76990735e.tar.bz2
riscv: Introduce SPL_SMP Kconfig option for U-Boot SPL
With SBI v0.2 HSM extension, only a single hart need to boot and enter operating system. The booting hart can bring up secondary harts one by one afterwards. For U-Boot running in SPL, SMP can be turned on, while in U-Boot proper, SMP can be optionally turned off if using SBI v0.2 HSM. Introduce a new SPL_SMP Kconfig option to support this. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Atish Patra <atish.patra@wdc.com>
Diffstat (limited to 'arch/riscv/lib')
-rw-r--r--arch/riscv/lib/Makefile2
-rw-r--r--arch/riscv/lib/spl.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/arch/riscv/lib/Makefile b/arch/riscv/lib/Makefile
index adadbf4..bd7b2c4 100644
--- a/arch/riscv/lib/Makefile
+++ b/arch/riscv/lib/Makefile
@@ -22,7 +22,7 @@ endif
obj-y += interrupts.o
obj-y += reset.o
obj-y += setjmp.o
-obj-$(CONFIG_SMP) += smp.o
+obj-$(CONFIG_$(SPL_)SMP) += smp.o
obj-$(CONFIG_SPL_BUILD) += spl.o
# For building EFI apps
diff --git a/arch/riscv/lib/spl.c b/arch/riscv/lib/spl.c
index ae07bbe..4ca038b 100644
--- a/arch/riscv/lib/spl.c
+++ b/arch/riscv/lib/spl.c
@@ -41,7 +41,7 @@ void __noreturn jump_to_image_no_args(struct spl_image_info *spl_image)
invalidate_icache_all();
debug("image entry point: 0x%lX\n", spl_image->entry_point);
-#ifdef CONFIG_SMP
+#ifdef CONFIG_SPL_SMP
ret = smp_call_function(spl_image->entry_point, (ulong)fdt_blob, 0, 0);
if (ret)
hang();