MKIMAGE(1) | General Commands Manual | MKIMAGE(1) |
mkimage - Generate image for U-Boot
mkimage -l [uimage file name]
mkimage [options] -f [image tree source file] [uimage file name]
mkimage [options] -F [uimage file name]
mkimage [options] (legacy mode)
The mkimage command is used to create images for use with the U-Boot boot loader. These images can contain the linux kernel, device tree blob, root file system image, firmware images etc., either separate or combined.
mkimage supports two different formats:
The old legacy image format concatenates the individual parts (for example, kernel image, device tree blob and ramdisk image) and adds a 64 bytes header containing information about target architecture, operating system, image type, compression method, entry points, time stamp, checksums, etc.
The new FIT (Flattened Image Tree) format allows for more flexibility in handling images of various types and also enhances integrity protection of images with stronger checksums. It also supports verified boot.
List image information:
Create old legacy image:
Create FIT image:
This can be automatically generated for some simple cases. Use "-f auto" for this. In that case the arguments -d, -A, -O, -T, -C, -a and -e are used to specify the image to include in the FIT and its attributes. No .its file is required.
List image information:
mkimage -l uImage
Create legacy image with compressed PowerPC Linux kernel:
mkimage -A powerpc -O linux -T kernel -C gzip
-a 0 -e 0 -n Linux -d vmlinux.gz uImage
Create FIT image with compressed PowerPC Linux kernel:
mkimage -f kernel.its kernel.itb
Create FIT image with compressed kernel and sign it with keys in the /public/signing-keys directory. Add corresponding public keys into u-boot.dtb, skipping those for which keys cannot be found. Also add a comment.
mkimage -f kernel.its -k /public/signing-keys -K u-boot.dtb
-c "Kernel 3.8 image for production devices" kernel.itb
Update an existing FIT image, signing it with additional keys. Add corresponding public keys into u-boot.dtb. This will resign all images with keys that are available in the new directory. Images that request signing with unavailable keys are skipped.
mkimage -F -k /secret/signing-keys -K u-boot.dtb
-c "Kernel 3.8 image for production devices" kernel.itb
Create a FIT image containing a kernel, using automatic mode. No .its file is required.
mkimage -f auto -A arm -O linux -T kernel -C none -a 43e00000 -e 0
-c "Kernel 4.4 image for production devices" -d vmlinuz kernel.itb
Create a FIT image containing a kernel and some device tree files, using automatic mode. No .its file is required.
mkimage -f auto -A arm -O linux -T kernel -C none -a 43e00000 -e 0
-c "Kernel 4.4 image for production devices" -d vmlinuz -b /path/to/rk3288-firefly.dtb -b /path/to/rk3288-jerry.dtb kernel.itb
http://www.denx.de/wiki/U-Boot/WebHome
This manual page was written by Nobuhiro Iwamatsu <iwamatsu@nigauri.org> and Wolfgang Denk <wd@denx.de>. It was updated for image signing by Simon Glass <sjg@chromium.org>.
2010-05-16 |