This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Launching bare-metal firmware at EL2 (Hyp) on QEMU with ARM Trusted Firmware?

Hi experts,

I am recently developing some bare-metal code for a Cortex-A57 Aarch64 on QEMU (Virt platform) for playing with the Virtualization Extension. I first used one core and I developed a bootloader from scratch that switches the execution from EL3 to EL2. Now I want to move to multi core and for this reason I would like to use ARM Trusted Firmware for powering secondary cores by using PSCI.

The instructions provided in https://github.com/ARM-software/arm-trusted-firmware/blob/master/docs/plat/qemu.rst are supporting the execution of Linux as Non-Secure payload (Non-Secure EL1?) by using QEMU v2.6.0 (while I am using QEMU v2.10.1) . I tried to customized the procedure by doing:

1- "export CROSS_COMPILE=.../aarch64-linux-gnu-"

2- "make PLAT=qemu DEBUG=1"

3-  "cd build/qemu/debug"

4- "qemu-system-aarch64 -nographic -machine virt,secure=on -cpu cortex-a57 -kernel <my_kernel.bin> -append console=ttyAMA0,38400 -smp 2 -m 1024 -bios bl1.bin -d unimp -semihosting-config enable,target=native"

The output I get is the following:

NOTICE:  Booting Trusted Firmware
NOTICE:  BL1: v1.4(debug):v1.4-687-g5ff6da94
NOTICE:  BL1: Built : 16:42:50, Feb 27 2018
INFO:    BL1: RAM 0xe02e000 - 0xe036000
WARNING: BL1: cortex_a57: CPU workaround for 813419 was missing!
INFO:    BL1: cortex_a57: CPU workaround for disable_ldnp_overread was applied
WARNING: BL1: cortex_a57: CPU workaround for 826974 was missing!
WARNING: BL1: cortex_a57: CPU workaround for 826977 was missing!
WARNING: BL1: cortex_a57: CPU workaround for 828024 was missing!
WARNING: BL1: cortex_a57: CPU workaround for 829520 was missing!
WARNING: BL1: cortex_a57: CPU workaround for 833471 was missing!
WARNING: BL1: cortex_a57: CPU workaround for 859972 was missing!
INFO:    BL1: cortex_a57: CPU workaround for cve_2017_5715 was applied
INFO:    BL1: Loading BL2
WARNING: Firmware Image Package header check failed.
INFO:    Loading image id=1 at address 0xe003000
INFO:    Image id=1 loaded: 0xe003000 - 0xe00a1f0
NOTICE:  BL1: Booting BL2
INFO:    Entry point address = 0xe003000
INFO:    SPSR = 0x3c5
NOTICE:  BL2: v1.4(debug):v1.4-687-g5ff6da94
NOTICE:  BL2: Built : 16:42:51, Feb 27 2018
INFO:    BL2: Doing platform setup
INFO:    BL2: Loading image id 3
WARNING: Firmware Image Package header check failed.
INFO:    Loading image id=3 at address 0xe020000
INFO:    Image id=3 loaded: 0xe020000 - 0xe028090
INFO:    BL2: Loading image id 5
WARNING: Firmware Image Package header check failed.
INFO:    Loading image id=5 at address 0x60000000
WARNING: Failed to determine the size of the image id=5 (-2)
ERROR:   BL2: Failed to load image (-2)

Please, could someone help me?

Parents Reply Children
No data