[U-Boot] [PATCH 04/11] tools: mkimage: Extend mkimage to also include pmufw
Michal Simek
michal.simek at xilinx.com
Tue Nov 21 11:58:39 UTC 2017
On 20.11.2017 16:38, Simon Glass wrote:
> Hi Michal,
>
> On 6 November 2017 at 05:02, Michal Simek <michal.simek at xilinx.com> wrote:
>> This is generated command line when PMUFW_INIT_FILE is setup.
>>
>> ./tools/mkimage -T zynqmpimage -R ./"" -n
>> ./"board/xilinx/zynqmp/pmufw.bin" -d spl/u-boot-spl.bin spl/boot.bin
>>
>> pmufw has to be in binary format and mkimage is using dynamic
>> header size generation without using calloc function based on pmufw
>> size. Boot.bin header is filled with pmufw size and pmufw is copied to
>> header data section. When header is generated mkimage append
>> u-boot-spl.bin.
>
> Can you reword this a bit? It is a bit confusing to read.
Fixed in v2.
>
>>
>> Signed-off-by: Michal Simek <michal.simek at xilinx.com>
>> ---
>>
>> arch/arm/cpu/armv8/zynqmp/Kconfig | 7 +++
>> scripts/Makefile.spl | 3 +-
>> tools/zynqmpimage.c | 99 ++++++++++++++++++++++++++++++++++++++-
>> 3 files changed, 107 insertions(+), 2 deletions(-)
>>
>> diff --git a/arch/arm/cpu/armv8/zynqmp/Kconfig b/arch/arm/cpu/armv8/zynqmp/Kconfig
>> index 4dc8b1caf79e..7e4eaf782d17 100644
>> --- a/arch/arm/cpu/armv8/zynqmp/Kconfig
>> +++ b/arch/arm/cpu/armv8/zynqmp/Kconfig
>> @@ -57,6 +57,13 @@ config BOOT_INIT_FILE
>> Add register writes to boot.bin format (max 256 pairs).
>> Expect a table of register-value pairs, e.g. "0x12345678 0x4321"
>>
>> +config PMUFW_INIT_FILE
>> + string "PMU firmware"
>> + depends on SPL
>> + default ""
>> + help
>> + Include PMUFW to boot.bin.
>
> Help should include full details. Abbreviations should be explained.
I have fixed this too.
>
> Also are you saying that this tacks something new onto u-boot.bin?
> Where is that happening and how is it found at run time? I'm wondering
> is this might be a job for binman?
Nope. It is really just boot header follows by pmufw.bin and
u-boot-spl.bin >> boot.bin
bootrom based on headers know that there is pmufw.bin which is consumed
by PMU unit which is microblaze cpu. And SPL runs on a53s.
I am aware about binman when you send the first version but haven't had
any time to look at it. This mkimage extension is something I used for
pretty long time and I didn't see any issue for this usecase.
boot.bin format can contain multiple sessions for example ATF, full
u-boot, Linux, rootfs, app for arm R5, bitstream, etc. For generating
this boot.bin maybe binman could be right tool but Xilinx has own tools
called bootgen which is capable to generate this image. It also contains
encryption and authentication parts.
Thanks,
Michal
Thanks,
Michal
More information about the U-Boot
mailing list