Code Scrub for Dxe Core.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5560 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@@ -24,7 +24,7 @@ EFI_DEBUG_IMAGE_INFO_TABLE_HEADER mDebugInfoTableHeader = {
|
||||
|
||||
EFI_SYSTEM_TABLE_POINTER *mDebugTable = NULL;
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
Creates and initializes the DebugImageInfo Table. Also creates the configuration
|
||||
@@ -41,10 +41,10 @@ VOID
|
||||
CoreInitializeDebugImageInfoTable (
|
||||
VOID
|
||||
)
|
||||
{
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
EFI_PHYSICAL_ADDRESS Mem;
|
||||
UINTN NumberOfPages;
|
||||
UINTN NumberOfPages;
|
||||
|
||||
//
|
||||
// Allocate boot services memory for the structure. It's required to be aligned on
|
||||
@@ -52,14 +52,14 @@ CoreInitializeDebugImageInfoTable (
|
||||
// a 4M aligned address within the memory we just freed, and then allocate memory at that
|
||||
// address for our initial structure.
|
||||
//
|
||||
NumberOfPages = FOUR_MEG_PAGES + EFI_SIZE_TO_PAGES(sizeof (EFI_SYSTEM_TABLE_POINTER));
|
||||
NumberOfPages = FOUR_MEG_PAGES + EFI_SIZE_TO_PAGES(sizeof (EFI_SYSTEM_TABLE_POINTER));
|
||||
|
||||
Status = CoreAllocatePages (AllocateAnyPages, EfiBootServicesData, NumberOfPages , &Mem);
|
||||
Status = CoreAllocatePages (AllocateAnyPages, EfiBootServicesData, NumberOfPages , &Mem);
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
if (EFI_ERROR(Status)) {
|
||||
return;
|
||||
}
|
||||
Status = CoreFreePages (Mem, NumberOfPages);
|
||||
Status = CoreFreePages (Mem, NumberOfPages);
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
if (EFI_ERROR(Status)) {
|
||||
return;
|
||||
@@ -69,8 +69,8 @@ CoreInitializeDebugImageInfoTable (
|
||||
// Then allocate memory at that address
|
||||
//
|
||||
Mem = (Mem + FOUR_MEG_MASK) & (~FOUR_MEG_MASK);
|
||||
|
||||
Status = CoreAllocatePages (AllocateAddress, EfiBootServicesData, NumberOfPages - FOUR_MEG_PAGES, &Mem);
|
||||
|
||||
Status = CoreAllocatePages (AllocateAddress, EfiBootServicesData, NumberOfPages - FOUR_MEG_PAGES, &Mem);
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
if (EFI_ERROR(Status)) {
|
||||
return;
|
||||
@@ -112,9 +112,9 @@ CoreUpdateDebugTableCrc32 (
|
||||
Adds a new DebugImageInfo structure to the DebugImageInfo Table. Re-Allocates
|
||||
the table if it's not large enough to accomidate another entry.
|
||||
|
||||
@param ImageInfoType type of debug image information
|
||||
@param LoadedImage pointer to the loaded image protocol for the image being
|
||||
loaded
|
||||
@param ImageInfoType type of debug image information
|
||||
@param LoadedImage pointer to the loaded image protocol for the image being
|
||||
loaded
|
||||
@param ImageHandle image handle for the image being loaded
|
||||
|
||||
**/
|
||||
@@ -124,7 +124,7 @@ CoreNewDebugImageInfoEntry (
|
||||
IN EFI_LOADED_IMAGE_PROTOCOL *LoadedImage,
|
||||
IN EFI_HANDLE ImageHandle
|
||||
)
|
||||
{
|
||||
{
|
||||
EFI_DEBUG_IMAGE_INFO *Table;
|
||||
EFI_DEBUG_IMAGE_INFO *NewTable;
|
||||
UINTN Index;
|
||||
@@ -199,7 +199,7 @@ VOID
|
||||
CoreRemoveDebugImageInfoEntry (
|
||||
EFI_HANDLE ImageHandle
|
||||
)
|
||||
{
|
||||
{
|
||||
EFI_DEBUG_IMAGE_INFO *Table;
|
||||
UINTN Index;
|
||||
|
||||
|
@@ -23,11 +23,11 @@ UINTN mSystemTableAllocateSize = 0;
|
||||
/**
|
||||
Find a config table by name in system table's ConfigurationTable.
|
||||
|
||||
@param Guid The table name to look for
|
||||
@param Table Pointer of the config table
|
||||
@param Guid The table name to look for
|
||||
@param Table Pointer of the config table
|
||||
|
||||
@retval EFI_NOT_FOUND Could not find the table in system table's
|
||||
ConfigurationTable.
|
||||
@retval EFI_NOT_FOUND Could not find the table in system table's
|
||||
ConfigurationTable.
|
||||
@retval EFI_SUCCESS Table successfully found.
|
||||
|
||||
**/
|
||||
@@ -56,10 +56,10 @@ CoreGetConfigTable (
|
||||
Boot Service called to add, modify, or remove a system configuration table from
|
||||
the EFI System Table.
|
||||
|
||||
@param Guid Pointer to the GUID for the entry to add, update, or
|
||||
remove
|
||||
@param Table Pointer to the configuration table for the entry to add,
|
||||
update, or remove, may be NULL.
|
||||
@param Guid Pointer to the GUID for the entry to add, update, or
|
||||
remove
|
||||
@param Table Pointer to the configuration table for the entry to add,
|
||||
update, or remove, may be NULL.
|
||||
|
||||
@return EFI_SUCCESS Guid, Table pair added, updated, or removed.
|
||||
@return EFI_INVALID_PARAMETER Input GUID not valid.
|
||||
|
@@ -25,8 +25,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
@param Microseconds The number of microseconds to stall execution.
|
||||
|
||||
@retval EFI_SUCCESS Execution was stalled for at least the requested
|
||||
amount of microseconds.
|
||||
@retval EFI_SUCCESS Execution was stalled for at least the requested
|
||||
amount of microseconds.
|
||||
@retval EFI_NOT_AVAILABLE_YET gMetronome is not available yet
|
||||
|
||||
**/
|
||||
|
Reference in New Issue
Block a user