Revision: 16952
          http://sourceforge.net/p/edk2/code/16952
Author:   lgao4
Date:     2015-02-28 05:34:38 +0000 (Sat, 28 Feb 2015)
Log Message:
-----------
PcAtChipsetPkg: Update BaseAcpiTimerLib

Introduce new PcdAcpiIoPortBaseAddressMask to mask BITS ACPI IO Port Base 
Address.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <[email protected]>
Reviewed-by: Star Zeng <[email protected]>

Modified Paths:
--------------
    trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/AcpiTimerLib.c
    trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/BaseAcpiTimerLib.inf
    trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/DxeAcpiTimerLib.inf
    trunk/edk2/PcAtChipsetPkg/PcAtChipsetPkg.dec
    trunk/edk2/PcAtChipsetPkg/PcAtChipsetPkg.uni

Modified: trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/AcpiTimerLib.c
===================================================================
--- trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/AcpiTimerLib.c       
2015-02-28 02:36:06 UTC (rev 16951)
+++ trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/AcpiTimerLib.c       
2015-02-28 05:34:38 UTC (rev 16952)
@@ -1,7 +1,7 @@
 /** @file
   ACPI Timer implements one instance of Timer Library.
 
-  Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
+  Copyright (c) 2013 - 2015, Intel Corporation. All rights reserved.<BR>
   This program and the accompanying materials
   are licensed and made available under the terms and conditions of the BSD 
License
   which accompanies this distribution.  The full text of the license may be 
found at
@@ -118,11 +118,11 @@
 {
   UINT16  Port;
   
-  Port = PcdGet16 (PcdAcpiIoPciBarRegisterOffset);
+  Port = PcdGet16 (PcdAcpiIoPortBaseAddress);
   
   //
   // If the register offset to the BAR for the ACPI I/O Port Base Address is 
not 0x0000, then 
-  // read the PCI register for the APCI BAR value in case the BAR has been 
programmed to a 
+  // read the PCI register for the ACPI BAR value in case the BAR has been 
programmed to a 
   // value other than PcdAcpiIoPortBaseAddress
   //
   if (PcdGet16 (PcdAcpiIoPciBarRegisterOffset) != 0x0000) {
@@ -134,7 +134,7 @@
                         ));
   }
   
-  return (Port & ~BIT0) + PcdGet16 (PcdAcpiPm1TmrOffset);
+  return (Port & PcdGet16 (PcdAcpiIoPortBaseAddressMask)) + PcdGet16 
(PcdAcpiPm1TmrOffset);
 }
 
 /**

Modified: trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/BaseAcpiTimerLib.inf
===================================================================
--- trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/BaseAcpiTimerLib.inf 
2015-02-28 02:36:06 UTC (rev 16951)
+++ trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/BaseAcpiTimerLib.inf 
2015-02-28 05:34:38 UTC (rev 16952)
@@ -4,7 +4,7 @@
 #  Provides basic timer support using the ACPI timer hardware.  The performance
 #  counter features are provided by the processors time stamp counter. 
 #
-#  Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
+#  Copyright (c) 2013 - 2015, Intel Corporation. All rights reserved.<BR>
 #  This program and the accompanying materials
 #  are licensed and made available under the terms and conditions of the BSD 
License
 #  which accompanies this distribution.  The full text of the license may be 
found at
@@ -49,3 +49,4 @@
   gPcAtChipsetPkgTokenSpaceGuid.PcdAcpiIoPciBarRegisterOffset     ## CONSUMES
   gPcAtChipsetPkgTokenSpaceGuid.PcdAcpiIoPortBaseAddress          ## CONSUMES
   gPcAtChipsetPkgTokenSpaceGuid.PcdAcpiPm1TmrOffset               ## CONSUMES
+  gPcAtChipsetPkgTokenSpaceGuid.PcdAcpiIoPortBaseAddressMask      ## CONSUMES
\ No newline at end of file

Modified: trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/DxeAcpiTimerLib.inf
===================================================================
--- trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/DxeAcpiTimerLib.inf  
2015-02-28 02:36:06 UTC (rev 16951)
+++ trunk/edk2/PcAtChipsetPkg/Library/AcpiTimerLib/DxeAcpiTimerLib.inf  
2015-02-28 05:34:38 UTC (rev 16952)
@@ -4,7 +4,7 @@
 #  Provides basic timer support using the ACPI timer hardware.  The performance
 #  counter features are provided by the processors time stamp counter. 
 #
-#  Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
+#  Copyright (c) 2013 - 2015, Intel Corporation. All rights reserved.<BR>
 #  This program and the accompanying materials
 #  are licensed and made available under the terms and conditions of the BSD 
License
 #  which accompanies this distribution.  The full text of the license may be 
found at
@@ -49,3 +49,4 @@
   gPcAtChipsetPkgTokenSpaceGuid.PcdAcpiIoPciBarRegisterOffset     ## CONSUMES
   gPcAtChipsetPkgTokenSpaceGuid.PcdAcpiIoPortBaseAddress          ## CONSUMES
   gPcAtChipsetPkgTokenSpaceGuid.PcdAcpiPm1TmrOffset               ## CONSUMES
+  gPcAtChipsetPkgTokenSpaceGuid.PcdAcpiIoPortBaseAddressMask      ## CONSUMES
\ No newline at end of file

Modified: trunk/edk2/PcAtChipsetPkg/PcAtChipsetPkg.dec
===================================================================
--- trunk/edk2/PcAtChipsetPkg/PcAtChipsetPkg.dec        2015-02-28 02:36:06 UTC 
(rev 16951)
+++ trunk/edk2/PcAtChipsetPkg/PcAtChipsetPkg.dec        2015-02-28 05:34:38 UTC 
(rev 16952)
@@ -163,5 +163,9 @@
   # @Prompt Offset to 32-bit Timer register in ACPI BAR
   gPcAtChipsetPkgTokenSpaceGuid.PcdAcpiPm1TmrOffset              
|0x0008|UINT16|0x00000017
 
+  ## Defines the bit mask to retrieve ACPI IO Port Base Address
+  # @Prompt ACPI IO Port Base Address Mask
+  gPcAtChipsetPkgTokenSpaceGuid.PcdAcpiIoPortBaseAddressMask     
|0xFFFE|UINT16|0x00000018
+
 [UserExtensions.TianoCore."ExtraFiles"]
   PcAtChipsetPkgExtra.uni
\ No newline at end of file

Modified: trunk/edk2/PcAtChipsetPkg/PcAtChipsetPkg.uni
===================================================================
--- trunk/edk2/PcAtChipsetPkg/PcAtChipsetPkg.uni        2015-02-28 02:36:06 UTC 
(rev 16951)
+++ trunk/edk2/PcAtChipsetPkg/PcAtChipsetPkg.uni        2015-02-28 05:34:38 UTC 
(rev 16952)
@@ -268,4 +268,16 @@
  -\ No newline at end of file
+++++++\ No newline at end of file


------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits

Reply via email to