Hi, I want to load my own FSBL into L2LIM to test my UART driver. I tried the following:
I created a partition with the type 5B193300-FC78-40CD-8002-E86C45580B47 (FSBL) after the bbl partition (Thanks for leaving some space!). I made it 4MiB large.
I set MSEL to 11 (0b1011)
I turned on the board
The result was that ROM1/ZSBL printed “Error 0x0100000000000001”. What does this error number mean?
The manual says “Then, the entire contents of this partition, the FSBL, are
downloaded into the L2 LIM at address 0x0800_0000.” How large may an FSBL partition be? Because it sounds like L2LIM will simply be overflowed if the partition is too large.
// Error codes are formatted as follows:
// [63:60] [59:56] [55:0]
// bootstage trap errorcode
// If trap == 1, then errorcode is actually the mcause register with the
// interrupt bit shifted to bit 55.
Some what related idea: For recovery (and, in some cases, development) purposes, it would be interesting to have an (official) SD-card image that contains not only bbl+Linux, but also FSBL, so the HiFive Unleashed could be booted in boot mode MSEL=11 without relying on the content of the SPI flash.
Where do I get FSBL? Should I extract it from SPI flash?
I tried that with FSBL 2018-03-20 as shipped on SPI flash a week ago, and it didn’t work (ZSBL printed an error code), but maybe it was an error on my part (partition to large, maybe).
The gpt image that get’s flashed includes a partition with a legal FSBL. I usually just create a 1MB partition on my SD card (with the correct GUID code) and then dd the fsbl binary into it.
I stumbled onto that issue and have been working on building that repo but I’m having some trouble, do you know if there are any fsbl.bin files available online? We just need an FSBL for running some tests.
I’m a toolchain guy. I’m not an expert in this area.
Most of the people that want to build FSBL are doing boot loader work, and know how to debug boot loader problems. It seems odd that someone would request it for any other reason.