summaryrefslogtreecommitdiff
path: root/MdePkg/Library/BasePciLibCf8
diff options
context:
space:
mode:
Diffstat (limited to 'MdePkg/Library/BasePciLibCf8')
-rw-r--r--MdePkg/Library/BasePciLibCf8/PciLib.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/MdePkg/Library/BasePciLibCf8/PciLib.c b/MdePkg/Library/BasePciLibCf8/PciLib.c
index 5cfa952b12..7e21e23174 100644
--- a/MdePkg/Library/BasePciLibCf8/PciLib.c
+++ b/MdePkg/Library/BasePciLibCf8/PciLib.c
@@ -1011,8 +1011,7 @@ PciBitFieldAndThenOr32 (
If StartAddress > 0x0FFFFFFF, then ASSERT().
If ((StartAddress & 0xFFF) + Size) > 0x1000, then ASSERT().
- If (StartAddress + Size - 1) > 0x0FFFFFFF, then ASSERT().
- If Buffer is NULL, then ASSERT().
+ If Size > 0 and Buffer is NULL, then ASSERT().
@param StartAddress Starting address that encodes the PCI Bus, Device,
Function and Register.
@@ -1047,8 +1046,7 @@ PciReadBuffer (
If StartAddress > 0x0FFFFFFF, then ASSERT().
If ((StartAddress & 0xFFF) + Size) > 0x1000, then ASSERT().
- If (StartAddress + Size - 1) > 0x0FFFFFFF, then ASSERT().
- If Buffer is NULL, then ASSERT().
+ If Size > 0 and Buffer is NULL, then ASSERT().
@param StartAddress Starting address that encodes the PCI Bus, Device,
Function and Register.