summaryrefslogtreecommitdiff
path: root/OvmfPkg
diff options
context:
space:
mode:
Diffstat (limited to 'OvmfPkg')
-rw-r--r--OvmfPkg/PlatformPei/Platform.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/OvmfPkg/PlatformPei/Platform.c b/OvmfPkg/PlatformPei/Platform.c
index 833f62adf..66bb0984c 100644
--- a/OvmfPkg/PlatformPei/Platform.c
+++ b/OvmfPkg/PlatformPei/Platform.c
@@ -31,6 +31,7 @@
#include <Guid/MemoryTypeInformation.h>
#include "Platform.h"
+#include "Cmos.h"
EFI_MEMORY_TYPE_INFORMATION mDefaultMemoryTypeInformation[] = {
{ EfiACPIMemoryNVS, 0x004 },
@@ -200,6 +201,27 @@ ReserveEmuVariableNvStore (
}
+VOID
+DebugDumpCmos (
+ VOID
+ )
+{
+ UINTN Loop;
+
+ DEBUG ((EFI_D_INFO, "CMOS:\n"));
+
+ for (Loop = 0; Loop < 0x80; Loop++) {
+ if ((Loop % 0x10) == 0) {
+ DEBUG ((EFI_D_INFO, "%02x:", Loop));
+ }
+ DEBUG ((EFI_D_INFO, " %02x", CmosRead8 (Loop)));
+ if ((Loop % 0x10) == 0xf) {
+ DEBUG ((EFI_D_INFO, "\n"));
+ }
+ }
+}
+
+
/**
Perform Platform PEI initialization.
@@ -220,6 +242,8 @@ InitializePlatform (
DEBUG ((EFI_D_ERROR, "Platform PEIM Loaded\n"));
+ DebugDumpCmos ();
+
TopOfMemory = MemDetect ();
ReserveEmuVariableNvStore ();