UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Visitor mberemand
Visitor
68 Views
Registered: ‎10-22-2018

Which kernel address setting does what?

I am attempting to boot Petalinux where everything is stored in a single BOOT.bin file, constructed from this .bif file.

all:
{
   [pskfile] RSAPrimarySecretKey.pem
   [sskfile] RSASecondarySecretKey.pem 
   [bootloader, authentication=rsa] test_secure_fsbl.elf
   [authentication=rsa] download.bit
   [authentication=rsa] u-boot.elf
   [authentication=rsa, partition_owner=uboot, load=0x6000000] image.ub
}

The kernel address can be specified in petalinux-config under Subsystem AUTO Hardware Settings --> Memory Settings. I can specify the load address for image.ub in the .bif file as you see I've done. Should these values be the same? What does each one actually do? I've tried several combinations of addresses but I still don't understand what items are loaded into memory, where they are loaded into memory, and when they are loaded into memory. The official documentation does not say anything about this that I can find.

My current (and probably wrong) assumption is this:

load mmc 0 0x100000 BOOT.bin

puts the FSBL and U-boot consecutively in memory starting at 0x100000 and puts image.ub at address 0x6000000 (the address specified in the .bif). After the zynqrsa authentication, I run

bootm 0x6000000

which should put the device tree, kernel, and rootfs (from image.ub) in other locations in memory and then start the kernel. If I've set the kernel address in petalinux-config to 0x20000000, it should load the kernel there. But I don't see any place to specify the load address for the other two.

Using Zynq ZC702 board and 2017.2 version of all Xilinx tools.

Tags (2)
0 Kudos
2 Replies
Xilinx Employee
Xilinx Employee
29 Views
Registered: ‎10-11-2011

Re: Which kernel address setting does what?

You should be storing the BOOT.bin in QSPI flash at address 0x0 for the monolithic image.

If you prefer SD boot I suggest to remove image.ub from BOOT.bin and have u-boot access image.ub as file in the FAT32 partition of the SD card.

Also, this might be a better question for the Embedded OS experts.

0 Kudos
Visitor mberemand
Visitor
18 Views
Registered: ‎10-22-2018

Re: Which kernel address setting does what?

@denistI've not been using flash for anything but uEnv variables. After some more experimentation I was able to get everything working as it should with the address in petalinux-config left at 0x0 and the load address for image.ub set to 0x3000000, though I'm still not sure how it determines where the device tree and rootfs get loaded.

I assume the reason you recommend I separate image.ub from BOOT.bin is so that making changes to the components of image.ub won't require me to rebuild BOOT.bin. If I do that, how do I encrypt and sign image.ub such that zynqrsa recognizes it? I only know how to specify this in the .bif file and let bootgen take care of it.

0 Kudos