]> git.dujemihanovic.xyz Git - u-boot.git/commit
efi_loader: rounding of image size
authorHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Sun, 29 Aug 2021 09:52:44 +0000 (11:52 +0200)
committerHeinrich Schuchardt <xypron.glpk@gmx.de>
Sat, 4 Sep 2021 10:03:57 +0000 (12:03 +0200)
commitf3a343d7339acf1d531e438e15fef3c7975cfdcf
treedc0776611d802cb400f322b786044192ffad1605
parent1ea133acd64eb0099865b0649b1d039ef63787ee
efi_loader: rounding of image size

We should not first allocate memory and then report a rounded up value as
image size. Instead first round up according to section allocation and then
allocate the memory.

Fixes: 82786754b9d2 ("efi_loader: ImageSize must be multiple of SectionAlignment")
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
lib/efi_loader/efi_image_loader.c