2 Emu Emulation Architectural Protocol Driver as defined in UEFI/PI.
3 This Timer module uses an UNIX Thread to simulate the timer-tick driven
6 Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>
7 Portions copyright (c) 2010 - 2011, Apple Inc. All rights reserved.
8 SPDX-License-Identifier: BSD-2-Clause-Patent
20 // Legal timer value range in 100 ns units
22 #define TIMER_MINIMUM_VALUE 0
23 #define TIMER_MAXIMUM_VALUE (0x100000000ULL - 1)
26 // Default timer value in 100 ns units (50 ms)
28 #define DEFAULT_TIMER_TICK_DURATION 500000
31 // Function Prototypes
35 EmuTimerDriverInitialize (
36 IN EFI_HANDLE ImageHandle
,
37 IN EFI_SYSTEM_TABLE
*SystemTable
42 EmuTimerDriverRegisterHandler (
43 IN EFI_TIMER_ARCH_PROTOCOL
*This
,
44 IN EFI_TIMER_NOTIFY NotifyFunction
49 EmuTimerDriverSetTimerPeriod (
50 IN EFI_TIMER_ARCH_PROTOCOL
*This
,
56 EmuTimerDriverGetTimerPeriod (
57 IN EFI_TIMER_ARCH_PROTOCOL
*This
,
58 OUT UINT64
*TimerPeriod
63 EmuTimerDriverGenerateSoftInterrupt (
64 IN EFI_TIMER_ARCH_PROTOCOL
*This