User`s guide
Secure Boot with i.MX28 HAB Version 4, Rev. 1
18 Freescale Semiconductor
Signed U-Boot and Linux kernel example
Figure 6. Players in the generation of signed boot image
Figure 6 above shows the tools and steps for code signing a bootable image for i.MX28 processor.
The prerequisites are:
• Linux machine set up to perform builds of the i.MX28 BSP
• Freescale CST
• Freescale elftosb tool
• Objcopy utility
Here are the steps to generate signed u-boot SB file:
1. The source code changes described in section 3.3 are required for power_prep, boot_prep and
u-boot.
2. Build the three ELF files for power_prep, boot_prep and u-boot. Follow the instructions in the
BSP guide on how to build imx-bootlets and u-boot.
3. Next step is to generate HAB data for the three ELF files using the Freescale code signing tool.
The ELF files should be first converted to binary using the GNU objcopy command.
objcopy -I elf32-little -O binary –-gap-fill 0xFF power_prep power_prep.bin
objcopy -I elf32-little -O binary –-gap-fill 0xFF boot_prep boot_prep.bin
objcopy -I elf32-little -O binary -–gap-fill 0xFF u-boot u-boot.bin
Also using objcopy command add padding to the binary for sufficient length to allow future
expansion of the code
objcopy -I binary -O binary –-gap-fill 0xFF –-pad-to 0x2A000 u-boot.bin
u-boot_pad.bin










