This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TDA4VM: UFS error in Uboot

Part Number: TDA4VM

Tool/software:

Hi

We use sdk 10.

UFS:KLUEGAJ1ZD-B0CQ059

In U-Boot, after entering ufs init and scsi scan, the following error sometimes occurs.

U-Boot SPL 2024.04-ti-gc215c8a1b536 (Apr 18 2025 - 05:55:58 +0000)
SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
Trying to boot from SPI
Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
Loading Environment from nowhere... OK
Starting ATF on ARM64 core...

NOTICE:  BL31: v2.10.0(release):v2.10.0-367-g00f1ec6b87-dirty
NOTICE:  BL31: Built : 16:09:05, Feb  9 2024
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
I/TC: SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
I/TC: HUK Initialized
I/TC: Activated SA2UL device
I/TC: Fixing SA2UL firewall owner for GP device
I/TC: Enabled firewalls for SA2UL TRNG device
I/TC: SA2UL TRNG initialized
I/TC: SA2UL Drivers initialized
I/TC: Primary CPU switching to normal world boot

U-Boot SPL 2024.04-ti-gc215c8a1b536 (Apr 18 2025 - 05:55:58 +0000)
SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
Detected: J7X-BASE-CPB rev E3
Detected: J7X-VSC8514-ETH rev E2
Trying to boot from SPI
k3-navss-ringacc ringacc@2b800000: Ring Accelerator probed rings:286, gp-rings[96,20] sci-dev-id:235
k3-navss-ringacc ringacc@2b800000: dma-ring-reset-quirk: disabled
jedec_spi_nor flash@0: non-uniform erase sector maps are not supported yet.
Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted


U-Boot 2024.04-ti-gc215c8a1b536 (Apr 18 2025 - 05:55:58 +0000)

SoC:   J721E SR1.1 GP
Model: Texas Instruments J721e EVM
Board: J721EX-PM2-SOM rev E8
DRAM:  2 GiB (effective 4 GiB)
Core:  116 devices, 34 uclasses, devicetree: separate
Flash: 0 Bytes
MMC:   mmc@4f80000: 0, mmc@4fb0000: 1
Loading Environment from nowhere... OK
In:    serial@2800000
Out:   serial@2800000
Err:   serial@2800000
am65_cpsw_nuss ethernet@46000000: K3 CPSW: nuss_ver: 0x6BA00101 cpsw_ver: 0x6BA80100 ale_ver: 0x00293904 Ports:1
Detected: J7X-BASE-CPB rev E3
Detected: J7X-VSC8514-ETH rev E2
Net:   Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000port@1: phy_connect() failed
No ethernet found.

k3-navss-ringacc ringacc@2b800000: Ring Accelerator probed rings:286, gp-rings[96,20] sci-dev-id:235
k3-navss-ringacc ringacc@2b800000: dma-ring-reset-quirk: disabled
jedec_spi_nor flash@0: non-uniform erase sector maps are not supported yet.
SF: Detected s28hs512t with page size 256 Bytes, erase size 256 KiB, total 64 MiB
device 0 offset 0x680000, size 0x9
SF: 9 bytes @ 0x680000 Read: OK
Error: Invalid flag byte at 0x80000000. Value: 0xFF
Hit any key to stop autoboot:  0
Device at ufs@4e84000 up at:cdns-ufs-pltfm ufs@4e84000: [RX, TX]: gear=[3, 3], lane[2, 2], pwr[FAST MODE, FAST MODE], rate = 2
scanning bus for devices...
cdns-ufs-pltfm ufs@4e84000: Error in status:00000004
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: Error in status:00000004
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: Error in status:00000014
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: Error in status:00000004
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: Error in status:00000004
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: Error in status:00000014
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: Error in status:00000004
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: Error in status:00000004
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: Error in status:00000015
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f
cdns-ufs-pltfm ufs@4e84000: OCS error from controller = f

