File tree Expand file tree Collapse file tree 9 files changed +84
-2
lines changed
boards/arm/fvp_corstone1000 Expand file tree Collapse file tree 9 files changed +84
-2
lines changed Original file line number Diff line number Diff line change 33
44config BOARD_FVP_CORSTONE1000
55 select SOC_A320 if BOARD_FVP_CORSTONE1000_A320
6+ select SOC_A320 if BOARD_FVP_CORSTONE1000_A320_SMP
Original file line number Diff line number Diff line change @@ -106,6 +106,8 @@ if(CONFIG_BUILD_WITH_TFA)
106106 ENABLE_SVE_FOR_NS=1
107107 ENABLE_SVE_FOR_SWD=1
108108 ENABLE_STACK_PROTECTOR=strong
109+ # Multi-core PSCI support for secondary CPU boot
110+ ENABLE_MULTICORE=1
109111 )
110112
111113 # Output paths depend on debug/release
Original file line number Diff line number Diff line change 44 vendor : arm
55 socs :
66 - name : a320
7+ variants :
8+ - name : smp
Original file line number Diff line number Diff line change @@ -42,9 +42,10 @@ Supported Features
4242 Board Variants
4343==============
4444
45- The following board target is available:
45+ The following board targets are available:
4646
47- * ``fvp_corstone1000/a320 `` - ARMv9.2-A with Cortex-A320 CPU
47+ * ``fvp_corstone1000/a320 `` - single-core ARMv9.2-A with Cortex-A320 CPU
48+ * ``fvp_corstone1000/a320/smp `` - quad-core SMP with all 4 Cortex-A320 CPUs
4849
4950Memory Map
5051==========
Original file line number Diff line number Diff line change 99#include <zephyr/dt-bindings/interrupt-controller/arm-gic.h>
1010
1111/ {
12+ psci {
13+ compatible = "arm,psci-0.2";
14+ method = "smc";
15+ };
16+
1217 chosen {
1318 zephyr,sram = &dram0;
1419 zephyr,flash = &flash0;
Original file line number Diff line number Diff line change 1+ /*
2+ * Copyright (c) 2026 BayLibre SAS
3+ * SPDX-License-Identifier: Apache-2.0
4+ */
5+
6+ #include "fvp_corstone1000_a320.dts"
Original file line number Diff line number Diff line change 1+ # Copyright (c) 2026 BayLibre SAS
2+ # SPDX-License-Identifier: Apache-2.0
3+
4+ identifier : fvp_corstone1000/a320/smp
5+ name : Arm Corstone-1000-A320 Fixed Virtual Platform (SMP)
6+ arch : arm64
7+ type : sim
8+ simulation :
9+ - name : armfvp
10+ exec : FVP_Corstone-1000-A320
11+ toolchain :
12+ - zephyr
13+ - cross-compile
14+ ram : 128
15+ flash : 64
16+ vendor : arm
Original file line number Diff line number Diff line change 1+ # Copyright (c) 2026 BayLibre SAS
2+ # SPDX-License-Identifier: Apache-2.0
3+
4+ CONFIG_XIP=n
5+
6+ # Enable Timer and Sys clock
7+ CONFIG_SYS_CLOCK_TICKS_PER_SEC=1000
8+ CONFIG_ARM_ARCH_TIMER=y
9+
10+ # Enable UART driver
11+ CONFIG_SERIAL=y
12+
13+ # Enable serial port
14+ CONFIG_UART_INTERRUPT_DRIVEN=y
15+
16+ # Enable console
17+ CONFIG_CONSOLE=y
18+ CONFIG_UART_CONSOLE=y
19+
20+ # Run in Non-Secure mode (EL1NS) - TF-A handles secure boot
21+ CONFIG_ARMV8_A_NS=y
22+
23+ # PSCI support for CPU power management
24+ CONFIG_PM_CPU_OPS=y
25+
26+ # 64-bit timeout for long-running operations
27+ CONFIG_TIMEOUT_64BIT=y
28+
29+ # Cache management
30+ CONFIG_CACHE_MANAGEMENT=y
31+
32+ # SMP support - 4 Cortex-A320 cores
33+ CONFIG_SMP=y
34+ CONFIG_MP_MAX_NUM_CPUS=4
35+ CONFIG_MAX_THREAD_BYTES=3
36+
37+ # TF-A warm boot does not set VMPIDR_EL2 for secondary CPUs.
38+ # Without this, EL1 reads of MPIDR_EL1 return 0 on secondary cores.
39+ CONFIG_ARM64_SET_VMPIDR_EL2=y
Original file line number Diff line number Diff line change @@ -196,6 +196,11 @@ set(TFM_CMAKE_ARGS
196196 -DCORSTONE1000_DSU_120T=TRUE
197197)
198198
199+ # Multi-core support: boot all 4 host CPUs (secondaries enter holding pen)
200+ if ("${BOARD_QUALIFIERS} " MATCHES "/smp$" )
201+ list (APPEND TFM_CMAKE_ARGS -DENABLE_MULTICORE=TRUE )
202+ endif ()
203+
199204# Add toolchain bin directory to CMAKE_PROGRAM_PATH so CMake can find the compiler
200205if (ARM_GCC_M_TOOLCHAIN_DIR)
201206 list (APPEND TFM_CMAKE_ARGS "-DCMAKE_PROGRAM_PATH=${ARM_GCC_M_TOOLCHAIN_DIR} " )
@@ -295,6 +300,11 @@ set(TFA_EXTRA_ARGS
295300 NR_OF_IMAGES_IN_FW_BANK=4
296301)
297302
303+ # Multi-core PSCI support for secondary CPU boot
304+ if ("${BOARD_QUALIFIERS} " MATCHES "/smp$" )
305+ list (APPEND TFA_EXTRA_ARGS ENABLE_MULTICORE=1)
306+ endif ()
307+
298308# Find cross compiler for AArch64
299309if (DEFINED ENV{CROSS_COMPILE})
300310 set (TFA_CROSS_COMPILE $ENV{CROSS_COMPILE} )
You can’t perform that action at this time.
0 commit comments