The earlier example highlighted creation of the Linux Images and Boot images to boot from an SD card. This section explains the configuration of PetaLinux to generate Linux images for QSPI flash. For more information about the dependencies for PetaLinux, see the PetaLinux Tools Documentation: Reference Guide (UG1144).
Before starting this example, create a backup of the boot images created for SD card setup using the following commands:
$ cd <Petalinux-project-path>/xilinx-zcu102-2022.2/images/linux/ $ mkdir sd_boot $ cp image.ub sd_boot/ $ cp u-boot.elf sd_boot/ $ cp BOOT.BIN sd_boot/
Change the directory to the PetaLinux project root directory:
$ cd <Petalinux-project-path>/xilinx-zcu102-2022.2
Launch the top-level system configuration menu:
$ petalinux-config
The Configuration wizard opens.
Select Subsystem AUTO Hardware Settings.
Under the advanced bootable images storage settings, do the following:
Select boot image settings.
Select image storage media.
Select primary flash as the boot device.
Under the advanced bootable images storage settings submenu, do the following:
Select kernel image settings.
Select image storage media.
Select primary flash as the storage device.
One level above (under Subsystem AUTO Hardware Settings) do the following:
Select Flash Settings and notice the entries listed in the partition table.
Note
Some memory (0x1E00000 + 0x40000) is set aside for initial boot partitions and U-Boot settings. These values can be modified on need basis.
Based on this, the offset for Linux images is calculated as 0x1E40000 in the QSPI Flash device. This will be used while creating the boot image for QSPI Boot-mode.
The following steps set the Linux system memory size to about 1.79 GB.
Under Subsystem AUTO Hardware Settings, do the following
Select Memory Settings.
Set System Memory Size to
0x6FFFFFFF
.
Save the configuration settings and exit the Configuration wizard.
Rebuild using the
petalinux-build
command.Take a backup of u-boot.elf and the other images. These will be used when creating boot images.
Note
For more information, refer to the PetaLinux Tools Documentation: Reference Guide (UG1144).