summaryrefslogtreecommitdiff
path: root/HisiPkg/D01BoardPkg/Bds/BootMenu.c
diff options
context:
space:
mode:
authorAlexander Graf <agraf@suse.de>2014-12-12 02:17:10 +0100
committerWei Xu <xuwei5@huawei.com>2014-12-17 16:58:20 +0800
commitf9bbfcb9ee24e9d3540b03a3b10352c05d7b36ac (patch)
tree7353c724bd62e2bbd09d1139406077510b64518a /HisiPkg/D01BoardPkg/Bds/BootMenu.c
parentccdc4cc7e4e884a5a1eb25451363e38a3091c775 (diff)
HisiPkg: D01: Move bootwrapper to SRAM
Reserving DDR memory is a very tricky thing to do. We always need to make sure we don't overlap with memory regions the guest uncondionally uses. However, we need to keep the bootwrapper code resident in memory for CPU hotplug. So let's just move it into SRAM. There it can stay happily ever after. Unfortunately we need to make sure we only copy the bootwrapper to SRAM, not a full NAND block. So this patch also introduces a bounce buffer for NAND access. Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: Wei Xu <xuwei5@huawei.com>
Diffstat (limited to 'HisiPkg/D01BoardPkg/Bds/BootMenu.c')
-rw-r--r--HisiPkg/D01BoardPkg/Bds/BootMenu.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/HisiPkg/D01BoardPkg/Bds/BootMenu.c b/HisiPkg/D01BoardPkg/Bds/BootMenu.c
index 4bc9cda82..c5380cb2b 100644
--- a/HisiPkg/D01BoardPkg/Bds/BootMenu.c
+++ b/HisiPkg/D01BoardPkg/Bds/BootMenu.c
@@ -772,14 +772,14 @@ BootLinuxAtagLoader (
EFI_STATUS LoadLinuxAtSecEnd()
{
- LinuxEntry entry = (LinuxEntry)(TEXT_DDR_BASE);
+ LinuxEntry entry = (LinuxEntry)(TEXT_SRAM_BASE);
EFI_STATUS Status = EFI_SUCCESS;
ArmDisableDataCache();
ArmCleanInvalidateDataCache();
ArmDisableInstructionCache ();
ArmInvalidateInstructionCache ();
ArmDisableMmu();
- DEBUG(( EFI_D_ERROR, "MOVE PC TEXT_DDR_BASE\n"));
+ DEBUG(( EFI_D_ERROR, "MOVE PC TEXT_SRAM_BASE\n"));
(void)entry();
return Status;
}
@@ -791,7 +791,7 @@ EFI_STATUS RunBootwrapper()
*(UINTN*)(UINTN)(0xe302b000 + 0x18) = 0;
*(UINTN*)(UINTN)(0xe302b000 + 0x1c) = 0;
- *(volatile UINT32 *)(0xe0000000 + 0x100) = TEXT_DDR_BASE;
+ *(volatile UINT32 *)(0xe0000000 + 0x100) = TEXT_SRAM_BASE;
ArmCleanDataCache();
*(UINT8*)(0xf4007000) = 'G';