]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Library/BasePciLibCf8/PciLib.c
Sync with other libs
[mirror_edk2.git] / MdePkg / Library / BasePciLibCf8 / PciLib.c
index 5cfa952b124a09faea74df5017820762984b3e4d..13c76c047f6628018d4c9e08494d1b0e9a119e47 100644 (file)
   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
-  Module Name:  PciLib.c\r
-\r
 **/\r
 \r
+\r
+#include <Base.h>\r
+\r
+\r
+#include <Library/PciLib.h>\r
+#include <Library/PciCf8Lib.h>\r
+\r
 /**\r
   Reads an 8-bit PCI configuration register.\r
 \r
@@ -1011,8 +1016,7 @@ PciBitFieldAndThenOr32 (
 \r
   If StartAddress > 0x0FFFFFFF, then ASSERT().\r
   If ((StartAddress & 0xFFF) + Size) > 0x1000, then ASSERT().\r
-  If (StartAddress + Size - 1)  > 0x0FFFFFFF, then ASSERT().\r
-  If Buffer is NULL, then ASSERT().\r
+  If Size > 0 and Buffer is NULL, then ASSERT().\r
 \r
   @param  StartAddress  Starting address that encodes the PCI Bus, Device,\r
                         Function and Register.\r
@@ -1047,8 +1051,7 @@ PciReadBuffer (
 \r
   If StartAddress > 0x0FFFFFFF, then ASSERT().\r
   If ((StartAddress & 0xFFF) + Size) > 0x1000, then ASSERT().\r
-  If (StartAddress + Size - 1)  > 0x0FFFFFFF, then ASSERT().\r
-  If Buffer is NULL, then ASSERT().\r
+  If Size > 0 and Buffer is NULL, then ASSERT().\r
 \r
   @param  StartAddress  Starting address that encodes the PCI Bus, Device,\r
                         Function and Register.\r