]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
lmb: bootm: remove superfluous lmb stub functions
authorSughosh Ganu <sughosh.ganu@linaro.org>
Mon, 26 Aug 2024 11:59:27 +0000 (17:29 +0530)
committerTom Rini <trini@konsulko.com>
Tue, 3 Sep 2024 20:08:50 +0000 (14:08 -0600)
Remove a couple of superfluous LMB stub functions, and instead put a
check for calling the lmb_reserve() function.

Signed-off-by: Sughosh Ganu <sughosh.ganu@linaro.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
boot/bootm.c

index ddede08979a684b8594df004e8b44c9a32f25711..a61bbcfb45c25df4693a1b1c447fc9e803bae206 100644 (file)
@@ -239,11 +239,6 @@ static int boot_get_kernel(const char *addr_fit, struct bootm_headers *images,
        return 0;
 }
 
-#if !CONFIG_IS_ENABLED(LMB)
-#define lmb_reserve(base, size)
-static inline void boot_start_lmb(void) { }
-#endif
-
 static int bootm_start(void)
 {
        memset((void *)&images, 0, sizeof(images));
@@ -700,7 +695,9 @@ static int bootm_load_os(struct bootm_headers *images, int boot_progress)
                images->os.end = relocated_addr + image_size;
        }
 
-       lmb_reserve(images->os.load, (load_end - images->os.load));
+       if (CONFIG_IS_ENABLED(LMB))
+               lmb_reserve(images->os.load, (load_end - images->os.load));
+
        return 0;
 }