mirror of https://github.com/acidanthera/audk.git
Add 3 macros to manager Timer events.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6563 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
8dd2a792d6
commit
52ca0d9816
|
@ -29,6 +29,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
|||
#include <Protocol/DriverDiagnostics.h>
|
||||
#include <Protocol/DriverDiagnostics2.h>
|
||||
|
||||
#include <Library/BaseLib.h>
|
||||
|
||||
///
|
||||
/// Unicode String Table
|
||||
///
|
||||
|
@ -56,6 +58,45 @@ typedef struct {
|
|||
} EFI_LOCK;
|
||||
|
||||
|
||||
/**
|
||||
Macro that returns the number of 100 ns units for a specified number of microseconds.
|
||||
Useful for managing EFI timer events.
|
||||
|
||||
@param Microseconds Number of microseonds.
|
||||
|
||||
@return The number of 100 ns units equivalent to the number of microseconds specified
|
||||
by Microseconds.
|
||||
|
||||
**/
|
||||
#define EFI_TIMER_PERIOD_MICROSECONDS(Microseconds) MultU64x32((UINT64)(Microseconds), 10)
|
||||
|
||||
|
||||
/**
|
||||
Macro that returns the number of 100 ns units for a specified number of milliseoconds.
|
||||
Useful for managing EFI timer events.
|
||||
|
||||
@param Milliseconds Number of milliseconds.
|
||||
|
||||
@return The number of 100 ns units equivalent to the number of milliseconds specified
|
||||
by Milliseconds.
|
||||
|
||||
**/
|
||||
#define EFI_TIMER_PERIOD_MILLISECONDS(Milliseconds) MultU64x32((UINT64)(Milliseconds), 10000)
|
||||
|
||||
|
||||
/**
|
||||
Macro that returns the number of 100 ns units for a specified number of seoconds.
|
||||
Useful for managing EFI timer events.
|
||||
|
||||
@param Seconds Number of seconds.
|
||||
|
||||
@return The number of 100 ns units equivalent to the number of seconds specified
|
||||
by Seconds.
|
||||
|
||||
**/
|
||||
#define EFI_TIMER_PERIOD_SECONDS(Seconds) MultU64x32((UINT64)(Seconds), 10000000)
|
||||
|
||||
|
||||
/**
|
||||
This function searches the list of configuration tables stored in the EFI System
|
||||
Table for a table with a GUID that matches TableGuid. If a match is found,
|
||||
|
|
Loading…
Reference in New Issue