[U-Boot] [PATCH 2/2] armv8: sec_firmware: Add support for loadables in FIT

York Sun york.sun at nxp.com
Tue Oct 24 14:29:51 UTC 2017


On 10/23/2017 09:21 PM, Sumit Garg wrote:
<snip>
>>
>> Sumit,
>>
>> If I understand you correctly, you are parsing the secure firmware FIT image to
>> find the loadable node and store the 64-bit load address in the scratch
>> registers. How do you determine which scratch registers to use?
>>
>> York
> 
> Yes your understanding is correct. The scratch registers which I used are as follows:
> 
> For Chassis gen 3 platforms:
> 	/* Assign addresses to loadable ptrs */
> 	loadable_l = &gur->scratchrw[4];
> 	loadable_h = &gur->scratchrw[5];
> 
> For Chassis gen 2 platforms:
> 	/* Assign addresses to loadable ptrs */
> 	loadable_l = &scfg->scratchrw[2];
> 	loadable_h = &scfg->scratchrw[3];
> 
> I choose above scratch registers to avoid any conflict with usage of scratch registers
> in Boot-ROM, u-boot and PPA.

I see you write to these scratch registers but never read from them.
What's the purpose to store the address in them?

York


More information about the U-Boot mailing list