OvmfPkg: AcpiTimerLib: Use global variable during PEI_CORE and PEIM

Since in OVMF both PEI_CORE and PEIM run from RAM, and thus may
utilize global variables, use the "Base" AcpiTimerLib instance
(instead of BaseRom) to take advantage of the improved efficiency
of storing the timer register IO address in a global variable.

This leaves only SEC using the BaseRomAcpiTimerLib instance.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gabriel Somlo <somlo@cmu.edu>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16377 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
Gabriel Somlo
2014-11-14 00:38:35 +00:00
committed by jljusten
parent 170ef2d916
commit f122712b42
6 changed files with 30 additions and 18 deletions

View File

@@ -20,7 +20,7 @@
FILE_GUID = FB648CF5-91BE-4737-9023-FD807AC6D96D
MODULE_TYPE = BASE
VERSION_STRING = 1.0
LIBRARY_CLASS = TimerLib|DXE_CORE DXE_SMM_DRIVER UEFI_DRIVER UEFI_APPLICATION SMM_CORE
LIBRARY_CLASS = TimerLib|PEI_CORE PEIM DXE_CORE DXE_SMM_DRIVER UEFI_DRIVER UEFI_APPLICATION SMM_CORE
CONSTRUCTOR = AcpiTimerLibConstructor
[Sources]
@@ -31,6 +31,9 @@
MdePkg/MdePkg.dec
OvmfPkg/OvmfPkg.dec
[Pcd]
gUefiOvmfPkgTokenSpaceGuid.PcdAcpiPmBaseAddress
[LibraryClasses]
BaseLib
PciLib