- First we need to re-create Image.gz from the
vmlinuz-6.12.107+deb13-arm64 file
- Get the extract-vmlinux
script from the linux-kernel sources and use
it on the vmlinuz and then recompress
./extract-vmlinux vmlinuz-6.12.107+deb13-arm64 > vmlinux
gzip -k -9 vmlinux -c > Image.gz
- Next append the device tree file to the end
cat Image.gz apq8016-sbc.dtb > Image.gz+dtb
- Then create the boot image
mkbootimg --kernel Image.gz+dtb \
--ramdisk initrd.img-6.12.107+deb13-arm64 \
--output boot-db410c.img \
--pagesize 2048 \
--base 0x80000000 \
--cmdline "root=PARTLABEL=rootfs console=ttyMSM0,115200n8"