J721EXSOMXEVM: PDK Low Power Manager Demo Linux Boot Errors

Part Number: J721EXSOMXEVM
Other Parts Discussed in Thread: UNIFLASH

Tool/software:

I am attempting to run the Low Power Mode (LPM) Demo from the PDK 10_00_00. I am using a J721E EVM with a DR829.

When running the LPM demo, Linux is unable to boot on the MPU1_0 and fails in an early stage. Here is the output from UART when Linux tries to boot:

NOTICE:  BL31: v2.10.0(release):v2.10.0-367-g00f1ec6b87-dirty
NOTICE:  BL31: Built : 16:09:05, Feb  9 2024
ERROR:   Timeout waiting for thread SP_RESPONSE to fill
ERROR:   Thread SP_RESPONSE verification failed (-60)
ERROR:   Message receive failed (-60)
ERROR:   Failed to get response (-60)
ERROR:   Transfer send failed (-60)
ERROR:   Timeout waiting for thread SP_RESPONSE to fill
ERROR:   Thread SP_RESPONSE verification failed (-60)
ERROR:   Message receive failed (-60)
ERROR:   Failed to get response (-60)
ERROR:   Transfer send failed (-60)
ERROR:   Unable to query firmware capabilities (-60)
I/TC: 
I/TC: OP-TEE version: 4.2.0-dev (gcc version 13.3.0 (GCC)) #1 Fri Apr 12 09:51:21 UTC 2024 aarch64
I/TC: WARNING: This OP-TEE configuration might be insecure!
I/TC: WARNING: Please check https://optee.readthedocs.io/en/latest/architecture/porting_guidelines.html
I/TC: Primary CPU initializing
I/TC: GIC redistributor base address not provided
I/TC: Assuming default GIC group status and modifier
E/TC:0 0 k3_sec_proxy_verify_thread:108 Queue is busy
E/TC:0 0 k3_sec_proxy_recv:196 Thread SEC_PROXY_RESPONSE_THREAD verification failed. ret = -65523
E/TC:0 0 ti_sci_get_response:101 Message receive failed (-65523)
E/TC:0 0 ti_sci_do_xfer:150 Failed to get response (-65523)
E/TC:0 0 ti_sci_init:486 Unable to communicate with control firmware (-65523)
E/TC:0 0 call_initcalls:43 Initcall __text_start + 0x00070b10 failed
E/TC:0 0 k3_sec_proxy_verify_thread:108 Queue is busy
E/TC:0 0 k3_sec_proxy_recv:196 Thread SEC_PROXY_RESPONSE_THREAD verification failed. ret = -65523
E/TC:0 0 ti_sci_get_response:101 Message receive failed (-65523)
E/TC:0 0 ti_sci_do_xfer:150 Failed to get response (-65523)
E/TC:0 0 k3_sec_proxy_verify_thread:108 Queue is busy
E/TC:0 0 k3_sec_proxy_recv:196 Thread SEC_PROXY_RESPONSE_THREAD verification failed. ret = -65523
E/TC:0 0 ti_sci_get_response:101 Message receive failed (-65523)
E/TC:0 0 ti_sci_do_xfer:150 Failed to get response (-65523)
E/TC:0 0 k3_sec_proxy_verify_thread:108 Queue is busy
E/TC:0 0 k3_sec_proxy_recv:196 Thread SEC_PROXY_RESPONSE_THREAD verification failed. ret = -65523
E/TC:0 0 ti_sci_get_response:101 Message receive failed (-65523)
E/TC:0 0 ti_sci_do_xfer:150 Failed to get response (-65523)
E/TC:0 0 tee_otp_get_hw_unique_key:97 Could not get HUK
E/TC:0 0 call_initcalls:43 Initcall __text_start + 0x00070b38 failed
E/TC:0 0 k3_sec_proxy_verify_thread:108 Queue is busy
E/TC:0 0 k3_sec_proxy_recv:196 Thread SEC_PROXY_RESPONSE_THREAD verification failed. ret = -65523
E/TC:0 0 ti_sci_get_response:101 Message receive failed (-65523)
E/TC:0 0 ti_sci_do_xfer:150 Failed to get response (-65523)
E/TC:0 0 sa2ul_init:61 Failed to get SA2UL device
E/TC:0 0 call_initcalls:43 Initcall __text_start + 0x00070b40 failed
E/TC:0 0 
E/TC:0 0 Core data-abort at address 0x14 (translation fault)
E/TC:0 0  esr 0x96000005  ttbr0 0x9e8a2000   ttbr1 0x00000000   cidr 0x0
E/TC:0 0  cpu #0          cpsr 0x600003c4
E/TC:0 0  x0  000000009e875000 x1  0000000000000000
E/TC:0 0  x2  0000000000000000 x3  0000000000000000
E/TC:0 0  x4  0000000000000050 x5  000000009e892d70
E/TC:0 0  x6  ffffffffffffffb0 x7  0000000000010cb0
E/TC:0 0  x8  0000000000010cb0 x9  000000009e892f80
E/TC:0 0  x10 000000009e882070 x11 0000000000000008
E/TC:0 0  x12 0000000000000000 x13 000000009e8a3e60
E/TC:0 0  x14 0000000000000000 x15 0000000000000000
E/TC:0 0  x16 000000009e81cc5c x17 0000000000000000
E/TC:0 0  x18 0000000000000000 x19 000000009e8a41e0
E/TC:0 0  x20 000000009e8a41e8 x21 000000009e875000
E/TC:0 0  x22 000000009e875000 x23 000000009e875f00
E/TC:0 0  x24 000000009e874dc0 x25 0000000000000000
E/TC:0 0  x26 0000000000000000 x27 0000000000000000
E/TC:0 0  x28 0000000000000000 x29 000000009e8a4170
E/TC:0 0  x30 000000009e81741c elr 000000009e81742c
E/TC:0 0  sp_el0 000000009e8a4170
E/TC:0 0 TEE load address @ 0x9e800000
E/TC:0 0 Call stack:
E/TC:0 0  0x9e81742c
E/TC:0 0  0x9e807ca0
E/TC:0 0  0x9e8225fc
E/TC:0 0  0x9e807e9c
E/TC:0 0 Panic 'unhandled pageable abort' at /usr/src/debug/optee-os/4.2.0+git/core/arch/arm/kernel/abort.c:582 <abort_>
E/TC:0 0 TEE load address @ 0x9e800000
E/TC:0 0 Call stack:
E/TC:0 0  0x9e80817c
E/TC:0 0  0x9e81f0c0
E/TC:0 0  0x9e807884
E/TC:0 0  0x9e804a68

