varigit/meta-variscite-fslc

Extend u-boot recipe for secure-boot

Closed this issue · 4 comments

This is more of a feature request than an issue.

I'm following http://variwiki.com/index.php?title=High_Assurance_Boot to test Secure Boot.

I need the following files from my u-boot build

  • SPL
  • SPL.log
  • u-boot-ivt.img
  • u-boot-ivt.img.log

Building manually from the git repo it works fine, but not so in yocto. I've added the following to my config:

UBOOT_CONFIG[secure-boot] = "mx6var_som_sd_SECURE_BOOT_config,sdcard,u-boot-ivt.img"

This makes it compile, but only a renamed u-boot-ivt.img is installed/deployed. Should the u-boot recipe be modified so that a secure-boot build puts all the necessary files in the deploy/images directory?

I'm trying to find out what differs in the build process so that I can append to compile/install/deploy.

Yocto does:

oe_runmake -C /home/tassle/src/yocto-pd-bsp/build_fb/tmp/work/myrfs-fslc-linux-gnueabi/u-boot-variscite/1.0-r0/git O=/home/tassle/src/yocto-pd-bsp/build_fb/tmp/work/myrfs-fslc-linux-gnueabi/u-boot-variscite/1.0-r0/build/mx6var_som_sd_SECURE_BOOT_config mx6var_som_sd_SECURE_BOOT_config

oe_runmake -C /home/tassle/src/yocto-pd-bsp/build_fb/tmp/work/myrfs-fslc-linux-gnueabi/u-boot-variscite/1.0-r0/git O=/home/tassle/src/yocto-pd-bsp/build_fb/tmp/work/myrfs-fslc-linux-gnueabi/u-boot-variscite/1.0-r0/build/mx6var_som_sd_SECURE_BOOT_config

I do:
make mx6var_som_sd_SECURE_BOOT_defconfig
make -j4

Still, I get the log files needed, and Yocto does not.

Hi @TheTasslehoff .
By default Yocto builds U-Boot with "V=1" for increased verbosity (see EXTRA_OEMAKE in sources/poky/meta/recipes-bsp/u-boot/u-boot.inc).
When doing so, the log files are not created - instead, that log info is printed to output.
In Yocto's case, the output is available at: BUILD_DIR/tmp/work/var_som_mx6-fslc-linux-gnueabi/u-boot-variscite/1.0-r0/temp/log.do_compile
The relevant log outputs should be near the end of the file.

To remove the "V=1" from the make command, create a u-boot-variscite.bbappend (or edit u-boot-variscite.bb), and add the following line to it:
EXTRA_OEMAKE_remove = "V=1"
Then the log files will be created in BUILD_DIR/tmp/work/var_som_mx6-fslc-linux-gnueabi/u-boot-variscite/1.0-r0/build/mx6var_som_sd_SECURE_BOOT_config/

Next time, please open a support ticket via Variscite's customer portal:
http://www.variscite.com/support/variscite-customer-portal

Regards,
Eran

That I will. Thanks a lot for the solution.

You are welcome.