cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Highlighted
Observer
Observer
921 Views
Registered: ‎11-05-2018

bootgen - "load" and "startup" bif attributes don't appear to have any effect on output file

Jump to solution

The two bif files:

the_ROM_image:{
		[bootloader, destination_cpu=a53-0] zynqmp_fsbl.elf
		[destination_cpu = a53-1]dummy1.elf
		[destination_cpu = a53-2]dummy2.elf
}

and

the_ROM_image:{
		[bootloader, destination_cpu=a53-0] zynqmp_fsbl.elf
		[destination_cpu = a53-1]dummy1.elf
		[destination_cpu = a53-2, load=0xa0000, startup=0xb0000]dummy2.elf
}

Generate two .bin files with the same sha256 sum (i.e, identical files) when using the command:

`bootgen -image dummy.bif -arch zynqmp -o dummy.bin -w o` 

Why is this?
I can get a file with a different sum by changing other attributes, or order.

My ultimate goal is just to get those two elf files to run a the same time on two separate cores. But instead, I believe those two elf files load into the same RAM address, and both cores run the second elf file at the same time. So, I tried to change to load address, but to no avail. 

I'm using the tools from Xilinx SDK 2018.3

0 Kudos
1 Solution

Accepted Solutions
Highlighted
Moderator
Moderator
803 Views
Registered: ‎03-19-2014

Load does not apply to elf files -- those will be loaded into the location in the linker.   If you want your elf to be at a different location, change the lscript.ld to the desired location.   The load attribute applies to other binary files, .bin, dtb, .gz, etc.

-------------------------------------------------------------------------
Don’t forget to reply, kudo, and accept as solution.
-------------------------------------------------------------------------

View solution in original post

4 Replies
Highlighted
Xilinx Employee
Xilinx Employee
886 Views
Registered: ‎01-15-2014

Hello,

Ideally that should not happen. You should get different load address and execution address for the dummy2.elf.

I tried running a similar test case at my end. I do see the differences between the two bins generated.

I'm not sure what could be the reason for not generating proper bin with new load/startup. Can you share your elfs, so that I can debug more?

diff.png
0 Kudos
Highlighted
Observer
Observer
809 Views
Registered: ‎11-05-2018

Hi Pmallad,

For some reason my response got deleted.

I attached the test files. When running make.bat on Windows 10, bootgen created two identical bin files from each of the bif files:

a93b2dad454fd0d816d74c2bf632bfc01dc79ae2c49188308be6afb4ff4e571e bin1.bin
a93b2dad454fd0d816d74c2bf632bfc01dc79ae2c49188308be6afb4ff4e571e bin2.bin

I tried doing the same thing on Linux, and ended up with the same results as I did on Windows 10. 

I also found that changing the startup or load address of the FSBL does have an effect on the bin files, but that is not what I want to do.

0 Kudos
Highlighted
Observer
Observer
840 Views
Registered: ‎11-05-2018

Hi pmallad,

I was trying to respond earlier, but Xilinx kept removing my replies.

Here's a link to the zip: https://butterypumpkin.com:8443/forums.xilinx/bootgen_test.zip

When I run make.bat in this folder, which creates a bin from each of the bif files, it generates two identical bin files:

a93b2dad454fd0d816d74c2bf632bfc01dc79ae2c49188308be6afb4ff4e571e *bin1.bin
a93b2dad454fd0d816d74c2bf632bfc01dc79ae2c49188308be6afb4ff4e571e *bin2.bin 

Elf files are all different:

6a4f7e9c70a4ba6cb4c779f1160eef133714e4afc3ddb34c1eb994376e3cb3a8 *dummy1.elf c34f1fd5e3d4e8c336199cd27686d26cddd5ebb4be6691cc85544075335b8ebd *dummy2.elf 50b84fca1cc13c4b93db5c02a5df4175a382800d894640d2820b6a9af6fd0642 *zynqmp_fsbl.elf

I also tried this on Linux(Ubuntu 18.04/Xilinx SDK 2018.3), and ended up with the same results as Windows 10

Changing the load or startup address of the FSBL *does* have an effect. But that's not what I want to do

Thank you

0 Kudos
Highlighted
Moderator
Moderator
804 Views
Registered: ‎03-19-2014

Load does not apply to elf files -- those will be loaded into the location in the linker.   If you want your elf to be at a different location, change the lscript.ld to the desired location.   The load attribute applies to other binary files, .bin, dtb, .gz, etc.

-------------------------------------------------------------------------
Don’t forget to reply, kudo, and accept as solution.
-------------------------------------------------------------------------

View solution in original post