linux: gzip 64bit kernels on RPi

RPi firmware since around September 2020 is able to decompress
gzipped kernels prior to handing over control. Arm64 kernels do not
do self-decompression, so use the firmware's capability.

Signed-off-by: Ian Leonard <antonlacon@gmail.com>
This commit is contained in:
Ian Leonard 2022-06-20 19:32:40 +00:00
parent e8c865d966
commit 4ced62d585

View File

@ -282,6 +282,12 @@ makeinstall_target() {
fi fi
done done
elif [ "${BOOTLOADER}" = "bcm2835-bootloader" ]; then elif [ "${BOOTLOADER}" = "bcm2835-bootloader" ]; then
# RPi firmware will decompress gzipped kernels prior to booting
if [ "${TARGET_KERNEL_ARCH}" = "arm64" ]; then
pigz --best --force ${INSTALL}/.image/${KERNEL_TARGET}
mv ${INSTALL}/.image/${KERNEL_TARGET}.gz ${INSTALL}/.image/${KERNEL_TARGET}
fi
mkdir -p ${INSTALL}/usr/share/bootloader/overlays mkdir -p ${INSTALL}/usr/share/bootloader/overlays
# install platform dtbs, but remove upstream kernel dtbs (i.e. without downstream # install platform dtbs, but remove upstream kernel dtbs (i.e. without downstream