[U-Boot] Hi, Problem about verify uboot
Simon Glass
sjg at chromium.org
Wed Jul 23 11:32:28 CEST 2014
(copying the mailing list - but please do this yourself from now on -
note you will need to join it first if you have not already)
Hi,
On 23 July 2014 03:20, Duxiaoqiang <duxiaoqiang at huawei.com> wrote:
> Hi Simon
>
>
>
> When I verified secure UBOOT with FIT image, I found a problem about
> it, and maybe need your help. Details about the problem please see below.
>
>
>
> Ø Use mkimage tool to generate a fit.img file which contains a Linux image
> and a fdt file.
>
> Ø Boot fit.img with bootm command: bootm 0xxxxxxxxx
>
> Ø Verify hash value about the image and fdt was success. But after verify
> step, there was a synchronous abort exception(data alignment problem)
>
> Ø I trace the source code, and found that the error occurred in function
> boot_fdt_add_mem_rsv_regions->fdt_num_mem_rsv->(_fdt_mem_rsv)->size;
>
> _fdt_mem_rsv function will return a pointer point to the reserve memory
> space about fdt section in image, and in my environment the value is
> 0x985a051c, but the type of size is unsigned long long.
>
> This is the reason why the synchronous abort exception happened.
>
> And I I trace the address value of fdt_blob, it is 0x985a04f4, also
> un-alignment to 8 bytes.
>
> I guess the layout space of fdt was decided by mkimage tool.
>
>
>
> My question is:
>
> 1) I think it is a common problem, is there any precedent, and what is
> the solution.
I'm not quite sure of the problem.
>
> 2) Is there any solutions to force the start address of fdt_blob be
> align with 8 bytes?
Yes this is set by setup_fdt() in board_f.c, assuming you are using
CONFIG_SYS_GENERIC_BOARD.
For the CONFIG_OF_SEPARATE case you probably need to make sure that
u-boot.bin is a multiple of 8 bytes long. You can do this by adding
alignment into the .lds file for your board before the _end or
_image_end symbol.
Regards,
Simon
More information about the U-Boot
mailing list