diff options
author | Alexander Graf <agraf@suse.de> | 2016-03-04 01:10:01 +0100 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2016-03-15 18:03:10 -0400 |
commit | 50149ea37a21dcbed675297f1536c31a7db39c19 (patch) | |
tree | d6a18d12c1306cbc1306baed0aeea5ff2f5d2ae4 /common | |
parent | c1311ad4e0d1759788601513fac0f65620d40472 (diff) |
efi_loader: Add runtime services
After booting has finished, EFI allows firmware to still interact with the OS
using the "runtime services". These callbacks live in a separate address space,
since they are available long after U-Boot has been overwritten by the OS.
This patch adds enough framework for arbitrary code inside of U-Boot to become
a runtime service with the right section attributes set. For now, we don't make
use of it yet though.
We could maybe in the future map U-boot environment variables to EFI variables
here.
Signed-off-by: Alexander Graf <agraf@suse.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
Tested-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'common')
-rw-r--r-- | common/board_r.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/common/board_r.c b/common/board_r.c index 52a9b262eb1..6432d2374a9 100644 --- a/common/board_r.c +++ b/common/board_r.c @@ -65,6 +65,7 @@ #ifdef CONFIG_AVR32 #include <asm/arch/mmu.h> #endif +#include <efi_loader.h> DECLARE_GLOBAL_DATA_PTR; @@ -177,6 +178,9 @@ static int initr_reloc_global_data(void) */ gd->fdt_blob += gd->reloc_off; #endif +#ifdef CONFIG_EFI_LOADER + efi_runtime_relocate(gd->relocaddr, NULL); +#endif return 0; } |