From 8da26f51569aa3f9b6a0be49058399a0a036c14a Mon Sep 17 00:00:00 2001 From: Heinrich Schuchardt Date: Mon, 25 Apr 2022 23:54:48 +0200 Subject: [PATCH] efi_loader: simplify efi_add_conventional_memory_map() Remove redundant constraint. Signed-off-by: Heinrich Schuchardt --- lib/efi_loader/efi_memory.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/efi_loader/efi_memory.c b/lib/efi_loader/efi_memory.c index 1c51a3f..e048a54 100644 --- a/lib/efi_loader/efi_memory.c +++ b/lib/efi_loader/efi_memory.c @@ -771,7 +771,7 @@ efi_status_t efi_add_conventional_memory_map(u64 ram_start, u64 ram_end, /* ram_top is before this region, reserve all */ efi_add_memory_map_pg(ram_start, pages, EFI_BOOT_SERVICES_DATA, true); - } else if ((ram_top >= ram_start) && (ram_top < ram_end)) { + } else if (ram_top < ram_end) { /* ram_top is inside this region, reserve parts */ pages = (ram_end - ram_top) >> EFI_PAGE_SHIFT; -- 2.7.4