mkimage: sunxi_egon: Allow overriding the padding size
authorSamuel Holland <samuel@sholland.org>
Wed, 13 Oct 2021 00:21:27 +0000 (19:21 -0500)
committerAndre Przywara <andre.przywara@arm.com>
Sun, 30 Jan 2022 01:25:00 +0000 (01:25 +0000)
commit50d5c6428fc280c095b0edd1a612b3661b5db77d
treeb8bba8542981838394c37ab3a04113614fbc4503
parente97943b732d0e0588cfab3a8cb53459ca14dc81d
mkimage: sunxi_egon: Allow overriding the padding size

Due to a bug in the H3 SoC, where the CPU 0 hotplug flag cannot be
written, resuming CPU 0 requires using the "Super Standby" code path in
the BROM instead of the hotplug path. This path requires jumping to an
eGON image in SRAM.

This resume image, whose single purpose is to jump back to the secure
monitor, only needs to contain a single instruction. Padding the image
to 8 KiB would be wasteful of SRAM. Hook up the -B (block size) option
so users can set the block/padding size.

Signed-off-by: Samuel Holland <samuel@sholland.org>
Reviewed-by: Andre Przywara <andre.przywara@arm.com>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
tools/sunxi_egon.c