Skip to content

spl: atf: Fix potential bug on getting FIT data

Massimo Pegorer u-boot 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 5 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4spl: atf: Improve comments and code readabilitycommon/spl/spl_atf.c+15 -192 replies
2/4image: fit: Improve functions description commentsboot/image-fit.c+5 -71 reply
3/4spl: atf: Fix potential but not occurring bugcommon/spl/spl_atf.c+7 -81 reply
4/4spl: atf: Reduce SPL code sizecommon/spl/spl_atf.c+19 -231 reply

Reviews trailers per patch

All 4 patches have a Reviewed-by or Acked-by.

PatchSimon Glass
1/4R-b
2/4R-b
3/4R-b
4/4R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/4] spl: atf: Fix potential bug on getting FIT data

If both fit_image_get_entry() and fit_image_get_load() calls fail, an uninitialized variable value is passed to TF-A as BL3-2 and/or BL3-3 entry point in spl_invoke_atf().

In real world of current SPL flow this is not expected to occur because a fit_image_get_load() failure should break boot during images loading phase, and thus before entering spl_invoke_atf().

Update improve and fix comments.

A minor rework slightly reduces SPL code size up to 72 bytes.
Note: I am not enough confident about uintptr_t and ulong sizes matching within all architectures, otherwise straightforward pass of bl3x_entry reference to fit_image_get_xxx would be fine.

Massimo Pegorer (4):
spl: atf: Improve comments and code readability
image: fit: Improve functions description comments
spl: atf: Fix potential but not occurring bug
spl: atf: Reduce SPL code size

 boot/image-fit.c     | 12 +++----
 common/spl/spl_atf.c | 75 +++++++++++++++++++-------------------------
 2 files changed, 38 insertions(+), 49 deletions(-)
Signature · 1 line
2.34.1