Hi there,
I posted this in another forum, but I'm not sure it was the right place. I've been trying to get a Microzed z7020 board to work with the latest version of Petalinux 2021.2. Currently I am using 2018.2 without issue. I am able to perform the following to create a new setup without issue, just as before:
petalinux-create -t project --template zynq --name mz7020_qspi
petalinux-config --get-hw-description [path to .xsa file here]
However, when I try to build with:
petalinux-package --boot --u-boot --kernel --fpga
I always get the following output:
[INFO] Sourcing buildtools
INFO: Getting system flash information...
INFO: File in BOOT BIN: "/home/james/Download/petalinux/mz7020_qspi/images/linux/zynq_fsbl.elf"
INFO: File in BOOT BIN: "/home/james/Download/petalinux/mz7020_qspi/project-spec-hw-description/design_1_wrapper.bit"
INFO: File in BOOT BIN: "/home/james/Download/petalinux/mz7020_qspi/images/linux/u-boot.elf"
INFO: File in BOOT BIN: "/home/james/Download/petalinux/mz7020_qspi/images/linux/system.dtb"
INFO: File in BOOT BIN: "/home/james/Download/petalinux/mz7020_qspi/images/linux/boot.scr"
INFO: File in BOOT BIN: "/home/james/Download/petalinux/mz7020_qspi/images/linux/image.ub"
INFO: Generating zynq binary package BOOT.BIN...
****** Xilinx Bootgen v2021.2
**** Build date : Sep 30 2021-06:08:18
** Copyright 1986-2021 Xilinx, Inc. All Rights Reserved.
[ERROR] : Section image.ub.0.offset of 0x520000 overlaps with prior section end address of FC0AC0
ERROR: Fail to create BOOT image
I've seen elsewhere that this could be related to the size of the boot partition, so if I run petalinux-config, then go to:
Subsystem AUTO Hardware Settings -> Flash Settings
I change:
(boot) name
(0x500000) size
*** partition 1 ***
(bootenv) name
(0x20000) size
*** partition 2 ***
(kernel) name
(0xA80000) size
*** partition 3 ***
(spare) name
(0x0) size
*** partition 4 ***
() name
on the following lines to:
(boot) name
(0x1000000) size
to increase the size of said partition. Then I run a petalinux-build and try again with petalinux-package without issue.
At that point, the issue seems to be that the BOOT.bin is too large to flash onto the onboard memory of the Microzed. When I attempt to flash the image within the Vitis environment (formerly Xilinx SDK), I get the following:
Performing Erase Operation...
sf erase 0 1CA0000
ERROR: attempting erase past flash size (0x1000000)
Zynq> f erase 0 1CA0000
Erase Operation failed.
INFO: [Xicom 50-44] Elapsed time = 0 sec.
ERROR: Flash Operation Failed
I use flash type qspi_single, as it seems to be the only type that is fully compatible. If I try qspi_dual_parallel, qspi_dual_stacked, or nor, it seems to flash without issue, but then once I try to bootup the Microzed it either doesn't at all or comes back with:
*** Warning - bad CRC, using default environment
In: serial@e0001000
Out: serial@e0001000
Err: serial@e0001000
Net:
ZYNQ GEM: e000b000, mdio bus e000b000, phyaddr -1, interface rgmii-id
eth0: ethernet@e000b000
Hit any key to stop autoboot: 0
SF: Detected s25fl128s with page size 256 Bytes, erase size 64 KiB, total 16 MiB
device 0 offset 0xfc0000, size 0x40000
SF: 262144 bytes @ 0xfc0000 Read: OK
QSPI: Trying to boot script at 3000000
## Executing script at 03000000
Trying to load boot images from qspi
SF: Detected s25fl128s with page size 256 Bytes, erase size 64 KiB, total 16 MiB
Offset exceeds device limit
sf - SPI flash sub-system
...
...
I thought that there was 64mb of flash at least, but this seems to act more like 16mb. I could definitely be wrong about the storage size. Am I possibly misconfiguring anything obvious and/or flashing it the wrong way? Before the change to distro-boot with 2020.1 apparently, it would work flawlessly with 2018.2. Any help would be greatly appreciated and I can lookup anything that would be helpful.