Skip to content
Commit 37cb9c15 authored by This contributor prefers not to receive mails's avatar This contributor prefers not to receive mails Committed by Stefan Roese
Browse files

tools: kwbimage: Simplify aligning and calculating checksum



The return value of kwbimage_generate() is used for aligning the data
part of kwbimage. Use it for calculating proper 4 byte alignment as is
required by BootROM and also use it for allocating additional 4 bytes
for the 32-bit data checksum.

This simplifies the alignment code to be only at one place (in function
kwbimage_generate) and also simplifies setting checksum as it can be
directly updated in memory.

Signed-off-by: default avatarPali Rohár <pali@kernel.org>
Reviewed-by: default avatarMarek Behún <marek.behun@nic.cz>
Reviewed-by: default avatarStefan Roese <sr@denx.de>
Reviewed-by: default avatarChris Packham <judge.packham@gmail.com>
Tested-by: default avatarChris Packham <judge.packham@gmail.com>
parent 8ab9c6be
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment