2016-04-28 179 views
1

我正试图启用u-boot中的安全启动for gumstix overo风暴。 基于http://www.denx-cs.de/doku/?q=m28verifiedbootu-boot在启用安全启动后挂起:on overo

在我准备SD卡后,u-boot无法启动并出现以下错误消息。

U-Boot SPL 2015.07 (Apr 28 2016 - 13:53:06) 
SPL: Please implement spl_start_uboot() for your board 
SPL: Direct Linux boot not active! 
reading u-boot.img 
spl_load_image_fat: error reading image u-boot.img, err - -1 
SPL: Please implement spl_start_uboot() for your board 
SPL: Direct Linux boot not active! 
Failed to mount ext2 filesystem... 
spl_load_image_ext: ext4fs mount err - 0 

================ 

这是我使用的u-boot.dts文件。

/dts-v1/; 

/{ 
     model = "Keys"; 

     signature { 
       key-dev { 
         required = "conf"; 
         algo = "sha1,rsa2048"; 
         key-name-hint = "my_key"; 
       }; 
     }; 
}; 

产生的u-boot.dtb, DTC -p 0×1000 /work/u-boot.dts -O DTB -o /work/u-boot.dtb

而这些都是通过conf我已经加入到包括/ CONFIGS/omap3_overo.h

#define CONFIG_OF_CONTROL 
#define CONFIG_OF_SEPARATE 
#define CONFIG_FIT 
#define CONFIG_FIT_SIGNATURE 
#define CONFIG_RSA 
#define CONFIG_FIT_VERBOSE 

,我用下面的线编制的u-boot:

使ARCH =手臂CROSS_COMPILE = ARM-Linux的gnueabi- EXT_DTB =/work/u-boot.dtb all -j4

如果您对如何调试此问题有任何建议,请让我知道。

===================

有更新。

  1. 将u-boot-dtb.img名称更改为u-boot.img。
  2. 然后主板能够启动,但是当我尝试使用bootm时会给出以下消息。

**

Overo # 
## Loading kernel from FIT Image at 82000000 ... 
    Using '[email protected]' configuration 
    Verifying Hash Integrity ... sha1,rsa2048:my_keyRSA: Can't find Modular Exp implementation 
RSA: Can't find Modular Exp implementation 
- Failed to verify required signature 'key-my_key' 
Bad Data Hash 
ERROR: can't get kernel image! 
Overo # 

**

如DOC/uImage.FIT/beaglebone_vboot.txt提到的,我试过的脚本 - 工具/ fit_check_sign,其输出是正常的。能够验证签名。

所以仍然不知道,具体问题是什么,为什么我得到上述错误信息。 我搜索了UCLASS_MOD_EXP,/ * RSA Mod Exp设备* /,但无法获得太多信息。

什么是RSA Mod Exp设备以及如何确保我拥有该设备?

任何调试输入都会非常有帮助。

编辑:

diff include/configs/omap3_overo.h ../../u-boot2015.07/include/configs/omap3_overo.h 
     191a192,199 
     > 
     > #define CONFIG_OF_CONTROL                
     > #define CONFIG_OF_SEPARATE 
     > #define CONFIG_FIT 
     > #define CONFIG_FIT_SIGNATURE 
     > #define CONFIG_RSA 
     > #define CONFIG_FIT_VERBOSE 
     > 

回答

1

好了,第一个问题解决是在这里:

reading u-boot.img 
spl_load_image_fat: error reading image u-boot.img, err - -1 

因此,没有你的SD卡有U型的boot.img?请注意,您链接到的示例确实是而不是执行了SPL,而是改为使用旧样式(但仍为功能和支持的)imximage格式,因为它位于i.MX上,而您正在使用OMAP3平台。在这种情况下阅读doc/uImage.FIT/beaglebone_vboot。由于am335x(在beaglebone板中发现的)是对OMAP3部件的演变,而不是其他SoC供应商(如i.MX和OMAP3),因此txt对您非常有用。

编辑: 现在我们正在加载正确的文件,在v2015.07中,这些文件尚未迁移到Kconfig。你启用了CONFIG_RSA吗?看看ENABLE_VBOOT在各种配置头文件和树的其余部分所做的工作,你需要做类似的工作。

+0

我根据您对doc/uImage.FIT/beaglebone_vboot.txt的反馈编辑了该问题。但仍然面临启动问题 –

+0

我已经更新了我的答案,但也请贴出您的omap3_overo.h配置文件的差异。 –

+0

我添加了差异 ,我也在使用CONFIG_RSA。 现在调查其他VBOOT文件.. –