On the MCU1_0, everything runs perfectly. There are no errors and I measured the test points to confirm that as the MCU proceeds through the demo it is properly turning the MAIN domain on and off. Here is the output from MCU1_0:

MCU R5F App started at 33002 usecs

PMIC initialization done.
IPC_echo_test (core : mcu1_0) .....
Waiting for Linux VDev ready...
Calling Sciclient_procBootRequestProcessor, ProcId 0x6... 
Calling Sciclient_procBootRequestProcessor, ProcId 0x7... 
Loading BootImage
BootImage completed, status = 0
Sciclient_procBootReleaseProcessor, ProcId 0x6...
Sciclient_procBootReleaseProcessor, ProcId 0x7...
Sleeping for 10 seconds after each stage
MCU2_0 booted                                                                   
MCU2_1 booted                                                                   
Calling Sciclient_procBootRequestProcessor, ProcId 0x8...                       
Calling Sciclient_procBootRequestProcessor, ProcId 0x9...                       
Calling Sciclient_procBootRequestProcessor, ProcId 0x3...                       
Calling Sciclient_procBootRequestProcessor, ProcId 0x4...                       
Calling Sciclient_procBootRequestProcessor, ProcId 0x30...                      
Loading BootImage                                                               
BootImage completed, status = 0                                                 
Sciclient_procBootReleaseProcessor, ProcId 0x8...                               
Sciclient_procBootReleaseProcessor, ProcId 0x9...                               
Sciclient_procBootReleaseProcessor, ProcId 0x3...                               
Sciclient_procBootReleaseProcessor, ProcId 0x4...                               
Sciclient_procBootReleaseProcessor, ProcId 0x30...                              
C7X_0 booted                                                                    
Sleeping for 10 seconds after each stage                                        
MCU3_0 booted                                                                   
MCU3_1 booted                                                                   
Calling Sciclient_procBootRequestProcessor, ProcId 0x20...                      
Loading BootImage                                                               
BootImage completed, status = 0                                                 
Sciclient_procBootReleaseProcessor, ProcId 0x20...                              
Sleeping for 20 seconds after the last stage                                    
Boot App: Started at 2335180 usec                                               
Boot App: Total Num booted cores = 8                                            
Boot App: Booted Core ID #10 at 3646001 usecs                                   
Boot App: Booted Core ID #11 at 4646000 usecs                                   
Boot App: Booted Core ID #12 at 16345000 usecs                                  
Boot App: Booted Core ID #13 at 17345000 usecs                                  
Boot App: Booted Core ID #16 at 18345001 usecs                                  
Boot App: Booted Core ID #17 at 19345001 usecs                                  
Boot App: Booted Core ID #18 at 20345001 usecs                                  
Boot App: Booted Core ID #0 at 35901000 usecs                                   
Exiting rpmsg_vdevMonitorFxn!                                                   
MCU only app: Inside MCU ONLY task!                                             
MCU only app: Disabling MAXT_OUTRG_EN for TMPSENS1:4 in MAIN domain!            
MCU only app: STATE INFO :: CURRENTLY IN ACTIVE MODE!                           
MCU only app: LED LD5 should be ON                                              
MCU only app: Please measure TP133 and TP134!                                   
MCU only app: Expected values in ACTIVE mode:                                   
TP133: HIGH                                                                     
TP134: HIGH                                                                     
MCU only app: Kindly unload Remoteproc modules from Linux. Type these commands :
   modprobe -r ti_k3_r5_remoteproc                                              
   modprobe -r ti_k3_dsp_remoteproc                                             
