# PetaLinux 2020.1

Tags: xilinx linux

PetaLinux 2020.1 removes many of the Xilinx specific extensions to U-Boot such as the netboot and update_boot convenience functions. In earlier versions of U-Boot with PetaLinux, the process of booting via TFTP and NFS was to simply start U-Boot the first time and then run

ZynqMP> setenv bootcmd 'run netboot'
ZynqMP> saveenv
ZynqMP> boot


This would ensure that U-Boot would run the netboot function by default, which loads the image.ub file over TFTP and then boots the kernel.

The netboot command has been removed in U-Boot as of PL 2020.1 in favor of the standard U-Boot Distro Boot. This is a good long-term change as it removes dependence on Xilinx-specific modifications, but it does require immediate modifications that are not well documented on Xilinx's part.

For one thing, even if you specify that you want to use NFS as your root filesystem in petalinux-config, the generated pxelinux.cfg/default file will still specify an init ramdisk (initrd) to use when booting. Ideally, the kernel should mount the network filesystem over the initrd as part of the init process, but this doesn't seem to be happening. The method I've used to get around this is to create the following file at project-spec/meta-user/recipes-bsp/u-boot/u-boot-zynq-scr/pxeboot.pxe:

LABEL Linux
KERNEL @@KERNEL_IMAGETYPE@@
FDT @@DEVICE_TREE_NAME@@


This is almost the same as the default pxeboot.pxe in the meta-xilinx layer, the only difference being the removal of the INITRD line. This will ensure that subsequent runs of petalinux-build will omit the initrd from the generated pxelinux.cfg/default file.

For now, it seems that many of the settings in petalinux-config do not do what one might expect. For example, setting the image file name to image.ub doesn't seem to do anything, as all of the default scripts use Image by default (for the Zynq MP, other boards/devices will vary obviously).