aboutsummaryrefslogtreecommitdiff
path: root/common/board_f.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-11-03 21:09:20 -0600
committerSimon Glass <sjg@chromium.org>2021-12-05 09:21:44 -0700
commitd5b6e91ba2cac6cb0a2f7437fdbbe792d1acb387 (patch)
tree842f22a1bc589e25c4968440d4986c77dc00f46e /common/board_f.c
parente2f0474b05e9667f7f764138c833331fa701e7bf (diff)
downloadu-boot-d5b6e91ba2cac6cb0a2f7437fdbbe792d1acb387.zip
u-boot-d5b6e91ba2cac6cb0a2f7437fdbbe792d1acb387.tar.gz
u-boot-d5b6e91ba2cac6cb0a2f7437fdbbe792d1acb387.tar.bz2
bloblist: Support allocating the bloblist
Typically the bloblist is positioned at a fixed address in memory until relocation. This is convenient when it is set up in SPL or before relocation. But for EFI we want to set it up only when U-Boot proper is running. Add a way to allocate it using malloc() and update the documentation to cover this aspect of bloblist. Note there are no tests of this feature at present, nor any direct testing of bloblist_init(). This can be added, e.g. by making this option controllable at runtime. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'common/board_f.c')
-rw-r--r--common/board_f.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/common/board_f.c b/common/board_f.c
index f7ea7c7..dd69c3b 100644
--- a/common/board_f.c
+++ b/common/board_f.c
@@ -655,8 +655,14 @@ static int reloc_bootstage(void)
static int reloc_bloblist(void)
{
#ifdef CONFIG_BLOBLIST
- if (gd->flags & GD_FLG_SKIP_RELOC)
+ /*
+ * Relocate only if we are supposed to send it
+ */
+ if ((gd->flags & GD_FLG_SKIP_RELOC) &&
+ CONFIG_BLOBLIST_SIZE == CONFIG_BLOBLIST_SIZE_RELOC) {
+ debug("Not relocating bloblist\n");
return 0;
+ }
if (gd->new_bloblist) {
int size = CONFIG_BLOBLIST_SIZE;