Hi,
I am working on AM335x based product development where the boot time of the system is very stringent. We expect the system to boot and stabilize in 500 msec. we need 150 msec to stabilize the control loop once the main code runs and left with 350 msec for system boot. We are also targeting to boot using SD card (This is also one of the critical requirement).
I tried the starterware boot loader, and figured out that, it takes around 800 msec to copy a application binary of size 84 KB from SD card to DDR3. So in the existing boot loader code in starteware the through put is around 100KB/sec. This is very slow and it doesn't match our requirement. I studied the TI Technical reference manual where it is mentioned that the SD card data transfer rate is 24MB/sec and also tried the example code /beaglebone/hs_mmcsd/. I am able to get very good SD card through put here, it just took 10msec to copy 100KB binary from SD card to DDR3.
I tried to understand the difference between the boot loader SD card copy and hs_mmcsd example SD card copy to DDR3 and found the following differences.
1.In the boot loader code, the data is read from SD card into IRAM in chunks of 512 bytes and memory copied to DDR3 from IRAM, where as in hs_mmscd example, the data is read from SD card directly into DDR3 of buffer size 64k.
2. The boot loader uses polling mode where as the hs_mmcsd code use EDMA for data read from SD card to DDR
3. MMU/cache not enabled in boot loader but enabled in hs_mmcsd example.
Because of the above differences, the boot loader SD card read to copy application image to DDR3 was very slow.
I tried to port the hs_mmscsd code into boot loader and tried to run and at this point, it the boot loader hangs/stops working in the EDMA transfer code.The same code works fine in hs_mmcsd example but fails in EDMA transfer code in the boot loader. I also tried /example/beaglebone/edma example code to run in the boot loader but it doesn't work (Again hangs in EDMA transfer)
1.Now my question is why EDMA data transfer ( from SD card to IRAM or IRAM to IRAM or UART to IRAM ) doesn't work in the boot loader? Can EDMA be used in boot loader or not? please suggest
2.If i enable MMU/Cache in the boot loader, it hangs? Why can't i enable MMU/Cache in boot loader?
3. How much time does the ROM boot code takes to run till the point MLO code starts running?
4. Finally is it possible to have 350 msec boot time using TI starterware boot loader booting from SD card ? if yes, how to achieve this?
Please give your inputs?
Regards,
Seetaram