MCU only app: After modules have been removed, press 1 and enter 


I am simply trying to get the demo to work in a default state and I have not modified anything (except for the necessary devicetree changes outlined in the documentation). Here are the steps I took while following these insutrctions.

  1. I modified the k3-j721e-common-proc-board.dts file in the Linux SDK and did a full yocto build. Then, I flashed the SD card and put it in the EVM. At this point, I checked that the device still booted as normal when in SD card mode.
  2. I located the 11 binaries needed for flashing the OSPI.
    1.  uart_j721e_evm_flash_programmer_release.tiimage
      1. C:\ti\uniflash_8.8.0\processors\FlashWriter\j721e_evm\uart_j721e_evm_flash_programmer_release.tiimage
      2. found in the uniflash installation path. I am using version 8.8.
    2. sbl_cust_img_mcu1_0_release.tiimage
      1. ti-processor-sdk-rtos-j721e-evm-10_00_00_05/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/binary/j721e_evm/cust/bin/sbl_cust_img_mcu1_0_release.tiimage
      2. found after running make all for J721E_EVM and MCU1_0
    3. tifs.bin
      1. ti-processor-sdk-rtos-j721e-evm-10_00_00_05/pdk_jacinto_10_00_00_27/packages/ti/drv/sciclient/soc/V1/tifs.bin
      2. I found this prebuilt. I don't know how to rebuild it or if I should.
    4. lpm_example_freertos_mcu1_0_release.appimage
      1. ti-processor-sdk-rtos-j721e-evm-10_00_00_05/pdk_jacinto_10_00_00_27/packages/ti/binary/lpm_example_freertos/bin/j721e_evm/lpm_example_freertos_mcu1_0_release.appimage
      2. built by running the make command from the LPM documentation: make lpm_example_freertos BOARD=j721e_evm CORE=mcu1_0 -sj8 BUILD_PROFILE=release
    5. multicore_MCU2_0_MCU2_1_stage1.appimage
      1. ti-processor-sdk-rtos-j721e-evm-10_00_00_05/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/example/boot_app/multicore_images/j721e_evm/multicore_MCU2_0_MCU2_1_stage1.appimage
      2. found pre-built
      3. I would like to know if this is supposed to be rebuilt for this demo
    6. multicore_DSPs_MCU3_0_MCU3_1_stage2.appimage
      1. ti-processor-sdk-rtos-j721e-evm-10_00_00_05/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/example/boot_app/multicore_images/j721e_evm/multicore_DSPs_MCU3_0_MCU3_1_stage2.appimage
      2. found pre-built
      3. I would like to know if this is supposed to be rebuilt for this demo
    7. multicore_MPU1_0_stage3.appimage
      1. ti-processor-sdk-rtos-j721e-evm-10_00_00_05/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/example/boot_app/multicore_images/j721e_evm/multicore_MPU1_0_stage3.appimage
      2. found pre-built
      3. I would like to know if this is supposed to be rebuilt for this demo
    8. atf_optee.appimage
      1. ti-processor-sdk-rtos-j721e-evm-10_00_00_05/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/tools/BootApp_binaries/linux/j721e_evm/atf_optee.appimage
      2. found pre-built
      3. I would like to know if this is supposed to be rebuilt for this demo
    9. tikernelimage_linux.appimage
      1. ti-processor-sdk-rtos-j721e-evm-10_00_00_05/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/tools/BootApp_binaries/linux/j721e_evm/tikernelimage_linux.appimage
      2. found pre-built
      3. I would like to know if this is supposed to be rebuilt for this demo
    10. tidtb_linux.appimage
      1. ti-processor-sdk-rtos-j721e-evm-10_00_00_05/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/tools/BootApp_binaries/linux/j721e_evm/tidtb_linux.appimage
      2. found pre-built
      3. I would like to know if this is supposed to be rebuilt for this demo
    11. nor_spi_patterns.bin
      1. ti-processor-sdk-rtos-j721e-evm-10_00_00_05/pdk_jacinto_10_00_00_27/packages/ti/board/src/flash/nor/ospi/nor_spi_patterns.bin
      2. found pre-built
  3. I put in the EVM into UART boot mode, found the COM port with the 'C' character being printed out, and flashed each binary to the instructed offset. There were no error messages.
  4. I switched to OSPI boot mode and power cycled the board. At this point I saw the successful UART output from MCU1_0 followed by the failed Linux boot over the MAIN UART.
  • Hi,

    Couple of questions before we dig deeper:

    • Are you using general purpose samples or high secure samples on your board? 
    • Also can you confirm if you can boot to Linux using the default boot flow using SPL U-Boot?

    Best regards,

    Keerthy 

  • 1. I am using a GP device. I am using unsigned images and they boot fine.

    2. I am able to boot Linux using the default boot flow using SPL U-Boot. I was able to boot Linux originally with the default Yocto build off of the SD card with U-Boot. Then, I made the devicetree changes for the LPM demo and tested that I can still successfully boot the new image from the SD card with U-Boot. This process and check is mentioned in step 1 of my original post. Please let me know if there is something you are asking me to clarify further.

    I suspect that my issue could be that my SBL is not configured correctly. As mentioned in 2B of my post, the SBL image I have is just the default that gets created when I build it as is. I have not made any changes or set any options because the LPM documentation does not instruct me to do so. However, after looking at this page on the J721E SBL and the Boot App, I realized that there are some options that might need to be changed from their default state to make the demo work. Can you confirm if this is the case? If so, could you provide instructions on which options to set and how to build?

    Thanks for your help.

  • Hi Louie,

    We are checking internally if the low power modes are having issues with the default SDK. We will keep you posted.

    - Keerthy

  • Hi Keerthy,

    thanks for checking this. Could you provide an update? We would need a working flow, which in this case needs only MCU1_0 firmware (MCU R5F) and A72 Linux, which here does not depend on OVX components or ethfw.

    Thanks!

    --Gunter

  • Hi Gunter/Louie,

    I am able to reproduce the issue. For some reason the uniflash was flaky. I used the U-boot to flash all the above binaries to OSPI.

    Logs on A72 On the EVM:

    NOTICE:  BL31: v2.10.0(release):v2.10.0-367-g00f1ec6b87-dirty
    NOTICE:  BL31: Built : 16:09:05, Feb  9 2024
    ERROR:   Timeout waiting for thread SP_RESPONSE to fill
    ERROR:   Thread SP_RESPONSE verification failed (-60)
    ERROR:   Message receive failed (-60)
    ERROR:   Failed to get response (-60)
    ERROR:   Transfer send failed (-60)
    ERROR:   Timeout waiting for thread SP_RESPONSE to fill
    ERROR:   Thread SP_RESPONSE verification failed (-60)
    ERROR:   Message receive failed (-60)
    ERROR:   Failed to get response (-60)
    ERROR:   Transfer send failed (-60)
    ERROR:   Unable to query firmware capabilities (-60)
    I/TC: 
    I/TC: OP-TEE version: 4.2.0-dev (gcc version 13.3.0 (GCC)) #1 Fri Apr 12 09:51:21 UTC 2024 aarch64
    I/TC: WARNING: This OP-TEE configuration might be insecure!
    I/TC: WARNING: Please check https://optee.readthedocs.io/en/latest/architecture/porting_guidelines.html
    I/TC: Primary CPU initializing
    I/TC: GIC redistributor base address not provided
    I/TC: Assuming default GIC group status and modifier
    E/TC:0 0 k3_sec_proxy_verify_thread:108 Queue is busy
    E/TC:0 0 k3_sec_proxy_recv:196 Thread SEC_PROXY_RESPONSE_THREAD verification failed. ret = -65523
    E/TC:0 0 ti_sci_get_response:101 Message receive failed (-65523)
    E/TC:0 0 ti_sci_do_xfer:150 Failed to get response (-65523)
    E/TC:0 0 ti_sci_init:486 Unable to communicate with control firmware (-65523)
    E/TC:0 0 call_initcalls:43 Initcall __text_start + 0x00070b10 failed
    E/TC:0 0 k3_sec_proxy_verify_thread:108 Queue is busy
    E/TC:0 0 k3_sec_proxy_recv:196 Thread SEC_PROXY_RESPONSE_THREAD verification failed. ret = -65523
    E/TC:0 0 ti_sci_get_response:101 Message receive failed (-65523)
    E/TC:0 0 ti_sci_do_xfer:150 Failed to get response (-65523)
    E/TC:0 0 k3_sec_proxy_verify_thread:108 Queue is busy
    E/TC:0 0 k3_sec_proxy_recv:196 Thread SEC_PROXY_RESPONSE_THREAD verification failed. ret = -65523
    E/TC:0 0 ti_sci_get_response:101 Message receive failed (-65523)
    E/TC:0 0 ti_sci_do_xfer:150 Failed to get response (-65523)
    E/TC:0 0 k3_sec_proxy_verify_thread:108 Queue is busy
    E/TC:0 0 k3_sec_proxy_recv:196 Thread SEC_PROXY_RESPONSE_THREAD verification failed. ret = -65523
    E/TC:0 0 ti_sci_get_response:101 Message receive failed (-65523)
    E/TC:0 0 ti_sci_do_xfer:150 Failed to get response (-65523)
    E/TC:0 0 tee_otp_get_hw_unique_key:97 Could not get HUK
    E/TC:0 0 call_initcalls:43 Initcall __text_start + 0x00070b38 failed
    E/TC:0 0 k3_sec_proxy_verify_thread:108 Queue is busy
    E/TC:0 0 k3_sec_proxy_recv:196 Thread SEC_PROXY_RESPONSE_THREAD verification failed. ret = -65523
    E/TC:0 0 ti_sci_get_response:101 Message receive failed (-65523)
    E/TC:0 0 ti_sci_do_xfer:150 Failed to get response (-65523)
    E/TC:0 0 sa2ul_init:61 Failed to get SA2UL device
    E/TC:0 0 call_initcalls:43 Initcall __text_start + 0x00070b40 failed
    E/TC:0 0 
    E/TC:0 0 Core data-abort at address 0x14 (translation fault)
    E/TC:0 0  esr 0x96000005  ttbr0 0x9e8a2000   ttbr1 0x00000000   cidr 0x0
    E/TC:0 0  cpu #0          cpsr 0x600003c4
    E/TC:0 0  x0  000000009e875000 x1  0000000000000000
    E/TC:0 0  x2  0000000000000000 x3  0000000000000000
    E/TC:0 0  x4  0000000000000050 x5  000000009e892d70
    E/TC:0 0  x6  ffffffffffffffb0 x7  0000000000010cb0
    E/TC:0 0  x8  0000000000010cb0 x9  000000009e892f80
    E/TC:0 0  x10 000000009e882070 x11 0000000000000008
    E/TC:0 0  x12 0000000000000000 x13 000000009e8a3e60
    E/TC:0 0  x14 0000000000000000 x15 0000000000000000
    E/TC:0 0  x16 000000009e81cc5c x17 0000000000000000
    E/TC:0 0  x18 0000000000000000 x19 000000009e8a41e0
    E/TC:0 0  x20 000000009e8a41e8 x21 000000009e875000
    E/TC:0 0  x22 000000009e875000 x23 000000009e875f00
    E/TC:0 0  x24 000000009e874dc0 x25 0000000000000000
    E/TC:0 0  x26 0000000000000000 x27 0000000000000000
    E/TC:0 0  x28 0000000000000000 x29 000000009e8a4170
    E/TC:0 0  x30 000000009e81741c elr 000000009e81742c
    E/TC:0 0  sp_el0 000000009e8a4170
    E/TC:0 0 TEE load address @ 0x9e800000
    E/TC:0 0 Call stack:
    E/TC:0 0  0x9e81742c
    E/TC:0 0  0x9e807ca0
    E/TC:0 0  0x9e8225fc
    E/TC:0 0  0x9e807e9c
    E/TC:0 0 Panic 'unhandled pageable abort' at /usr/src/debug/optee-os/4.2.0+git/core/arch/arm/kernel/abort.c:582 <abort_handler>
    E/TC:0 0 TEE load address @ 0x9e800000
    E/TC:0 0 Call stack:
    E/TC:0 0  0x9e80817c
    E/TC:0 0  0x9e81f0c0
    E/TC:0 0  0x9e807884
    E/TC:0 0  0x9e804a68
    

    Logs from R5F:

    Starting Sciserver..... PASSED
    
    MCU R5F App started at 33002 usecs
    
    PMIC initialization done.
    IPC_echo_test (core : mcu1_0) .....
    Waiting for Linux VDev ready...
    Calling Sciclient_procBootRequestProcessor, ProcId 0x6... 
    Calling Sciclient_procBootRequestProcessor, ProcId 0x7... 
    Loading BootImage
    BootImage completed, status = 0
    Sciclient_procBootReleaseProcessor, ProcId 0x6...
    Sciclient_procBootReleaseProcessor, ProcId 0x7...
    Sleeping for 10 seconds after each stage
    MCU2_0 booted
    MCU2_1 booted
    Calling Sciclient_procBootRequestProcessor, ProcId 0x8... 
    Calling Sciclient_procBootRequestProcessor, ProcId 0x9... 
    Calling Sciclient_procBootRequestProcessor, ProcId 0x3... 
    Calling Sciclient_procBootRequestProcessor, ProcId 0x4... 
    Calling Sciclient_procBootRequestProcessor, ProcId 0x30... 
    Loading BootImage
    BootImage completed, status = 0
    Sciclient_procBootReleaseProcessor, ProcId 0x8...
    Sciclient_procBootReleaseProcessor, ProcId 0x9...
    Sciclient_procBootReleaseProcessor, ProcId 0x3...
    Sciclient_procBootReleaseProcessor, ProcId 0x4...
    Sciclient_procBootReleaseProcessor, ProcId 0x30...
    C7X_0 booted
    Sleeping for 10 seconds after each stage
    MCU3_0 booted
    MCU3_1 booted
    Calling Sciclient_procBootRequestProcessor, ProcId 0x20... 
    Loading BootImage
    BootImage completed, status = 0
    Sciclient_procBootReleaseProcessor, ProcId 0x20...
    Sleeping for 20 seconds after the last stage
    Boot App: Started at 2335177 usec
    Boot App: Total Num booted cores = 8
    Boot App: Booted Core ID #10 at 3646001 usecs
    Boot App: Booted Core ID #11 at 4646000 usecs
    Boot App: Booted Core ID #12 at 16345001 usecs
    Boot App: Booted Core ID #13 at 17345000 usecs
    Boot App: Booted Core ID #16 at 18345001 usecs
    Boot App: Booted Core ID #17 at 19345000 usecs
    Boot App: Booted Core ID #18 at 20345000 usecs
    Boot App: Booted Core ID #0 at 35894001 usecs
    Exiting rpmsg_vdevMonitorFxn!
    MCU only app: Inside MCU ONLY task!
    MCU only app: Disabling MAXT_OUTRG_EN for TMPSENS1:4 in MAIN domain!
    MCU only app: STATE INFO :: CURRENTLY IN ACTIVE MODE!
    MCU only app: LED LD5 should be ON
    MCU only app: Please measure TP133 and TP134!
    MCU only app: Expected values in ACTIVE mode:
    TP133: HIGH
    TP134: HIGH
    MCU only app: Kindly unload Remoteproc modules from Linux. Type these commands in Linux CMD:
       modprobe -r ti_k3_r5_remoteproc
       modprobe -r ti_k3_dsp_remoteproc
    MCU only app: After modules have been removed, press 1 and enter
    
    Invalid input: MCU only app: Kindly unload Remoteproc modules from Linux. Type these commands in Linux CMD:
       modprobe -r ti_k3_r5_remoteproc
       modprobe -r ti_k3_dsp_remoteproc
    MCU only app: After modules have been removed, press 1 and enter
    
    

    From my top level observations:

    1. The errors happen because the communication between A72(ATF/OPTEE) & MCU R5F(DM/LPM) is broken.
      Traces: ERROR: Timeout waiting for thread SP_RESPONSE to fill
      ERROR: Thread SP_RESPONSE verification failed (-60)
      ERROR: Message receive failed (-60)
      ERROR: Failed to get response (-60)
    2. If i see the OSPI flashing map:
      lpm_example_freertos_mcu1_0_release.appimage> -d 3 -o 100000

      multicore_MCU2_0_MCU2_1_stage1.appimage> -d 3 -o 1FC0000

      But then we flash ATF/OPTEE later in between:
      atf_optee.appimage> -d 3 -o 1C0000
    3. The above could be an issue. I have already raised a high priority internal ticket so that development team is already looking into this.
      Best Regards,
      Keerthy 
  • Hi Keerthy,

    the above mapping with

    lpm_example_freertos_mcu1_0_release.appimage> -d 3 -o 100000
    atf_optee.appimage> -d 3 -o 1C0000

    has been in the PDK UG since e.g. SDK8.6

    Looking at the size of files

    319176 Oct 18 07:57 lpm_example_freertos_mcu1_0_release.appimage (approx 312KB)

    0xC0000 equates to 768KB space, so it seems there is enough space in the flash for the lpm binary, before the atf_optee.appimage starts at 0x1C0000. So there should not be an overlap.

    Regards,

    --Gunter

  • Gunter,

    Yes as already discussed on that call. I agree on that. Our internal expert is looking into this. We will keep you posted.

    - Keerthy

  • Hi Gunter/Louie,

    Adding the fix here.

    Please find the attachment for ……

    Please find the answers to the questions discussed in the previous meeting:

    1 . Can boot-app directly load u-boot?

                    Yes, the boot app example can load Uboot directly. Currently, it is not supported in PDK
                   
    2. What is the use of dummy binaries in stage 1 and stage 2 images?

                    These images are minimal example binary files built for each core. This binary will boot the core and write to common memory between the remote core and mcu1_0.

                    DM/mcu1_0 will poll on this memory address. Once the remote core writes to common memory, DM will print “MCU2_0 Booted”.

    Where to find all the binaries needed for LPM demo:

    Pre-built binaries:

    $SDK_Path/packages/ti/board/utils/uniflash/target/bin/j721e_evm/uart_j721e_evm_flash_programmer_release.tiimage
    $SDK_Path/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/binary/j721e_evm/cust/bin/sbl_cust_img_mcu1_0_release.tiimage
    $SDK_Path/pdk_jacinto_10_00_00_27/packages/ti/drv/sciclient/soc/V1/tifs.bin
    $SDK_Path/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/example/boot_app/multicore_images/j721e_evm/multicore_MCU2_0_MCU2_1_stage1.appimage
    $SDK_Path/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/example/boot_app/multicore_images/j721e_evm/multicore_DSPs_MCU3_0_MCU3_1_stage2.appimage

    $SDK_Path/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/example/boot_app/multicore_images/j721e_evm/multicore_MPU1_0_stage3.appimage
    $SDK_Path/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/tools/BootApp_binaries/linux/j721e_evm/atf_optee.appimage
    $SDK_Path/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/tools/BootApp_binaries/linux/j721e_evm/tikernelimage_linux.appimage 
    $SDK_Path/pdk_jacinto_10_00_00_27/packages/ti/boot/sbl/tools/BootApp_binaries/linux/j721e_evm/tidtb_linux.appimage
    $SDK_Path/pdk_jacinto_10_00_00_27/packages/ti/board/src/flash/nor/ospi/nor_spi_patterns.bin

    Only the lpm binary needs to be built:

    $SDK_Path/pdk_jacinto_10_00_00_27/packages/ti/binary/lpm_example_freertos/bin/j721e_evm/lpm_example_freertos_mcu1_0_release.appimage

    Thanks for the debug!

    Regards,
    Kerthy

  • Thank you for finding the root cause and sending the fix.

    However, I still need more instructions to test this demo. Specifically, you state that "only the lpm binary needs to be built." However, this is not the case.

    It is my understand that the devicetree changes listed in k3-j721e-common-proc-board.patch need to be applied to k3-j721e-common-proc-board.dts in the Linux SDK. From there, I still need instructions on how to build k3-j721e-common-proc-board.dts into a tidtb_linux.appimage file. Gunter and I are unable to locate this information in the documentation.

    I found steps in this E2E post that seem to describe the process (but for the vision apps). However, I get errors when trying to run the constructappimageshlos.sh script. Please provide the complete instructions for going from the modified k3-j721e-common-proc-board.dts in the Linux SDK to getting an output tidtb_linux.appimage file in RTOS SDK.

  • Louie,

    My bad. Attaching the working binary:

    tidtb_linux.appimage

    I believe you will need to recompile it yourself. This is to unblock validating the MCU_Only mode.

    - Keerthy

  • Thanks for your support and providing the binary. I will use this for my initial test.

    As requested in my previous message, could you please provide the full instructions for how to recompile the tidtb_linux.appimage? Specifically, I am looking for instructions on how to go from a an updated k3-j721e-common-proc-board.dts file to a .dtb file and finally to the tidtb_linux.appimage file. Gunter and I are unable to locate this information in the documentation.

  • Hi Louie,

    Step 1:

    I hope you have already installed the corresponding 10.0 Linux SDK: https://www.ti.com/tool/download/PROCESSOR-SDK-LINUX-J721E/10.00.00.08

    If not use the installer: https://dr-download.ti.com/software-development/software-development-kit-sdk/MD-U6uMjOroyO/10.00.00.08/ti-processor-sdk-linux-adas-j721e-evm-10_00_00_08-Linux-x86-Install.bin

    Install this SDK.

    Assuming the path of the Linux SDK is $SDK_Linux. You can edit the dts under: $SDK_Linux/board-support/ti-linux-kernel-6.6.32+git-ti/arch/arm64/boot/dts/ti/k3-j721e-common-proc-board.dts based on the patch provided.

    cd $SDK_Linux
    make linux-dtbs

    The above will generate k3-j721e-common-proc-board.dtb binary under the $SDK_Linux/board-support/ti-linux-kernel-6.6.32+git-ti/arch/arm64/boot/dts/ti/ folder. So now you have the modified k3-j721e-common-proc-board.dtb.

    cp $SDK_Linux/board-support/ti-linux-kernel-6.6.32+git-ti/arch/arm64/boot/dts/ti/k3-j721e-common-proc-board.dtb $SDK_Linux/board-support/prebuilt-images/

    Step 2:

    Compiling the tidtb_linux.appimage.

    cd ti-processor-sdk-rtos-j721e-evm-10_00_00_05/mcusw/mcuss_demos/boot_app_mcu_rtos/main_domain_apps
    mkdir binary
    mkdir binary/bin
    mkdir binary/bin/j721e_evm
    cd scripts/hlos/
    

    Edit the constructappimageshlos.sh

    Set MY_BOARD=j721e_evm
    Set OS=linux
    Set LINUX_BUILD_DIR_PATH=$SDK_Linux/board-support/board-support/prebuilt-images/

    Once you afre done editing the above. Now all the paths are set.

    Run the script & the sample output as below:

    ./constructappimageshlos.sh Generating atf_optee image
    WARNING: The runtime version supported by this application is unavailable.
    Using default runtime: v4.0.30319
    Parsing the input object file, /home/keerthy/work/ti-processor-sdk-rtos-j721e-evm-10_00_00_05/mcusw/mcuss_demos/boot_app_mcu_rtos/main_domain_apps/scripts/hlos/../../binary/bin/j721e_evm/atf_optee.elf.
    File conversion complete!
    Number of Input Files 1
    
    Generating tidtb_linux image
    WARNING: The runtime version supported by this application is unavailable.
    Using default runtime: v4.0.30319
    Parsing the input object file, /home/keerthy/work/ti-processor-sdk-rtos-j721e-evm-10_00_00_05/mcusw/mcuss_demos/boot_app_mcu_rtos/main_domain_apps/scripts/hlos/../../binary/bin/j721e_evm/tidtb_linux.elf.
    File conversion complete!
    Number of Input Files 1
    
    Generating tikernelimage_linux image
    WARNING: The runtime version supported by this application is unavailable.
    Using default runtime: v4.0.30319
    Parsing the input object file, /home/keerthy/work/ti-processor-sdk-rtos-j721e-evm-10_00_00_05/mcusw/mcuss_demos/boot_app_mcu_rtos/main_domain_apps/scripts/hlos/../../binary/bin/j721e_evm/tikernelimage_linux.elf.
    File conversion complete!
    Number of Input Files 1
    

    The required binaries are generated:

    ls -l ../../binary/bin/j721e_evm/
    total 61396
    -rw-rw-r-- 1 keerthy keerthy   535660 Oct 30 11:07 atf_optee.appimage
    -rwxrwxr-x 1 keerthy keerthy   614568 Oct 30 11:07 atf_optee.elf
    -rw-rw-r-- 1 keerthy keerthy   535628 Oct 30 11:07 atf_optee.rprc
    -rw-rw-r-- 1 keerthy keerthy   123788 Oct 30 11:07 tidtb_linux.appimage
    -rwxrwxr-x 1 keerthy keerthy   189848 Oct 30 11:07 tidtb_linux.elf
    -rw-rw-r-- 1 keerthy keerthy   123756 Oct 30 11:07 tidtb_linux.rprc
    -rw-rw-r-- 1 keerthy keerthy 20286024 Oct 30 11:07 tikernelimage_linux.appimage
    -rwxrwxr-x 1 keerthy keerthy 20352064 Oct 30 11:07 tikernelimage_linux.elf
    -rw-rw-r-- 1 keerthy keerthy 20285992 Oct 30 11:07 tikernelimage_linux.rprc
    

    Best Regards,
    Keerthy