2019-08-12 06:34:39 +02:00
|
|
|
## @file
|
|
|
|
# Base CPU Timer Library
|
|
|
|
#
|
2024-03-20 08:33:49 +01:00
|
|
|
# Provides basic timer support.
|
|
|
|
#
|
|
|
|
# In x86, using CPUID Leaf 0x15 XTAL frequency. The performance
|
2019-08-12 06:34:39 +02:00
|
|
|
# counter features are provided by the processors time stamp counter.
|
|
|
|
#
|
2024-03-20 08:33:49 +01:00
|
|
|
# In LoongArch64, using CPUCFG 0x4 and 0x5 for Stable Counter frequency.
|
|
|
|
#
|
2021-04-10 17:23:16 +02:00
|
|
|
# Copyright (c) 2021, Intel Corporation. All rights reserved.<BR>
|
2024-03-20 08:33:49 +01:00
|
|
|
# Copyright (c) 2024, Loongson Technology Corporation Limited. All rights reserved.<BR>
|
2019-08-12 06:34:39 +02:00
|
|
|
# SPDX-License-Identifier: BSD-2-Clause-Patent
|
|
|
|
#
|
|
|
|
##
|
|
|
|
|
|
|
|
[Defines]
|
|
|
|
INF_VERSION = 0x00010005
|
|
|
|
BASE_NAME = BaseCpuTimerLib
|
|
|
|
FILE_GUID = F10B5B91-D15A-496C-B044-B5235721AA08
|
|
|
|
MODULE_TYPE = BASE
|
|
|
|
VERSION_STRING = 1.0
|
2021-04-10 17:23:16 +02:00
|
|
|
LIBRARY_CLASS = TimerLib
|
2019-08-12 06:34:39 +02:00
|
|
|
MODULE_UNI_FILE = BaseCpuTimerLib.uni
|
|
|
|
|
2024-03-20 08:33:49 +01:00
|
|
|
[Sources.IA32, Sources.X64]
|
2019-08-12 06:34:39 +02:00
|
|
|
CpuTimerLib.c
|
|
|
|
BaseCpuTimerLib.c
|
|
|
|
|
2024-03-20 08:33:49 +01:00
|
|
|
[Sources.LoongArch64]
|
|
|
|
LoongArch64/CpuTimerLib.c
|
|
|
|
|
2019-08-12 06:34:39 +02:00
|
|
|
[Packages]
|
|
|
|
MdePkg/MdePkg.dec
|
|
|
|
UefiCpuPkg/UefiCpuPkg.dec
|
|
|
|
|
|
|
|
[LibraryClasses]
|
|
|
|
BaseLib
|
|
|
|
DebugLib
|
2024-03-08 08:20:55 +01:00
|
|
|
PcdLib
|
2019-08-12 06:34:39 +02:00
|
|
|
|
2024-03-20 08:33:49 +01:00
|
|
|
[LibraryClasses.LoongArch64]
|
|
|
|
SafeIntLib
|
|
|
|
|
2019-08-12 06:34:39 +02:00
|
|
|
[Pcd]
|
|
|
|
gUefiCpuPkgTokenSpaceGuid.PcdCpuCoreCrystalClockFrequency ## CONSUMES
|