mirror of https://github.com/acidanthera/audk.git
DuetPkg: Move EfiLdr Handoff data to stack
The EfiLdr image may be overwritten later in the boot process. This can lead to the Handoff structure being corrupted before DxeIpl is finished with it. To help prevent this, we move the Handoff structure to the stack, and in DxeIpl make a copy of it. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10950 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
6fc74eaa63
commit
dcb428da9e
|
@ -138,6 +138,10 @@ Returns:
|
||||||
VOID *MemoryDescriptor;
|
VOID *MemoryDescriptor;
|
||||||
VOID *NvStorageBase;
|
VOID *NvStorageBase;
|
||||||
CHAR8 PrintBuffer[256];
|
CHAR8 PrintBuffer[256];
|
||||||
|
EFILDRHANDOFF HandoffCopy;
|
||||||
|
|
||||||
|
CopyMem ((VOID*) &HandoffCopy, (VOID*) Handoff, sizeof (EFILDRHANDOFF));
|
||||||
|
Handoff = &HandoffCopy;
|
||||||
|
|
||||||
ClearScreen();
|
ClearScreen();
|
||||||
PrintString("Enter DxeIpl ...\n");
|
PrintString("Enter DxeIpl ...\n");
|
||||||
|
|
|
@ -50,7 +50,7 @@ EfiLoader (
|
||||||
UINTN BfvBase;
|
UINTN BfvBase;
|
||||||
EFI_MAIN_ENTRYPOINT EfiMainEntrypoint;
|
EFI_MAIN_ENTRYPOINT EfiMainEntrypoint;
|
||||||
CHAR8 PrintBuffer[256];
|
CHAR8 PrintBuffer[256];
|
||||||
STATIC EFILDRHANDOFF Handoff;
|
EFILDRHANDOFF Handoff;
|
||||||
|
|
||||||
ClearScreen();
|
ClearScreen();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue