cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
kysontan
Observer
Observer
545 Views
Registered: ‎04-30-2019

booting .elf at certain address

Hi,

I am working with ZCU102 and I was able to program .mcs (contains FSBL.elf, wrapper.bit, and Hello.elf) to flash.

I have Hello2.elf located in memory at address say 0x1000. How (what functions etc) can I modify the codes in Hello.c such that it can boot Hello2.elf at 0x1000? My goal is that I can just modify the codes in Hello2.elf and overwrite it instead of going through the re-making image and re-programing flash process.

Thanks

0 Kudos
6 Replies
savula
Moderator
Moderator
498 Views
Registered: ‎10-30-2017

Hi @kysontan ,

 

You can check with the multiboot for the same. Create different images and program them on flash and perfrom the multiboot when you want.

Please check the multiboot on ZynqMPSoC here:

https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/18842403/Zynq+Ultrascale+MPSoC+Multiboot+and+Fallback

 

Best Regards,
Srikanth
----------------------------------------------------------------------------------------------
Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.

Give Kudos to a post which you think is helpful and reply oriented.

0 Kudos
kysontan
Observer
Observer
485 Views
Registered: ‎04-30-2019

but i dont want to put all the .elf files into an image which gets programmed to flash

i want to be able to only program Hello.elf to flash only once, but have Hello.elf to boot whatever .elf at address 0x1000. This way i can modify the .elf at 0x1000 however i want without modifying Hello.elf and/or the image that contains it

0 Kudos
savula
Moderator
Moderator
465 Views
Registered: ‎10-30-2017

Hi @kysontan ,

If your first elf is at address 0x1000 and if you want to over write this elf with other new one, it may not work. Because the bootloader have the elf size and check sum. if anything is not matching with original one when you change the elf at address 0x1000 then bootloader fails to load elf. the new elf may have different size and checksum.

 

Best Regards,
Srikanth
----------------------------------------------------------------------------------------------
Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.

Give Kudos to a post which you think is helpful and reply oriented.

0 Kudos
kysontan
Observer
Observer
453 Views
Registered: ‎04-30-2019

so my image has FSBL and 1.elf, my question was if there is a way of me coding 1.elf so that it can boot 2.elf at 0x1000

and later i can overwrite 2.elf with 3.elf without modifying the image (contains FSBL and 1.elf)

0 Kudos
stephenm
Xilinx Employee
Xilinx Employee
440 Views
Registered: ‎09-12-2007

You need to do this in the linker script. 

0 Kudos
kysontan
Observer
Observer
428 Views
Registered: ‎04-30-2019

Capture1.PNGcan you give me more details what i need to do for achieving it? or documents that i can read about this?

here is what i see after i created a linker script for HelloWorld.elf. How do i know which name is for what? And the meanings of the section names?

thanks

 

Capture1.PNG
0 Kudos