2007-06-22 08:57:39 +02:00
|
|
|
/** @file
|
|
|
|
Entry point to the DXE Core.
|
|
|
|
|
2018-06-27 15:11:33 +02:00
|
|
|
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
2019-04-04 01:06:00 +02:00
|
|
|
SPDX-License-Identifier: BSD-2-Clause-Patent
|
2007-06-22 08:57:39 +02:00
|
|
|
|
|
|
|
**/
|
|
|
|
|
2007-07-20 08:28:14 +02:00
|
|
|
|
2007-06-22 18:22:26 +02:00
|
|
|
#include <PiDxe.h>
|
2007-07-20 08:28:14 +02:00
|
|
|
|
|
|
|
|
2007-06-22 18:22:26 +02:00
|
|
|
#include <Library/DxeCoreEntryPoint.h>
|
|
|
|
#include <Library/DebugLib.h>
|
|
|
|
#include <Library/BaseLib.h>
|
2007-06-22 08:57:39 +02:00
|
|
|
|
|
|
|
//
|
2018-06-27 15:11:33 +02:00
|
|
|
// Cache copy of HobList pointer.
|
|
|
|
//
|
2007-06-22 08:57:39 +02:00
|
|
|
VOID *gHobList = NULL;
|
|
|
|
|
|
|
|
/**
|
2018-06-27 15:11:33 +02:00
|
|
|
The entry point of PE/COFF Image for the DXE Core.
|
2008-12-10 04:14:49 +01:00
|
|
|
|
2009-02-06 08:26:53 +01:00
|
|
|
This function is the entry point for the DXE Core. This function is required to call
|
|
|
|
ProcessModuleEntryPointList() and ProcessModuleEntryPointList() is never expected to return.
|
|
|
|
The DXE Core is responsible for calling ProcessLibraryConstructorList() as soon as the EFI
|
|
|
|
System Table and the image handle for the DXE Core itself have been established.
|
2008-12-10 04:14:49 +01:00
|
|
|
If ProcessModuleEntryPointList() returns, then ASSERT() and halt the system.
|
|
|
|
|
2018-06-27 15:11:33 +02:00
|
|
|
@param HobStart The pointer to the beginning of the HOB List passed in from the PEI Phase.
|
2007-06-22 08:57:39 +02:00
|
|
|
|
|
|
|
**/
|
|
|
|
VOID
|
|
|
|
EFIAPI
|
|
|
|
_ModuleEntryPoint (
|
|
|
|
IN VOID *HobStart
|
|
|
|
)
|
|
|
|
{
|
|
|
|
//
|
|
|
|
// Cache a pointer to the HobList
|
|
|
|
//
|
|
|
|
gHobList = HobStart;
|
|
|
|
|
|
|
|
//
|
|
|
|
// Call the DXE Core entry point
|
|
|
|
//
|
|
|
|
ProcessModuleEntryPointList (HobStart);
|
|
|
|
|
|
|
|
//
|
|
|
|
// Should never return
|
|
|
|
//
|
|
|
|
ASSERT(FALSE);
|
|
|
|
CpuDeadLoop ();
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
2008-12-10 04:14:49 +01:00
|
|
|
Required by the EBC compiler and identical in functionality to _ModuleEntryPoint().
|
|
|
|
|
|
|
|
This function is required to call _ModuleEntryPoint() passing in HobStart.
|
2007-06-22 08:57:39 +02:00
|
|
|
|
2018-06-27 15:11:33 +02:00
|
|
|
@param HobStart The pointer to the beginning of the HOB List passed in from the PEI Phase.
|
2007-06-22 08:57:39 +02:00
|
|
|
|
|
|
|
**/
|
|
|
|
VOID
|
|
|
|
EFIAPI
|
|
|
|
EfiMain (
|
|
|
|
IN VOID *HobStart
|
|
|
|
)
|
|
|
|
{
|
|
|
|
_ModuleEntryPoint (HobStart);
|
|
|
|
}
|