From 186f8bc1646b216fec9ec911972199ac5c866412 Mon Sep 17 00:00:00 2001 From: Olivier Deprez Date: Thu, 14 Nov 2024 08:53:26 +0100 Subject: [PATCH 1/6] config: cca-3world: amend post build and run instructions Update instructions for how to tweak rootfs after building. Added lkvm --restricted_mem option. Signed-off-by: Olivier Deprez --- config/cca-3world.yaml | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/config/cca-3world.yaml b/config/cca-3world.yaml index 9e4a25b..109aec0 100644 --- a/config/cca-3world.yaml +++ b/config/cca-3world.yaml @@ -32,11 +32,9 @@ description: >- .. code-block:: shell $ cd ~/.shrinkwrap/package/cca-3world - $ ORIGINAL_PATH=$PATH - $ export PATH=$PATH:~/.shrinkwrap/build/build/cca-3world/buildroot/host/bin/ - $ e2fsck -fp rootfs.ext2 - $ resize2fs rootfs.ext2 256M - $ export PATH=$ORIGINAL_PATH + $ TOOLS_PATH=~/.shrinkwrap/build/build/cca-3world/buildroot/host/sbin + $ $TOOLS_PATH/e2fsck -fp rootfs.ext2 + $ $TOOLS_PATH/resize2fs rootfs.ext2 256M $ sudo su # mkdir mnt # mount rootfs.ext2 mnt @@ -61,7 +59,7 @@ description: >- .. code-block:: shell # cd /cca - # ./lkvm run --realm --disable-sve --irqchip=gicv3-its --firmware KVMTOOL_EFI.fd -c 1 -m 512 --no-pvtime --force-pci --disk guest-disk.img --measurement-algo=sha256 + # ./lkvm run --realm --disable-sve --irqchip=gicv3-its --firmware KVMTOOL_EFI.fd -c 1 -m 512 --no-pvtime --force-pci --disk guest-disk.img --measurement-algo=sha256 --restricted_mem Be patient while this boots to the UEFI shell. Navigate to "Boot Manager", then "UEFI Shell" and wait for the startup.nsh script to execute, which will -- GitLab From d1c3f1a7b821e4c5dbd92ca5e240071bc78a0ed6 Mon Sep 17 00:00:00 2001 From: Olivier Deprez Date: Wed, 13 Nov 2024 14:36:49 +0100 Subject: [PATCH 2/6] config: update firmware components to v2.12 Update TF-A, TF-a-tests, Hafnium to latest v2.12 firmware bundle tag. Update RMM to latest v0.6.0 tag. Signed-off-by: Olivier Deprez --- config/ffa-hafnium-optee.yaml | 3 --- config/ffa-optee.yaml | 3 --- config/hafnium-base.yaml | 2 +- config/rmm-base.yaml | 2 +- config/tfa-base.yaml | 2 +- config/tftf-base.yaml | 2 +- 6 files changed, 4 insertions(+), 10 deletions(-) diff --git a/config/ffa-hafnium-optee.yaml b/config/ffa-hafnium-optee.yaml index 82170cd..33b9db1 100644 --- a/config/ffa-hafnium-optee.yaml +++ b/config/ffa-hafnium-optee.yaml @@ -28,9 +28,6 @@ build: CFG_CORE_WORKAROUND_NSITR_CACHE_PRIME: n tfa: - repo: - # Temporary until we move tfa-base.yaml to release version with this - revision: a169b8fbc2b184f2a38e7c6ee29371407b15c634 prebuild: - cat < ${param:builddir}/sp_layout.json - "{" diff --git a/config/ffa-optee.yaml b/config/ffa-optee.yaml index 9f89e60..615965d 100644 --- a/config/ffa-optee.yaml +++ b/config/ffa-optee.yaml @@ -22,9 +22,6 @@ build: CFG_CORE_ASYNC_NOTIF: y tfa: - repo: - # Temporary until we move tfa-base.yaml to release version with this - revision: a169b8fbc2b184f2a38e7c6ee29371407b15c634 params: ARM_SPMC_MANIFEST_DTS: ${param:sourcedir}/plat/arm/board/fvp/fdts/fvp_spmc_el1_optee_manifest.dts BL32: ${artifact:OPTEE_PAGER_BIN} diff --git a/config/hafnium-base.yaml b/config/hafnium-base.yaml index ad0e811..fca2c2e 100644 --- a/config/hafnium-base.yaml +++ b/config/hafnium-base.yaml @@ -10,7 +10,7 @@ build: hafnium: repo: remote: https://git.trustedfirmware.org/hafnium/hafnium.git - revision: v2.11 + revision: v2.12.0 params: PROJECT: reference diff --git a/config/rmm-base.yaml b/config/rmm-base.yaml index 162e781..a839231 100644 --- a/config/rmm-base.yaml +++ b/config/rmm-base.yaml @@ -7,7 +7,7 @@ build: rmm: repo: remote: https://git.trustedfirmware.org/TF-RMM/tf-rmm.git - revision: tf-rmm-v0.5.0 + revision: tf-rmm-v0.6.0 toolchain: aarch64-none-elf- diff --git a/config/tfa-base.yaml b/config/tfa-base.yaml index fd6f1ca..4bbd5ec 100644 --- a/config/tfa-base.yaml +++ b/config/tfa-base.yaml @@ -11,7 +11,7 @@ build: tfa: repo: remote: https://git.trustedfirmware.org/TF-A/trusted-firmware-a.git - revision: v2.11 + revision: v2.12.0 toolchain: aarch64-none-elf- diff --git a/config/tftf-base.yaml b/config/tftf-base.yaml index 74cde39..e313dbd 100644 --- a/config/tftf-base.yaml +++ b/config/tftf-base.yaml @@ -12,7 +12,7 @@ build: tftf: repo: remote: https://git.trustedfirmware.org/TF-A/tf-a-tests.git - revision: v2.11 + revision: v2.12.0 toolchain: aarch64-none-elf- -- GitLab From 92cd89cc37ee9c50cf4277779112a7123751136f Mon Sep 17 00:00:00 2001 From: Olivier Deprez Date: Thu, 14 Nov 2024 08:37:22 +0100 Subject: [PATCH 3/6] config: cca-3world: update linux and kvmtool Update linux to cca-full/v5+v7 revision. Update kvmtool to cca/v3 revision. Signed-off-by: Olivier Deprez Signed-off-by: Jean-Philippe Brucker --- config/cca-3world.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config/cca-3world.yaml b/config/cca-3world.yaml index 109aec0..0f6edab 100644 --- a/config/cca-3world.yaml +++ b/config/cca-3world.yaml @@ -100,7 +100,7 @@ build: linux: repo: remote: https://git.gitlab.arm.com/linux-arm/linux-cca.git - revision: cca-full/rmm-v1.0-eac5 + revision: cca-full/v5+v7 kvmtool: repo: @@ -108,7 +108,7 @@ build: revision: v1.6.1 kvmtool: remote: https://gitlab.arm.com/linux-arm/kvmtool-cca - revision: cca/rmm-v1.0-eac5 + revision: cca/v3 edk2-cca-guest: repo: -- GitLab From ac04aad6a71bb20dbcacc6bf39ab2ace7dc7aaf5 Mon Sep 17 00:00:00 2001 From: Olivier Deprez Date: Tue, 26 Nov 2024 09:59:02 +0100 Subject: [PATCH 4/6] config: fix guest kernel cmdline earlycon parm For EFI boot, the latest guest earlycon doesn't work as is and needs to explicitly specify the NS address. Signed-off-by: Olivier Deprez Signed-off-by: Jean-Philippe Brucker --- config/cca-3world.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/cca-3world.yaml b/config/cca-3world.yaml index 0f6edab..881d47e 100644 --- a/config/cca-3world.yaml +++ b/config/cca-3world.yaml @@ -152,7 +152,7 @@ build: - STARTUP="${param:builddir}/startup.nsh" # Automatically boot the kernel when starting the EFI shell. - - echo "bootaa64.efi acpi=force earlycon root=/dev/vda2 ip=on" > $${STARTUP} + - echo "bootaa64.efi acpi=force root=/dev/vda2 ip=on" > $${STARTUP} # 64MB fat16 boot partition containing kernel as efi bootloader. - dd if=/dev/zero of=$${BOOTIMG} bs=1M count=64 status=none -- GitLab From a290503f15616626ffdb1662b216f76758434230 Mon Sep 17 00:00:00 2001 From: Olivier Deprez Date: Wed, 27 Nov 2024 10:08:36 +0000 Subject: [PATCH 5/6] config: remove FVP-rme layer from cca-edk2 Signed-off-by: Olivier Deprez --- config/cca-edk2.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/config/cca-edk2.yaml b/config/cca-edk2.yaml index 97d9336..8b2abb4 100644 --- a/config/cca-edk2.yaml +++ b/config/cca-edk2.yaml @@ -44,7 +44,6 @@ description: >- concrete: true layers: - - FVP_Base_RevC-2xAEMvA-rme.yaml - tfa-rme.yaml - ns-edk2-base.yaml -- GitLab From e75d3066eb5134c0b327084d234aba809effc4a0 Mon Sep 17 00:00:00 2001 From: Olivier Deprez Date: Tue, 19 Nov 2024 21:38:11 +0100 Subject: [PATCH 6/6] config: disable brbe for 3 and 4 worlds With FM FVP 11.27 Armv9.2 FEAT_BRBE extension causes significant latency on normal world/realm world switching. Temporarily disable the extension at the FVP command line. Signed-off-by: Olivier Deprez --- config/tfa-rme.yaml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/config/tfa-rme.yaml b/config/tfa-rme.yaml index 26cf405..f0b7026 100644 --- a/config/tfa-rme.yaml +++ b/config/tfa-rme.yaml @@ -27,3 +27,12 @@ run: bp.terminal_3: friendly: rmm + params: + # With FM 11.27 FVP, Armv9.2 FEAT_BRBE implies a significant performance drop while + # normal/realm world switches happen. Temporarily disable it on the FVP command line + # to help the developer experience. + -C cluster0.has_brbe: 0 + -C cluster1.has_brbe: 0 + -C cluster0.has_brbe_v1p1: 0 + -C cluster1.has_brbe_v1p1: 0 + -- GitLab