diff options
author | Sughosh Ganu <sughosh.ganu@linaro.org> | 2024-10-15 21:07:07 +0530 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2024-10-15 13:45:29 -0600 |
commit | 2f6191526a1325b6ddb59795a093eca69dbf8976 (patch) | |
tree | 8f50f00ee55466956045e92ce95641b4fd78c47c /lib/efi_loader/efi_memory.c | |
parent | 22f2c9ed9f533a56bed09bd4e0e37852b6b9f3b1 (diff) |
lmb: notify of any changes to the LMB memory map
In U-Boot, LMB and EFI are two primary modules who provide memory
allocation and reservation API's. Both these modules operate with the
same regions of memory for allocations. Use the LMB memory map update
event to notify other interested listeners about a change in it's
memory map. This can then be used by the other module to keep track of
available and used memory.
There is no need to send these notifications when the LMB module is
being unit-tested. Add a flag to the lmb structure to indicate if the
memory map is being used for tests, and suppress sending any
notifications when running these unit tests.
Signed-off-by: Sughosh Ganu <sughosh.ganu@linaro.org>
Diffstat (limited to 'lib/efi_loader/efi_memory.c')
-rw-r--r-- | lib/efi_loader/efi_memory.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/efi_loader/efi_memory.c b/lib/efi_loader/efi_memory.c index aa1da21f9f9..41501e9d41b 100644 --- a/lib/efi_loader/efi_memory.c +++ b/lib/efi_loader/efi_memory.c @@ -264,7 +264,7 @@ static s64 efi_mem_carve_out(struct efi_mem_list *map, * @overlap_only_ram: region may only overlap RAM * Return: status code */ -static efi_status_t efi_add_memory_map_pg(u64 start, u64 pages, +efi_status_t efi_add_memory_map_pg(u64 start, u64 pages, int memory_type, bool overlap_only_ram) { |