Fix bug in PciCfg to support PCI express address.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@3549 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@@ -53,7 +53,7 @@ PciCfgRead (
|
||||
{
|
||||
UINTN PciLibAddress;
|
||||
|
||||
PciLibAddress = COMMON_TO_PCILIB_ADDRESS (Address);
|
||||
PciLibAddress = PciCfgAddressConvert ((EFI_PEI_PCI_CFG_PPI_PCI_ADDRESS *) &Address);
|
||||
switch (Width) {
|
||||
case EfiPeiPciCfgWidthUint8:
|
||||
* (UINT8 *) Buffer = PciRead8 (PciLibAddress);
|
||||
@@ -103,7 +103,7 @@ PciCfgWrite (
|
||||
{
|
||||
UINTN PciLibAddress;
|
||||
|
||||
PciLibAddress = COMMON_TO_PCILIB_ADDRESS (Address);
|
||||
PciLibAddress = PciCfgAddressConvert ((EFI_PEI_PCI_CFG_PPI_PCI_ADDRESS *) &Address);
|
||||
switch (Width) {
|
||||
case EfiPeiPciCfgWidthUint8:
|
||||
PciWrite8 (PciLibAddress, *(UINT8 *) Buffer);
|
||||
@@ -153,7 +153,7 @@ PciCfgModify (
|
||||
{
|
||||
UINTN PciLibAddress;
|
||||
|
||||
PciLibAddress = COMMON_TO_PCILIB_ADDRESS (Address);
|
||||
PciLibAddress = PciCfgAddressConvert ((EFI_PEI_PCI_CFG_PPI_PCI_ADDRESS *) &Address);
|
||||
switch (Width) {
|
||||
case EfiPeiPciCfgWidthUint8:
|
||||
PciAndThenOr8 (PciLibAddress, (UINT8)~ClearBits, (UINT8)SetBits);
|
||||
|
Reference in New Issue
Block a user