Add doxygen style comments for functions in DxeMain.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5189 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
qhuang8
2008-05-09 07:08:30 +00:00
parent dc2e539a34
commit 162ed59443
38 changed files with 6088 additions and 7797 deletions

View File

@@ -26,30 +26,22 @@ static EFI_DEBUG_IMAGE_INFO_TABLE_HEADER mDebugInfoTableHeader = {
static EFI_SYSTEM_TABLE_POINTER *mDebugTable = NULL;
/**
Creates and initializes the DebugImageInfo Table. Also creates the configuration
table and registers it into the system table.
Note:
This function allocates memory, frees it, and then allocates memory at an
address within the initial allocation. Since this function is called early
in DXE core initialization (before drivers are dispatched), this should not
be a problem.
**/
VOID
CoreInitializeDebugImageInfoTable (
VOID
)
/*++
Routine Description:
Creates and initializes the DebugImageInfo Table. Also creates the configuration
table and registers it into the system table.
Arguments:
None
Returns:
NA
Notes:
This function allocates memory, frees it, and then allocates memory at an
address within the initial allocation. Since this function is called early
in DXE core initialization (before drivers are dispatched), this should not
be a problem.
--*/
{
EFI_STATUS Status;
EFI_PHYSICAL_ADDRESS Mem;
@@ -97,56 +89,42 @@ Notes:
ASSERT_EFI_ERROR (Status);
}
VOID
CoreUpdateDebugTableCrc32 (
VOID
)
/*++
Routine Description:
/**
Update the CRC32 in the Debug Table.
Since the CRC32 service is made available by the Runtime driver, we have to
wait for the Runtime Driver to be installed before the CRC32 can be computed.
This function is called elsewhere by the core when the runtime architectural
protocol is produced.
Arguments:
None
Returns:
NA
--*/
**/
VOID
CoreUpdateDebugTableCrc32 (
VOID
)
{
ASSERT(mDebugTable != NULL);
mDebugTable->Crc32 = 0;
gDxeCoreBS->CalculateCrc32 ((VOID *)mDebugTable, sizeof (EFI_SYSTEM_TABLE_POINTER), &mDebugTable->Crc32);
}
/**
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 ImageHandle image handle for the image being loaded
**/
VOID
CoreNewDebugImageInfoEntry (
IN UINT32 ImageInfoType,
IN EFI_LOADED_IMAGE_PROTOCOL *LoadedImage,
IN EFI_HANDLE ImageHandle
)
/*++
Routine Description:
Adds a new DebugImageInfo structure to the DebugImageInfo Table. Re-Allocates
the table if it's not large enough to accomidate another entry.
Arguments:
ImageInfoType - type of debug image information
LoadedImage - pointer to the loaded image protocol for the image being loaded
ImageHandle - image handle for the image being loaded
Returns:
NA
--*/
{
EFI_DEBUG_IMAGE_INFO *Table;
EFI_DEBUG_IMAGE_INFO *NewTable;
@@ -211,25 +189,17 @@ Returns:
}
/**
Removes and frees an entry from the DebugImageInfo Table.
@param ImageHandle image handle for the image being unloaded
**/
VOID
CoreRemoveDebugImageInfoEntry (
EFI_HANDLE ImageHandle
)
/*++
Routine Description:
Removes and frees an entry from the DebugImageInfo Table.
Arguments:
ImageHandle - image handle for the image being unloaded
Returns:
NA
--*/
{
EFI_DEBUG_IMAGE_INFO *Table;
UINTN Index;
@@ -252,3 +222,4 @@ Returns:
mDebugInfoTableHeader.UpdateStatus &= ~EFI_DEBUG_IMAGE_INFO_UPDATE_IN_PROGRESS;
}

View File

@@ -20,30 +20,23 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
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
@retval EFI_NOT_FOUND Could not find the table in system table's
ConfigurationTable.
@retval EFI_SUCCESS Table successfully found.
**/
EFI_STATUS
CoreGetConfigTable (
IN EFI_GUID *Guid,
OUT VOID **Table
)
/*++
Routine Description:
Find a config table by name in system table's ConfigurationTable.
Arguments:
Guid - The table name to look for
Table - Pointer of the config table
Returns:
EFI_NOT_FOUND - Could not find the table in system table's ConfigurationTable.
EFI_SUCCESS - Table successfully found.
--*/
{
UINTN Index;
@@ -59,33 +52,28 @@ Returns:
/**
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.
@return EFI_SUCCESS Guid, Table pair added, updated, or removed.
@return EFI_INVALID_PARAMETER Input GUID not valid.
@return EFI_NOT_FOUND Attempted to delete non-existant entry
@return EFI_OUT_OF_RESOURCES Not enough memory available
**/
EFI_STATUS
EFIAPI
CoreInstallConfigurationTable (
IN EFI_GUID *Guid,
IN VOID *Table
)
/*++
Routine Description:
Boot Service called to add, modify, or remove a system configuration table from
the EFI System Table.
Arguments:
Guid - Pointer to the GUID for the entry to add, update, or remove
Table - Pointer to the configuration table for the entry to add, update, or
remove, may be NULL.
Returns:
EFI_SUCCESS Guid, Table pair added, updated, or removed.
EFI_INVALID_PARAMETER Input GUID not valid.
EFI_NOT_FOUND Attempted to delete non-existant entry
EFI_OUT_OF_RESOURCES Not enough memory available
--*/
{
UINTN Index;
EFI_CONFIGURATION_TABLE *EfiConfigurationTable;

View File

@@ -17,7 +17,28 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#define WATCHDOG_TIMER_CALIBRATE_PER_SECOND 10000000
/**
Sets the system's watchdog timer.
@param Timeout The number of seconds to set the watchdog timer to.
A value of zero disables the timer.
@param WatchdogCode The numeric code to log on a watchdog timer timeout
event. The firmware reserves codes 0x0000 to 0xFFFF.
Loaders and operating systems may use other timeout
codes.
@param DataSize The size, in bytes, of WatchdogData.
@param WatchdogData A data buffer that includes a Null-terminated Unicode
string, optionally followed by additional binary data.
The string is a description that the call may use to
further indicate the reason to be logged with a
watchdog event.
@return EFI_SUCCESS Timeout has been set
@return EFI_NOT_AVAILABLE_YET WatchdogTimer is not available yet
@return EFI_UNSUPPORTED System does not have a timer (currently not used)
@return EFI_DEVICE_ERROR Could not complete due to hardware error
**/
EFI_STATUS
EFIAPI
CoreSetWatchdogTimer (
@@ -26,31 +47,6 @@ CoreSetWatchdogTimer (
IN UINTN DataSize,
IN CHAR16 *WatchdogData OPTIONAL
)
/*++
Routine Description:
Sets the system's watchdog timer.
Arguments:
Timeout The number of seconds. Zero disables the timer.
///////following three parameters are left for platform specific using
WatchdogCode The numberic code to log. 0x0 to 0xffff are firmware
DataSize Size of the optional data
WatchdogData Optional Null terminated unicode string followed by binary
data.
Returns:
EFI_SUCCESS Timeout has been set
EFI_NOT_AVAILABLE_YET WatchdogTimer is not available yet
EFI_UNSUPPORTED System does not have a timer (currently not used)
EFI_DEVICE_ERROR Could not complete due to hardware error
--*/
{
EFI_STATUS Status;

View File

@@ -20,29 +20,22 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include <DxeMain.h>
/**
Introduces a fine-grained stall.
@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_NOT_AVAILABLE_YET gMetronome is not available yet
**/
EFI_STATUS
EFIAPI
CoreStall (
IN UINTN Microseconds
)
/*++
Routine Description:
Introduces a fine-grained stall.
Arguments:
Microseconds The number of microseconds to stall execution
Returns:
EFI_SUCCESS - Execution was stalled for at least the requested amount
of microseconds.
EFI_NOT_AVAILABLE_YET - gMetronome is not available yet
--*/
{
UINT32 Counter;
UINT32 Remainder;