Part Number: PROCESSOR-SDK-AM64X
Other Parts Discussed in Thread: TMDS64EVM
Tool/software:
AM64X OSPI-NOR Flash and Kernel Booting Issues
I am currently working with two boards, a tmds64evm (proc101c) and a sk-am64 (proc10e3). I have successfully flashed tiboot3.bin, tispl.bin, and u-boot.img using UART, TFTP, and DFU, and confirmed that the boards can boot in OSPI mode.
My ultimate goal is to boot the kernel image file from the OSPI-NOR flash.
Problem 1: OSPI MTD Re-partitioning and saveenv Issue
I am trying to follow the steps in this link: https://dev.ti.com/tirex/explore/node?node=A__ARACMGmwZUkJurQKuv0ezw__AM64-ACADEMY__WI1KRXP__LATEST
In the OSPI MTD re-partitions section, re-partitioning does not work. My result screen is as follows:
=> setenv mtdparts mtdparts=fc40000.spi.0:512k(ospi.tiboot3),2m(ospi.tispl),4m(ospi.u-boot),256k(ospi.env),256k(ospi.env.backup),1m(ospi.dtb),20m@8m(ospi.kernel),36608k(ospi.rootfs),256k(ospi.phypattern)
=> mtd list
Could not find a valid device for fc40000.spi.0
List of MTD devices:
* nor0
- device: flash@0
- parent: spi@fc40000
- driver: jedec_spi_nor
- path: /bus@f4000/bus@fc00000/spi@fc40000/flash@0
- type: NOR flash
- block size: 0x40000 bytes
- min I/O: 0x10 bytes
- 0x000000000000-0x000004000000 : "nor0"
- 0x000000000000-0x000000100000 : "ospi.tiboot3"
- 0x000000100000-0x000000300000 : "ospi.tispl"
- 0x000000300000-0x000000700000 : "ospi.u-boot"
- 0x000000700000-0x000000740000 : "ospi.env"
- 0x000000740000-0x000000780000 : "ospi.env.backup"
- 0x000000800000-0x000003fc0000 : "ospi.rootfs"
- 0x000003fc0000-0x000004000000 : "ospi.phypattern"
When I use the command script as follows:
setenv mtdparts mtdparts=nor0:512k(ospi.tiboot3),2m(ospi.tispl),4m(ospi.u-boot),256k(ospi.env),256k(ospi.env.backup),1m(ospi.dtb),20m@8m(ospi.kernel),36608k(ospi.rootfs),256k(ospi.phypattern)
Re-partitioning works, and my result screen is as follows:
=> setenv mtdparts mtdparts=nor0:512k(ospi.tiboot3),2m(ospi.tispl),4m(ospi.u-boot),256k(ospi.env),256k(ospi.env.backup),1m(ospi.dtb),20m@8m(ospi.kernel),36608k(ospi.rootfs),256k(ospi.phypattern)
=> mtd list
SF: Detected s28hs512t with page size 256 Bytes, erase size 256 KiB, total 64 MiB
List of MTD devices:
* nor0
- device: flash@0
- parent: spi@fc40000
- driver: jedec_spi_nor
- path: /bus@f4000/bus@fc00000/spi@fc40000/flash@0
- type: NOR flash
- block size: 0x40000 bytes
- min I/O: 0x10 bytes
- 0x000000000000-0x000004000000 : "nor0"
- 0x000000000000-0x000000080000 : "ospi.tiboot3"
- 0x000000080000-0x000000280000 : "ospi.tispl"
- 0x000000280000-0x000000680000 : "ospi.u-boot"
- 0x000000680000-0x0000006c0000 : "ospi.env"
- 0x0000006c0000-0x000000700000 : "ospi.env.backup"
- 0x000000700000-0x000000800000 : "ospi.dtb"
- 0x000000800000-0x000001c00000 : "ospi.kernel"
- 0x000001c00000-0x000003fc0000 : "ospi.rootfs"
- 0x000003fc0000-0x000004000000 : "ospi.phypattern"
However, saveenv does not work. The following screen is displayed:
=> saveenv
Unknown command 'saveenv' - try 'help'
And after rebooting, the partition contents revert to the initial state.
My questions are:
- Is it possible to boot the kernel by placing the Image and .dtb files inside the rootfs partition without re-partitioning?
- Is re-partitioning absolutely necessary to boot the kernel via OSPI-NOR?
Problem 2: Yocto Build Failures
I believe the required rootfs is the tisdk-tiny-initramfs image, and I am trying to build it using the command MACHINE=am64xx-evm bitbake -k tisdk-tiny-image.
Despite having a powerful PC with sufficient specifications, the build does not succeed. I have also selected "no" for the Dash-related message. The build takes several hours and ultimately fails with numerous errors.
Could you please provide a solution for this issue?
Problem 3: General Guidance
I am new to Linux, so this process has been very difficult and challenging. My final goal is to boot the kernel from the flash without an SD card, just as it would boot from an SD card.
- Based on the issues I have described, have I misunderstood anything or taken a wrong approach?
- If so, could you please tell me about any alternative methods?
I would be very grateful for any help.