summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuillaume Ranquet <[email protected]>2025-09-11 15:35:41 +0200
committerTom Rini <[email protected]>2026-02-03 12:51:40 -0600
commit0cb8a88e7ab7824b7dc857fb6572705f3e19c456 (patch)
treeb0d1fb90f7b6008227fd89ffab219538909c6c48
parent80a3572f9bc3fdd8f0b0fa73f2f853da71b059eb (diff)
x86: boot: fix unreachable else branch in boot_prep_linux
The else if branch uses the is_zimage boolean which is initialized to 0 and never set before being tested here. remove the test on is_zimage to make this code reachable. Signed-off-by: Guillaume Ranquet <[email protected]> Reviewed-by: Bin Meng <[email protected]> Reviewed-by: Simon Glass <[email protected]>
-rw-r--r--arch/x86/lib/bootm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/lib/bootm.c b/arch/x86/lib/bootm.c
index 0827a884b1d..7a94dc877e3 100644
--- a/arch/x86/lib/bootm.c
+++ b/arch/x86/lib/bootm.c
@@ -103,7 +103,7 @@ static int boot_prep_linux(struct bootm_headers *images)
}
is_zimage = 1;
#if defined(CONFIG_FIT)
- } else if (images->fit_uname_os && is_zimage) {
+ } else if (images->fit_uname_os) {
ret = fit_image_get_data(images->fit_hdr_os,
images->fit_noffset_os,
(const void **)&data, &len);