Revision: 17714
          http://sourceforge.net/p/edk2/code/17714
Author:   gdong1
Date:     2015-06-25 16:00:29 +0000 (Thu, 25 Jun 2015)
Log Message:
-----------
CorebootModulePkg: Get power management register addresses.

This patch will get power management event register address and power 
management GPE enable register address.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Guo Dong <[email protected]>
Reviewed-by: Maurice Ma <[email protected]>

Modified Paths:
--------------
    trunk/edk2/CorebootModulePkg/CbSupportPei/CbSupportPei.c
    trunk/edk2/CorebootModulePkg/Include/Guid/AcpiBoardInfoGuid.h
    trunk/edk2/CorebootModulePkg/Include/Library/CbParseLib.h

Modified: trunk/edk2/CorebootModulePkg/CbSupportPei/CbSupportPei.c
===================================================================
--- trunk/edk2/CorebootModulePkg/CbSupportPei/CbSupportPei.c    2015-06-25 
14:49:06 UTC (rev 17713)
+++ trunk/edk2/CorebootModulePkg/CbSupportPei/CbSupportPei.c    2015-06-25 
16:00:29 UTC (rev 17714)
@@ -171,6 +171,8 @@
   FRAME_BUFFER_INFO*   pFbInfo;
   ACPI_BOARD_INFO*     pAcpiBoardInfo;
   UINTN                PmCtrlRegBase, PmTimerRegBase, ResetRegAddress, 
ResetValue;
+  UINTN                PmEvtBase;
+  UINTN                PmGpeEnBase;
 
   LowMemorySize = 0;
   HighMemorySize = 0;
@@ -355,7 +357,7 @@
   //
   // Create guid hob for acpi board information
   //
-  Status = CbParseFadtInfo (&PmCtrlRegBase, &PmTimerRegBase, &ResetRegAddress, 
&ResetValue);
+  Status = CbParseFadtInfo (&PmCtrlRegBase, &PmTimerRegBase, &ResetRegAddress, 
&ResetValue, &PmEvtBase, &PmGpeEnBase);
   ASSERT_EFI_ERROR (Status);
   pAcpiBoardInfo = NULL;
   pAcpiBoardInfo = BuildGuidHob (&gUefiAcpiBoardInfoGuid, sizeof 
(ACPI_BOARD_INFO));
@@ -364,6 +366,8 @@
   pAcpiBoardInfo->PmTimerRegBase = (UINT64)PmTimerRegBase;
   pAcpiBoardInfo->ResetRegAddress = (UINT64)ResetRegAddress;
   pAcpiBoardInfo->ResetValue = (UINT8)ResetValue;
+  pAcpiBoardInfo->PmEvtBase = (UINT64)PmEvtBase;
+  pAcpiBoardInfo->PmGpeEnBase = (UINT64)PmGpeEnBase;
   DEBUG ((EFI_D_ERROR, "Create acpi board info guid hob\n"));
 
   //

Modified: trunk/edk2/CorebootModulePkg/Include/Guid/AcpiBoardInfoGuid.h
===================================================================
--- trunk/edk2/CorebootModulePkg/Include/Guid/AcpiBoardInfoGuid.h       
2015-06-25 14:49:06 UTC (rev 17713)
+++ trunk/edk2/CorebootModulePkg/Include/Guid/AcpiBoardInfoGuid.h       
2015-06-25 16:00:29 UTC (rev 17714)
@@ -20,7 +20,9 @@
 ///
 extern EFI_GUID gUefiAcpiBoardInfoGuid;
 
-typedef struct {  
+typedef struct {
+  UINT64             PmEvtBase;
+  UINT64             PmGpeEnBase;
   UINT64             PmCtrlRegBase;
   UINT64             PmTimerRegBase;
   UINT64             ResetRegAddress;

Modified: trunk/edk2/CorebootModulePkg/Include/Library/CbParseLib.h
===================================================================
--- trunk/edk2/CorebootModulePkg/Include/Library/CbParseLib.h   2015-06-25 
14:49:06 UTC (rev 17713)
+++ trunk/edk2/CorebootModulePkg/Include/Library/CbParseLib.h   2015-06-25 
16:00:29 UTC (rev 17714)
@@ -91,6 +91,8 @@
   @param  pPmTimerReg        Pointer to the address of power management timer 
register
   @param  pResetReg          Pointer to the address of system reset register
   @param  pResetValue        Pointer to the value to be writen to the system 
reset register
+  @param  pPmEvtReg          Pointer to the address of power management event 
register
+  @param  pPmGpeEnReg        Pointer to the address of power management GPE 
enable register
 
   @retval RETURN_SUCCESS     Successfully find out all the required fadt 
information.
   @retval RETURN_NOT_FOUND   Failed to find the fadt table.
@@ -101,7 +103,9 @@
   IN UINTN*     pPmCtrlReg,
   IN UINTN*     pPmTimerReg,
   IN UINTN*     pResetReg,
-  IN UINTN*     pResetValue
+  IN UINTN*     pResetValue,
+  IN UINTN*     pPmEvtReg,
+  IN UINTN*     pPmGpeEnReg
   );
   
 /**


------------------------------------------------------------------------------
Monitor 25 network devices or servers for free with OpManager!
OpManager is web-based network management software that monitors 
network devices and physical & virtual servers, alerts via email & sms 
for fault. Monitor 25 devices for free with no restriction. Download now
http://ad.doubleclick.net/ddm/clk/292181274;119417398;o
_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits

Reply via email to