mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-10 23:24:38 +00:00
efi_loader: only reserve memory if fdt node enabled
Sub-nodes of /reserved-memory may be disabled. In this case we should not
reserve memory in the memory map.
Reported-by: Patrick DELAUNAY <patrick.delaunay@st.com>
Fixes: fef907b2e4
("efi_loader: create reservations after
ft_board_setup")
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Atish Patra <atish.patra@wdc.com>
This commit is contained in:
parent
6c0ef35cdc
commit
4ef2b0d551
1 changed files with 2 additions and 1 deletions
|
@ -199,7 +199,8 @@ static void efi_carve_out_dt_rsv(void *fdt)
|
|||
* The /reserved-memory node may have children with
|
||||
* a size instead of a reg property.
|
||||
*/
|
||||
if (addr != FDT_ADDR_T_NONE)
|
||||
if (addr != FDT_ADDR_T_NONE &&
|
||||
fdtdec_get_is_enabled(fdt, subnode))
|
||||
efi_reserve_memory(addr, size);
|
||||
subnode = fdt_next_subnode(fdt, subnode);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue