From: Simon Goldschmidt Date: Mon, 14 Jan 2019 21:38:20 +0000 (+0100) Subject: bootm: use new common function lmb_init_and_reserve X-Git-Tag: v2019.04-rc1~40^2~3 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=5b978dab7b8b534e9bf50b97a875dbc9c15cfb54;p=oweals%2Fu-boot.git bootm: use new common function lmb_init_and_reserve This reduces duplicate code only. Signed-off-by: Simon Goldschmidt Reviewed-by: Simon Glass --- diff --git a/common/bootm.c b/common/bootm.c index 80f304ce9f..a4618b6d2e 100644 --- a/common/bootm.c +++ b/common/bootm.c @@ -56,15 +56,11 @@ static void boot_start_lmb(bootm_headers_t *images) ulong mem_start; phys_size_t mem_size; - lmb_init(&images->lmb); - mem_start = env_get_bootm_low(); mem_size = env_get_bootm_size(); - lmb_add(&images->lmb, (phys_addr_t)mem_start, mem_size); - - arch_lmb_reserve(&images->lmb); - board_lmb_reserve(&images->lmb); + lmb_init_and_reserve(&images->lmb, (phys_addr_t)mem_start, mem_size, + NULL); } #else #define lmb_reserve(lmb, base, size)