Arm Community
Arm Community
  • Site
  • User
  • Site
  • Search
  • User
Open Source Software and Platforms
Open Source Software and Platforms
Wiki Guide to Set Up TF-A Firmwares Debug Environment on Arm DS for Total Compute Platform
  • Help
  • Jump...
  • Cancel
  • About this wiki
  • Supported platforms
  • Obtaining support
  • +Arm Reference Platforms deliverables
  • -A-class platforms
    • +Juno
    • +FVPs
    • -Total Compute Platforms
      • Guide to Set Up Debugging Environment for Total Compute Software Stack
      • Guide to Debug RSS Firmware Booting on Total Compute Platform
      • Guide to Debug SCP Firmware Booting on Total Compute Platform
      • Guide to Set Up TF-A Firmwares Debug Environment on Arm DS for Total Compute Platform
      • Guide to Debug Hafnium on Total Compute Platform
      • Guide to Disable AP Secure Images on Total Compute Platform
      • Guide to Run OpenEuler Embedded on TC2 Platform
      • Guide to add "Hello World" application into edk2 of TC2 LSC platform?
      • Guide to Set Up Linux Kernel Debug Environment on Arm DS for Total Compute Platform
      • Guide to Set Up U-boot Debug Environment on Arm DS for Total Compute Platform
    • +Morello Platform
    • +System Guidance for Infrastructure (SGI)
    • +System Guidance for Mobile (SGM)
    • Corstone-500
    • Cortex-A5 DesignStart
    • +Neoverse N1 SDP
    • Neoverse Reference Designs
    • +Legacy platforms
  • +M-class platforms
  • +R-class platforms
  • +FPGA prototyping boards
  • +Open source software

Guide to Set Up TF-A Firmwares Debug Environment on Arm DS for Total Compute Platform

The Trusted Firmware-A (TF-A) is implemented as Secure world software of Application Processor(AP) for the Arm Total Compute Platform, including a Secure Monitor executing at Exception Level 3 (EL3).

This guide describes the following tasks:

  • How to set up the TF-A debug connection.
  • How to load the TF-A debug symbol file.
  • How to start the TF-A debug.

This guide assumes that you already set up the debugging environment as described in the Guide to Set Up Debugging Environment for Total Compute Software Stack.

Note: The guidance given in this guide is based on the Total Compute TC23.1 code. Future code updates might introduce changes, so the guidance might not apply to all cases.

How to set up TF-A debugging connection

The Guide to Set Up Debugging Environment for Total Compute Software Stack describes how to set up the Total Compute debugging environment in the Arm DS.

There are some considerations to be aware of when setting up the TF-A debugging environment.

When debugging the TF-A, select ARM_Cortex-A520x2 SMP Cluster 0 as your target as shown in the following figure:


How to load the TF-A debug symbol file

In the Debugger tab of the TF-A debug configuration, include corresponding commands in Execute Debugger Commands to add symbol tables, as shown in the following figure:



Each time the debugging connection starts, these commands are automatically executed to load the symbol table files

Different firmwares run at different exception levels, so you must to specify different addresses for each ELF file. For example:

add-symbol-file /workspace/arm/tc23.1/output/tc3/buildroot/fvp/tmp_build/tfa/build/tc/debug/bl1/bl1.elf EL3:0
add-symbol-file /workspace/arm/tc23.1/output/tc3/buildroot/fvp/tmp_build/tfa/build/tc/debug/bl2/bl2.elf EL1S:0
add-symbol-file /workspace/arm/tc23.1/output/tc3/buildroot/fvp/tmp_build/tfa/build/tc/debug/bl31/bl31.elf EL3:0


You can also add other commands, such as setting breakpoints:

break bl1_main
break bl31_main
break EL3:0x04


The commands will automatically execute after connecting to the target as follows: 



How to start the TF-A debugging

When connecting the TF-A debug connection, you find that all cores are powered down and the Continue button is grey as follows:



To power up the Application Processor core, you must create an SCP debug connection according to the Guide to Debug RSS Firmware Booting on Total Compute Platform, and connect the SCP target as follows: 



You can set any breakpoints at the TF-A connection and click the Continue button at the SCP connection. The Application Processor core 0 is powered up by the SCP as follows: 




The Application Processor stops at the breakpoint and you can use the Continue button to continue debug the TF-A as follows: 

 

  • tf-a
  • Total Compute Solutions
  • Trusted Firmware
  • Share
  • History
  • More
  • Cancel
Related
Recommended