Jump to content
  • 0

SREC SPI Bootloader is Very Slow


bhall

Question

Hello,

I am using Vivado 2018.3 and a XC7A100T Artix-7. My project includes a Microblaze and an AXI QSPI controller. I am attempting to boot an SREC from Spansion Flash (S25FL256L) using the SREC SPI Bootloader. My SREC file size is around 830 KB. It takes over 2 minutes for the bootloader to finish loading the SREC. I commented out the VERBOSE definition, so nothing is being printed. Stack and heap sizes for the Bootloader are 2KB.

Does anyone have an idea as to how can I reduce this time?

I have tried increasing the clock frequency that is connected to my AXI QSPI controller (ext_spi_clk), but this did not help. I have also tried changing the bitstream configuration settings, but apparently that is for the initial FPGA configuration. I even tried an ELF bootloader found on Github, but it gave an error saying that my ELF header is invalid. 

Has anyone found a solution to this problem? I have seen several posts on these forums regarding this, but have found no clear solutions... 

Thanks in advance,

Brad

Link to comment
Share on other sites

8 answers to this question

Recommended Posts

Thanks @kwilber for this information. I was familiar with the tutorial you shared, but I hadn't tried changing compiler optimization flags, as they suggested. That decreased my file sizes, making it finish more quickly. It was still too slow for me, probably because my .srec is still pretty large. I didn't try the steps in the second link you shared, but I appreciate your assistance. 

(For others with a similar problem):

Instead of using the SREC SPI bootloader, I used this ELF Bootloader. It worked a lot better for me, but I did have to change a couple of the definitions in eb-config.h. I changed SPI_READ_OPERATION to 0x3 and SPI_FLASH_NDUMMY_BYTES to 0 as specified by my flash memory's datasheet. I also changed ELF_IMAGE_BASEADDR to fit my storage needs. It boots my .elf in about 3 seconds, compared to the SREC bootloader which took ~2.5 minutes. Maybe I had something configured incorrectly for that one...

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...