21 OUT UINT32 *TimerFrequency,
25 UINTN ApicTimerDivisor;
27 UINT32 ApicTimerFrequency;
31 ApicTimerFrequency =
PcdGet32 (PcdFSBClock) / (UINT32)ApicTimerDivisor;
51 DEBUG ((DEBUG_INFO,
"Debug Timer: FSB Clock = %d\n",
PcdGet32 (PcdFSBClock)));
52 DEBUG ((DEBUG_INFO,
"Debug Timer: Divisor = %d\n", ApicTimerDivisor));
53 DEBUG ((DEBUG_INFO,
"Debug Timer: Frequency = %d\n", ApicTimerFrequency));
54 DEBUG ((DEBUG_INFO,
"Debug Timer: InitialCount = %d\n", InitialCount));
57 if (TimerFrequency !=
NULL) {
58 *TimerFrequency = ApicTimerFrequency;
80 IN BOOLEAN EnableStatus
83 BOOLEAN OldDebugTimerInterruptState;
87 if (OldDebugTimerInterruptState != EnableStatus) {
104 return OldDebugTimerInterruptState;
120 IN UINT32 TimerCycle,
122 IN UINT32 TimeoutTicker
135 if (CurrentTimer <= Timer) {
136 Delta = Timer - CurrentTimer;
141 Delta = TimerCycle - (CurrentTimer - Timer) + 1;
144 return (BOOLEAN)(Delta >= TimeoutTicker);
UINT64 EFIAPI DivU64x32(IN UINT64 Dividend, IN UINT32 Divisor)
UINT64 EFIAPI MultU64x64(IN UINT64 Multiplicand, IN UINT64 Multiplier)
VOID EFIAPI CpuPause(VOID)
BOOLEAN EFIAPI SaveAndSetDebugTimerInterrupt(IN BOOLEAN EnableStatus)
UINT32 InitializeDebugTimer(OUT UINT32 *TimerFrequency, IN BOOLEAN DumpFlag)
BOOLEAN IsDebugTimerTimeout(IN UINT32 TimerCycle, IN UINT32 Timer, IN UINT32 TimeoutTicker)
VOID EFIAPI InitializeLocalApicSoftwareEnable(IN BOOLEAN Enable)
BOOLEAN EFIAPI GetApicTimerInterruptState(VOID)
VOID EFIAPI GetApicTimerState(OUT UINTN *DivideValue OPTIONAL, OUT BOOLEAN *PeriodicMode OPTIONAL, OUT UINT8 *Vector OPTIONAL)
VOID EFIAPI EnableApicTimerInterrupt(VOID)
VOID EFIAPI InitializeApicTimer(IN UINTN DivideValue, IN UINT32 InitCount, IN BOOLEAN PeriodicMode, IN UINT8 Vector)
UINT32 EFIAPI GetApicTimerCurrentCount(VOID)
VOID EFIAPI DisableApicTimerInterrupt(VOID)
#define DEBUG(Expression)
#define PcdGet32(TokenName)