Device 0: unknown device
** Bad device specification scsi 0 **
** Bad device specification scsi 0 **
Couldn't find partition scsi 0:1
Can't set block device
** Bad device specification scsi 0 **
Couldn't find partition scsi 0:1
Can't set block device
** Bad device specification scsi 0 **
Couldn't find partition scsi 0:1
Can't set block device
** Bad device specification scsi 0 **
Couldn't find partition scsi 0:1
Can't set block device
** Bad device specification scsi 0 **
Couldn't find partition scsi 0:1
Can't set block device
** Bad device specification scsi 0 **
Couldn't find partition scsi 0:1
Can't set block device
** Bad device specification scsi 0 **
Couldn't find partition scsi 0:1
Can't set block device
** Bad device specification scsi 0 **
Couldn't find partition scsi 0:1
Can't set block device
** Bad device specification scsi 0 **
Couldn't find partition scsi 0:1
Can't set block device
** Bad device specification scsi 0 **
Couldn't find partition scsi 0:1
Can't set block device
libfdt fdt_check_header(): FDT_ERR_BADMAGIC
No FDT memory address configured. Please configure
the FDT address via "fdt addr <address>" command.
Aborting!
Bad Linux ARM64 Image magic!
Scanning for bootflows in all bootdevs
Seq  Method       State   Uclass    Part  Name                      Filename
---  -----------  ------  --------  ----  ------------------------  ----------------
Scanning global bootmeth 'efi_mgr':
No EFI system partition
No EFI system partition
Failed to persist EFI variables
No EFI system partition
Failed to persist EFI variables
No EFI system partition
Failed to persist EFI variables
No EFI system partition
Failed to persist EFI variables
No EFI system partition
Failed to persist EFI variables
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
  0  efi_mgr      ready   (none)       0  <NULL>
** Booting bootflow '<NULL>' with efi_mgr
Loading Boot0000 'mmc 0' failed
Loading Boot0001 'mmc 1' failed
EFI boot manager: Cannot load any image
Boot failed (err=-14)
Scanning bootdev 'mmc@4fb0000.bootdev':
Scanning bootdev 'mmc@4f80000.bootdev':
Bus usb@6400000: cdns-usb3-host usb@6400000: DRD version v1 (ID: 0004024e, rev: 00000200)
Register 2000840 NbrPorts 2
Starting the controller
USB XHCI 1.00
scanning bus usb@6400000 for devices... 1 USB Device(s) found
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
No ethernet found.
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
No ethernet found.
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
Could not get PHY for mdio@f00: addr 0
am65_cpsw_nuss_port ethernet@46000000ethernet@46000: phy_connect() failed
No more bootdevs
---  -----------  ------  --------  ----  ------------------------  ----------------
(1 bootflow, 1 valid)
=>

 There are any patches for the UFS driver in uboot?

BR

