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.

SK-AM68: How to flash OSPI for SK-AM68 including ATF-OPTEE

Part Number: SK-AM68

Currently getting an error in u-boot after following guide to run linux from OSPI.

I loaded 4 files to locations

=> fatload mmc 1 ${loadaddr} nor_spi_patterns.bin;
128 bytes read in 2 ms (62.5 KiB/s)
=> sf update $loadaddr 0x3fC0000 $filesize;
device 0 offset 0x3fc0000, size 0x80
128 bytes written, 0 bytes skipped in 1.38s, speed 125 B/s
=> fatload mmc 1 ${loadaddr} tiboot3.bin; sf update $loadaddr 0x0 $filesize;
484274 bytes read in 8 ms (57.7 MiB/s)
device 0 offset 0x0, size 0x763b2
484274 bytes written, 0 bytes skipped in 2.958s, speed 167476 B/s
=> fatload mmc 1 ${loadaddr} tispl.bin; sf update $loadaddr 0x100000 $filesize;
1047763 bytes read in 14 ms (71.4 MiB/s)
device 0 offset 0x100000, size 0xffcd3
1047763 bytes written, 0 bytes skipped in 5.894s, speed 181941 B/s
=> fatload mmc 1 ${loadaddr} u-boot.img; sf update $loadaddr 0x280000 $filesize;
1328515 bytes read in 17 ms (74.5 MiB/s)
device 0 offset 0x280000, size 0x144583
1328515 bytes written, 0 bytes skipped in 8.390s, speed 162087 B/s
=> fatload mmc 1 ${loadaddr} uEnv.txt; sf update $loadaddr 0x680000 $filesize;
1028 bytes read in 2 ms (502 KiB/s)
device 0 offset 0x680000, size 0x404
1028 bytes written, 0 bytes skipped in 1.338s, speed 784 B/s


U-Boot SPL 2023.04-gb0d717b732 (Dec 06 2023 - 15:11:45 +0000)
SYSFW ABI: 3.1 (firmware rev 0x0009 '9.1.2--v09.01.02 (Kool Koala)')
i2c_write: error waiting for data ACK (status=0x116)
read error from device: 41c667c8 register: x!
EEPROM not available at 0x50, trying to read at 0x51
SPL initial stack usage: 13432 bytes
Trying to boot from SPI
alloc space exhausted
Could not get FIT buffer of 1328516 bytes
check CONFIG_SYS_SPL_MALLOC_SIZE
Loading Environment from nowhere... OK
Loading rproc fw image from device 3 not supported!
Starting ATF on ARM64 core...

ti_sci system-controller@44083000: ti_sci_get_response: Message receive failed. ret = -110
ti_sci system-controller@44083000: Message not acknowledgedFailed to put device 295 (-19)

### ERROR ### Please RESET the board ###

I found the post saying I could recompile u-boot with:

CONFIG_TI_SECURE_DEVICE=n

CONFIG_SPL_RAW_IMAGE_SUPPORT=y

But I'm thinking I'd rather keep the secure device enables, and load the ATF properly?

Is ATF loading, but I'm missing something else on the OSPI?

I also tried loading the ATF image from the SDK, atf_optee.appimage.signed, to address 0x1c0000 as outlined here: software-dl.ti.com/.../demo_boot_app_mcu_rtos_top.html