Move BaseCachingPciExpressLib library from ArmVirtPkg to under OvmfPkg. RISC-V Virt platform can leverage the same library to access PCI Express registers through PCI Express base address set in PcdPciExpressBaseAddress and cached in a global variable.
Signed-off-by: Abner Chang <[email protected]> Cc: Daniel Schaefer <[email protected]> Cc: Sunil V L <[email protected]> Cc: Ard Biesheuvel <[email protected]> Cc: Jiewen Yao <[email protected]> Cc: Jordan Justen <[email protected]> Cc: Gerd Hoffmann <[email protected]> --- ArmVirtPkg/ArmVirt.dsc.inc | 2 +- ArmVirtPkg/ArmVirtKvmTool.dsc | 6 +++--- .../BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf | 0 .../Library/BaseCachingPciExpressLib/PciExpressLib.c | 0 4 files changed, 4 insertions(+), 4 deletions(-) rename {ArmVirtPkg => OvmfPkg}/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf (100%) rename {ArmVirtPkg => OvmfPkg}/Library/BaseCachingPciExpressLib/PciExpressLib.c (100%) diff --git a/ArmVirtPkg/ArmVirt.dsc.inc b/ArmVirtPkg/ArmVirt.dsc.inc index 5a1598d90c..4db8ad5a79 100644 --- a/ArmVirtPkg/ArmVirt.dsc.inc +++ b/ArmVirtPkg/ArmVirt.dsc.inc @@ -141,7 +141,7 @@ # PCI Libraries PciLib|MdePkg/Library/BasePciLibPciExpress/BasePciLibPciExpress.inf - PciExpressLib|ArmVirtPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf + PciExpressLib|OvmfPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf PciCapLib|OvmfPkg/Library/BasePciCapLib/BasePciCapLib.inf PciCapPciSegmentLib|OvmfPkg/Library/BasePciCapPciSegmentLib/BasePciCapPciSegmentLib.inf PciCapPciIoLib|OvmfPkg/Library/UefiPciCapPciIoLib/UefiPciCapPciIoLib.inf diff --git a/ArmVirtPkg/ArmVirtKvmTool.dsc b/ArmVirtPkg/ArmVirtKvmTool.dsc index 9d23072d8f..4a54d13735 100644 --- a/ArmVirtPkg/ArmVirtKvmTool.dsc +++ b/ArmVirtPkg/ArmVirtKvmTool.dsc @@ -339,17 +339,17 @@ ArmPkg/Drivers/ArmPciCpuIo2Dxe/ArmPciCpuIo2Dxe.inf { <LibraryClasses> NULL|OvmfPkg/Fdt/FdtPciPcdProducerLib/FdtPciPcdProducerLib.inf - NULL|ArmVirtPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf + NULL|OvmfPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf } MdeModulePkg/Bus/Pci/PciHostBridgeDxe/PciHostBridgeDxe.inf { <LibraryClasses> NULL|OvmfPkg/Fdt/FdtPciPcdProducerLib/FdtPciPcdProducerLib.inf - NULL|ArmVirtPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf + NULL|OvmfPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf } MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf { <LibraryClasses> NULL|OvmfPkg/Fdt/FdtPciPcdProducerLib/FdtPciPcdProducerLib.inf - NULL|ArmVirtPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf + NULL|OvmfPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf } OvmfPkg/VirtioPciDeviceDxe/VirtioPciDeviceDxe.inf OvmfPkg/Virtio10Dxe/Virtio10.inf diff --git a/ArmVirtPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf b/OvmfPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf similarity index 100% rename from ArmVirtPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf rename to OvmfPkg/Library/BaseCachingPciExpressLib/BaseCachingPciExpressLib.inf diff --git a/ArmVirtPkg/Library/BaseCachingPciExpressLib/PciExpressLib.c b/OvmfPkg/Library/BaseCachingPciExpressLib/PciExpressLib.c similarity index 100% rename from ArmVirtPkg/Library/BaseCachingPciExpressLib/PciExpressLib.c rename to OvmfPkg/Library/BaseCachingPciExpressLib/PciExpressLib.c -- 2.31.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#86212): https://edk2.groups.io/g/devel/message/86212 Mute This Topic: https://groups.io/mt/88770178/21656 Group Owner: [email protected] Unsubscribe: https://edk2.groups.io/g/devel/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