liupt

  • We use sdk 10.

    UFS:KLUEGAJ1ZD-B0CQ059

    In U-Boot, after entering ufs init and scsi scan, the following error sometimes occur

    Is this a custom board? Also was this functional in the previous version of the SDK?

    - Keerthy

  • HI 

    Yes it is a custom board.

    This is a probabilistic issue. By continuously restarting and entering commands, the reproduction probability is approximately one in several dozen attempts.

    BR

    liupt

  • Hi Liupt,

    Let me try this out at my end. I will respond back here by mid next week.

    Is the flash same as what we use on EVM or is it different?

    Regards,
    Tanmay

  • Hi 

    Is the flash same as what we use on EVM or is it different?

        -------》No the Flash isS28HS512TGABHM010

    But now the problem is caused by UFS.

    BR

    liupt

  • Hi Liupt,

    I was talking about the UFS Flash. On EVM, we have THGAF8G8T23BA. Is the same flash being used by you?

    Regards,
    Tanmay

  • Hi Tanmay

    Get it the ufs is :KLUEGAJ1ZD-B0CQ059

    BR

    liupt

  • Hi Liupt,

    What does the log look like in successful case. Can you share that dump.

    Regards,
    Tanmay

  • Hi Tanmay

    U-Boot SPL 2024.04 (May 01 2025 - 14:57:04 +0800)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    Trying to boot from MMC2
    Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
    Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
    Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
    Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
    Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
    Loading Environment from nowhere... OK
    Starting ATF on ARM64 core...
    
    NOTICE:  BL31: v2.10.0(release):v2.10.0-367-g00f1ec6b87-dirty
    NOTICE:  BL31: Built : 16:09:05, Feb  9 2024
    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
    I/TC: SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    I/TC: HUK Initialized
    I/TC: Activated SA2UL device
    I/TC: Fixing SA2UL firewall owner for GP device
    I/TC: Enabled firewalls for SA2UL TRNG device
    I/TC: SA2UL TRNG initialized
    I/TC: SA2UL Drivers initialized
    I/TC: Primary CPU switching to normal world boot
    
    U-Boot SPL 2024.04 (May 01 2025 - 14:56:46 +0800)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    Detected: J7X-BASE-CPB rev E3
    Detected: J7X-VSC8514-ETH rev E2
    Trying to boot from MMC2
    Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
    Warning: Detected image signing certificate on GP device. Skipping certificate to prevent boot failure. This will fail if the image was also encrypted
    
    
    U-Boot 2024.04 (May 01 2025 - 14:56:46 +0800)
    
    SoC:   J721E SR1.1 GP
    Model: Texas Instruments J721e EVM
    Board: J721EX-PM2-SOM rev E8
    DRAM:  2 GiB (effective 4 GiB)
    Core:  116 devices, 34 uclasses, devicetree: separate
    Flash: 0 Bytes
    MMC:   mmc@4f80000: 0, mmc@4fb0000: 1
    Loading Environment from nowhere... OK
    In:    serial@2800000
    Out:   serial@2800000
    Err:   serial@2800000
    am65_cpsw_nuss ethernet@46000000: K3 CPSW: nuss_ver: 0x6BA00101 cpsw_ver: 0x6BA80100 ale_ver: 0x00293904 Ports:1
    Detected: J7X-BASE-CPB rev E3
    Detected: J7X-VSC8514-ETH rev E2
    Net:   Could not get PHY for mdio@f00: addr 0
    am65_cpsw_nuss_port ethernet@46000000port@1: phy_connect() failed
    No ethernet found.
    
    k3-navss-ringacc ringacc@2b800000: Ring Accelerator probed rings:286, gp-rings[96,20] sci-dev-id:235
    k3-navss-ringacc ringacc@2b800000: dma-ring-reset-quirk: disabled
    jedec_spi_nor flash@0: non-uniform erase sector maps are not supported yet.
    SF: Detected s28hs512t with page size 256 Bytes, erase size 256 KiB, total 64 MiB
    device 0 offset 0x680000, size 0x9
    SF: 9 bytes @ 0x680000 Read: OK
    The current system is on Partition A, set bootpart 0:1.
    Hit any key to stop autoboot:  0 
    Device at ufs@4e84000 up at:cdns-ufs-pltfm ufs@4e84000: [RX, TX]: gear=[3, 3], lane[2, 2], pwr[FAST MODE, FAST MODE], rate = 2
    scanning bus for devices...
      Device 0: (0:0) Vendor: SAMSUNG Prod.: KLUEGAJ1ZD-B0CQ Rev: 5900
                Type: Hard Disk
                Capacity: 241183.9 MB = 235.5 GB (61743103 x 4096)
      Device 1: (0:1) Vendor: SAMSUNG Prod.: KLUEGAJ1ZD-B0CQ Rev: 5900
                Type: Hard Disk
                Capacity: 31.9 MB = 0.0 GB (8191 x 4096)
      Device 2: (0:2) Vendor: SAMSUNG Prod.: KLUEGAJ1ZD-B0CQ Rev: 5900
                Type: Hard Disk
                Capacity: 31.9 MB = 0.0 GB (8191 x 4096)
    
    Device 0: (0:0) Vendor: SAMSUNG Prod.: KLUEGAJ1ZD-B0CQ Rev: 5900
                Type: Hard Disk
                Capacity: 241183.9 MB = 235.5 GB (61743103 x 4096)
    ... is now current device
    198 bytes read in 28 ms (6.8 KiB/s)
    Loaded env from uEnv.txt
    Importing environment from scsi 0:1 ...
    Running uenvcmd ...
    1420992 bytes read in 30 ms (45.2 MiB/s)
    Load Remote Processor 2 with data@addr=0x82000000 1420992 bytes: Success!
    322804 bytes read in 28 ms (11 MiB/s)
    Load Remote Processor 3 with data@addr=0x82000000 322804 bytes: Success!
    Failed to load '/lib/firmware/j7-main-r5f1_0-fw'
    Failed to load '/lib/firmware/j7-main-r5f1_1-fw'
    998192 bytes read in 28 ms (34 MiB/s)
    Load Remote Processor 6 with data@addr=0x82000000 998192 bytes: Success!
    998192 bytes read in 29 ms (32.8 MiB/s)
    Load Remote Processor 7 with data@addr=0x82000000 998192 bytes: Success!
    13504656 bytes read in 43 ms (299.5 MiB/s)
    Load Remote Processor 8 with data@addr=0x82000000 13504656 bytes: Success!
    20945408 bytes read in 60 ms (332.9 MiB/s)
    114126 bytes read in 27 ms (4 MiB/s)
    Working FDT set to 88000000
    1783 bytes read in 26 ms (66.4 KiB/s)
    11541 bytes read in 27 ms (417 KiB/s)
    ## Flattened Device Tree blob at 88000000
       Booting using the fdt blob at 0x88000000
    Working FDT set to 88000000
    ERROR: reserving fdt memory region failed (addr=880000000 size=27000000 flags=4)
       Loading Device Tree to 000000008fee1000, end 000000008fffffff ... OK
    Working FDT set to 8fee1000
    
    Starting kernel ...
    

    BR

    liupt

  • Hi Tanmay

    Have any update for this topic?

    BR
    JAY

  • Hi, Tanmay

    Compare these two err logs, I found some thing strangeness.

    (1) What does the error mean? (Error: Invalid flag byte at 0x80000000. Value: 0xFF)

    (2) OCS return value is 0xF, so I try to study JEDEC 2223A UFS protocol description. 

    I think this error should be happen in UFS flash early init stage, Do you have any debug suggestion?

    (3) Is it possible to decreases UFS R/W access speed for debugging?

    Wait your more suggestion

       

    Hi, liupt

    I saw these two logs are a little bit different and  feel confuse 

    (a) success boot log : SD boot from R5-SPL first , and then UFS boot from A72 SPL, isn't?

    (b) error boot log : OSPI Flash boot from R5-SPL first , and then UFS boot from A72 SPL, isn't?

    Few question,

    (1) Base on item (b), does it happen randomly? 

    (2) Base on item (a), does it happen also happen randomly? 

    (3) Does it have any special test pattern to duplicate this problem on your customized board?

    (4) Do you use another customized board w/ same issue?

    Thanks

    Gibbs

  • Hi 

    (a) success boot log : SD boot from R5-SPL first , and then UFS boot from A72 SPL, isn't?

    -------》NO,all boot in XSPI mode

    (b) error boot log : OSPI Flash boot from R5-SPL first , and then UFS boot from A72 SPL, isn't?

    ------>NO,NO,all boot in XSPI mode

    In XSPI boot mode, the error occurs randomly.

  • Hi,

    Tanmay is out of office for this week. Please expect a response early next week.

    Thanks for your patience,
    Keerthy

  • Hi, liupt

    I think we could still do some test until Tanmay come back.

    Few question,

    (1) Invalid byte error

    I saw boots failed w/ error message "Invalid flag byte at 0x8000 0000". How do you make sure there is no relationship w/ UFS boot failed?

    (2) Hand shake checking for "NOP OUT(IN) UPIU"

    Because I suspect this "may be" an UFS flash POR issues, so I curius to know, how about check first hand shank message (NOP OUT(IN) UPIU)?

    Is it successful? you can stuff some debug message in u-boot

    Ref. https://blog.csdn.net/comeonbestxiaohe/article/details/88549918

    Related code,

      

    (3) UIC Error

    You can trace log, error code is "cdns-ufs-pltfm ufs@4e84000: Error in status:00000004"

    This is UIC error, we may need to study how UIC error happens.

    Some UIC error register in TRM,

    (4) Reset

    How about use "scsi reset" before "ufs init"

    Gibbs

  • Hi, Tanmay

    Pls feel free to get us some comment when you see this thread

    Thank You Very Mnuch

    Gibbs

  • Hi Gibbs

    Update UFS boot failure issue where the system halts during U-Boot.

    White check mark Observations:

    1. Power and Signal Sequence Check
      We reviewed the timing of the following UFS-related signals:

      • UFS0_RSTN

      • UFS0_REF_CLK

      • VCC_3V3_UFS

      • VCC_1V8_UFS

      In the failure case, the waveforms show that UFS0_RSTN was not pulled LOW  during boot. This might indicate an issue with reset sequencing.

    2. Register Write Status Check
      The U-Boot log shows same behavior in UFS reset status=1 between success and failure:

      • fail

      • success


        How to ensure that UFS0_RSTN is working correctly, are there any recommended areas to adjust?


        BR
        JAY
  • Hi Jay,

    Was the schematic verified by TI?

    I will loop in our hardware exper here to look at the signals.

    Regards,

    Tanmay 

  • Hi, Tanmay

    SCH already verified by TI

    If you need SCH, please let me know.

    Thanks

    Gibbs

  • Hi Tanmay
    Have any update for this UFS0_RSTN working incorrect issue?


    BR
    Jay