I have created a U-Boot bootloader and Linux operating system using Buildroot
git clone git://git.buildroot.net/buildroot cd buildroot make zynq_zed_defconfig make
This was successful, and I am able to boot Linux on my ZedBoard using a microSD as the boot device and using the BOOT.BIN that buildroot/U-Boot created from the U-Boot SPL binary.
The latest buildroot version uses U-Boot's mkimage to create a Zynq-compatible first stage bootloader from the U-Boot SPL binary (u-boot-spl.bin). I think this used to require a special python tool, but now mkimage has been given the ability to generate this binary itself.
However, I would like to experiment with the Xilinx bootgen tool instead of mkimage. Unfortunately, when I use bootgen, the resulting BOOT.BIN does not work.
I am using a BIF file (boot.bif) as follows:
image: { [bootloader] u-boot-spl.bin }
I am invoking bootgen like this:
bootgen -arch zynq -image boot.bif -o BOOT.BIN
The resulting BOOT.BIN file is 90600 bytes, which is larger than what I create using mkimage (86952 bytes):
$ mkimage -A arm -T zynqimage -d u-boot-spl.bin BOOT.BIN Image Type : Xilinx Zynq Boot Image support Image Offset : 0x000008c0 Image Size : 86952 bytes (86952 bytes packed) Image Load : 0x00000000 User Field : 0x00000000 Checksum : 0xfd17ac31
Can anyone tell me how to get bootgen to generate a bootable binary from my u-boot-spl.bin? I noticed that if I specify zynqmp instead of zynq for -arch, the file size is exactly 256 bytes larger, but it still does not work.
Thanks,
Gregg