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
17 // Legal timer value range in 100 ns units
19 #define TIMER_MINIMUM_VALUE 0
20 #define TIMER_MAXIMUM_VALUE (0x100000000ULL - 1)
23 // Default timer value in 100 ns units (50 ms)
25 #define DEFAULT_TIMER_TICK_DURATION 500000
28 // Function Prototypes
32 EmuTimerDriverInitialize (
33 IN EFI_HANDLE ImageHandle
,
34 IN EFI_SYSTEM_TABLE
*SystemTable
39 EmuTimerDriverRegisterHandler (
40 IN EFI_TIMER_ARCH_PROTOCOL
*This
,
41 IN EFI_TIMER_NOTIFY NotifyFunction
46 EmuTimerDriverSetTimerPeriod (
47 IN EFI_TIMER_ARCH_PROTOCOL
*This
,
53 EmuTimerDriverGetTimerPeriod (
54 IN EFI_TIMER_ARCH_PROTOCOL
*This
,
55 OUT UINT64
*TimerPeriod
60 EmuTimerDriverGenerateSoftInterrupt (
61 IN EFI_TIMER_ARCH_PROTOCOL
*This