PciLib:
For PciRead/WriteBuffer(): A fix to handle boundary cases when Size is 0; DevicePathLib: For FileDevicePath(): Change to use AppendDevicePath () in place of AppendDevicePathNode(). PrintLib: For type %p, according to current MWG, it should ignore flag 0, +, space, l, & L Misc: Fix a bug in EBC interpreter for Ia32. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@796 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@@ -1196,11 +1196,16 @@ PciExpressReadBuffer (
|
||||
|
||||
ASSERT_INVALID_PCI_ADDRESS (StartAddress);
|
||||
ASSERT (((StartAddress & 0xFFF) + Size) <= 0x1000);
|
||||
ASSERT ((Buffer != NULL) || (Size == 0));
|
||||
|
||||
if (Size == 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
ASSERT (Buffer != NULL);
|
||||
|
||||
EndAddress = StartAddress + Size;
|
||||
|
||||
if ((StartAddress < EndAddress) && ((StartAddress & 1) != 0)) {
|
||||
if ((StartAddress & 1) != 0) {
|
||||
//
|
||||
// Read a byte if StartAddress is byte aligned
|
||||
//
|
||||
@@ -1282,11 +1287,16 @@ PciExpressWriteBuffer (
|
||||
|
||||
ASSERT_INVALID_PCI_ADDRESS (StartAddress);
|
||||
ASSERT (((StartAddress & 0xFFF) + Size) <= 0x1000);
|
||||
ASSERT ((Buffer != NULL) || (Size == 0));
|
||||
|
||||
if (Size == 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
ASSERT (Buffer != NULL);
|
||||
|
||||
EndAddress = StartAddress + Size;
|
||||
|
||||
if ((StartAddress < EndAddress) && ((StartAddress & 1) != 0)) {
|
||||
if ((StartAddress & 1) != 0) {
|
||||
//
|
||||
// Write a byte if StartAddress is byte aligned
|
||||
//
|
||||
|
Reference in New Issue
Block a user