summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--OvmfPkg/Include/OvmfPlatforms.h10
-rw-r--r--OvmfPkg/Library/AcpiTimerLib/BaseAcpiTimerLib.c10
-rw-r--r--OvmfPkg/Library/AcpiTimerLib/BaseRomAcpiTimerLib.c10
-rw-r--r--OvmfPkg/Library/AcpiTimerLib/DxeAcpiTimerLib.c10
4 files changed, 10 insertions, 30 deletions
diff --git a/OvmfPkg/Include/OvmfPlatforms.h b/OvmfPkg/Include/OvmfPlatforms.h
index 19f0adb897..43ab01d57c 100644
--- a/OvmfPkg/Include/OvmfPlatforms.h
+++ b/OvmfPkg/Include/OvmfPlatforms.h
@@ -27,4 +27,14 @@
#define OVMF_HOSTBRIDGE_DID \
PCI_LIB_ADDRESS (0, 0, 0, PCI_DEVICE_ID_OFFSET)
+//
+// Common bits in same-purpose registers
+//
+#define PMBA_RTE BIT0
+
+//
+// Common IO ports relative to the Power Management Base Address
+//
+#define ACPI_TIMER_OFFSET 0x8
+
#endif
diff --git a/OvmfPkg/Library/AcpiTimerLib/BaseAcpiTimerLib.c b/OvmfPkg/Library/AcpiTimerLib/BaseAcpiTimerLib.c
index 490cf803be..c3c50c05d3 100644
--- a/OvmfPkg/Library/AcpiTimerLib/BaseAcpiTimerLib.c
+++ b/OvmfPkg/Library/AcpiTimerLib/BaseAcpiTimerLib.c
@@ -19,16 +19,6 @@
#include <OvmfPlatforms.h>
//
-// Power Management PCI Configuration Register fields
-//
-#define PMBA_RTE BIT0
-
-//
-// Offset in the Power Management Base Address to the ACPI Timer
-//
-#define ACPI_TIMER_OFFSET 0x8
-
-//
// Cached ACPI Timer IO Address
//
STATIC UINT32 mAcpiTimerIoAddr;
diff --git a/OvmfPkg/Library/AcpiTimerLib/BaseRomAcpiTimerLib.c b/OvmfPkg/Library/AcpiTimerLib/BaseRomAcpiTimerLib.c
index 50a3391b75..5164769f60 100644
--- a/OvmfPkg/Library/AcpiTimerLib/BaseRomAcpiTimerLib.c
+++ b/OvmfPkg/Library/AcpiTimerLib/BaseRomAcpiTimerLib.c
@@ -19,16 +19,6 @@
#include <Library/PcdLib.h>
#include <OvmfPlatforms.h>
-//
-// Power Management PCI Configuration Register fields
-//
-#define PMBA_RTE BIT0
-
-//
-// Offset in the Power Management Base Address to the ACPI Timer
-//
-#define ACPI_TIMER_OFFSET 0x8
-
/**
The constructor function enables ACPI IO space.
diff --git a/OvmfPkg/Library/AcpiTimerLib/DxeAcpiTimerLib.c b/OvmfPkg/Library/AcpiTimerLib/DxeAcpiTimerLib.c
index 0c42ed2c5c..e673434ae6 100644
--- a/OvmfPkg/Library/AcpiTimerLib/DxeAcpiTimerLib.c
+++ b/OvmfPkg/Library/AcpiTimerLib/DxeAcpiTimerLib.c
@@ -19,16 +19,6 @@
#include <OvmfPlatforms.h>
//
-// Power Management PCI Configuration Register fields
-//
-#define PMBA_RTE BIT0
-
-//
-// Offset in the Power Management Base Address to the ACPI Timer
-//
-#define ACPI_TIMER_OFFSET 0x8
-
-//
// Cached ACPI Timer IO Address
//
STATIC UINT32 mAcpiTimerIoAddr;