diff options
author | Nikhil M Jain <n-jain1@ti.com> | 2023-06-09 14:52:33 +0530 |
---|---|---|
committer | Udit Kumar <u-kumar1@ti.com> | 2023-06-12 09:49:43 +0530 |
commit | 898272c13607c7eb8c71f21d79d99daf8bd8298f (patch) | |
tree | b20b49416fa86e19d113a00711b8e8bbfe5ed633 /common | |
parent | 0878bacfa7e9fdd67641c4ea215e41978a2b8461 (diff) |
common: board_f: Pass frame buffer info from SPL to u-boot
U-boot proper can use frame buffer address passed from SPL to reserve
the memory area used by framebuffer set in SPL so that splash image
set in SPL continues to get displayed while u-boot proper is running.
Put the framebuffer address and size in a bloblist to make them
available at u-boot proper, if in u-boot proper CONFIG_VIDEO is defined.
Signed-off-by: Nikhil M Jain <n-jain1@ti.com>
Diffstat (limited to 'common')
-rw-r--r-- | common/board_f.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/common/board_f.c b/common/board_f.c index f3c1ab53b1..aaf64ed9d8 100644 --- a/common/board_f.c +++ b/common/board_f.c @@ -411,7 +411,16 @@ __weak int arch_reserve_mmu(void) static int reserve_video(void) { - if (IS_ENABLED(CONFIG_VIDEO)) { + if (IS_ENABLED(CONFIG_SPL_VIDEO) && spl_phase() > PHASE_SPL && + CONFIG_IS_ENABLED(BLOBLIST)) { + struct video_handoff *ho; + + ho = bloblist_find(BLOBLISTT_U_BOOT_VIDEO, sizeof(*ho)); + if (!ho) + return log_msg_ret("blf", -ENOENT); + video_reserve_from_bloblist(ho); + gd->relocaddr = ho->fb; + } else if (CONFIG_IS_ENABLED(VIDEO)) { ulong addr; int ret; |