diff options
| author | Caleb Connolly <[email protected]> | 2024-10-18 15:51:07 +0200 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2024-10-18 14:16:10 -0600 |
| commit | 491195769dbeed62f0a2f20cfa198bd2b297720e (patch) | |
| tree | d76cc15bc36c961d1032125faccf8234e2d5cbc2 /lib | |
| parent | 8ab2178de069194d2eed8fe1b90db7e12cf032bb (diff) | |
lmb: notify when adjacent regions are added
lmb_add_region() returns a positive integer if the added regions causes
existing regions to be coalesced. We still want to notify the EFI
subsystem about these added regions though, so adjust lmb_add() to only
bail on errors.
This fixes EFI memory allocation on boards with adjacent memory banks as is the
case on several Qualcomm boards like the RB3 Gen 2.
Fixes: 2f6191526a13 (lmb: notify of any changes to the LMB memory map)
Signed-off-by: Caleb Connolly <[email protected]>
Reviewed-by: Sughosh Ganu <[email protected]>
Tested-by: Neil Armstrong <[email protected]>
Reviewed-by: Ilias Apalodimas <[email protected]>
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/lmb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/lmb.c b/lib/lmb.c index 78fe2d4de7c..7e90f178763 100644 --- a/lib/lmb.c +++ b/lib/lmb.c @@ -487,7 +487,7 @@ long lmb_add(phys_addr_t base, phys_size_t size) struct alist *lmb_rgn_lst = &lmb.free_mem; ret = lmb_add_region(lmb_rgn_lst, base, size); - if (ret) + if (ret < 0) return ret; if (lmb_should_notify(LMB_NONE)) |
