From: Abner Chang Date: Mon, 11 Oct 2021 13:26:23 +0000 (+0800) Subject: ArmPkg: Use PcdPciIoTranslation PCD from MdePkg X-Git-Tag: edk2-stable202202~379 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=7d78a86ecfc6d86244a552b1bad6fb346439116b ArmPkg: Use PcdPciIoTranslation PCD from MdePkg PcdPciIoTranslation PCD is relocated to MdePkg and leveraged by both ARM and RISC-V arch. This patch removes the one from ArmPkg and address the corresponding changes required for other modules under ArmVirtPkg. Signed-off-by: Abner Chang Cc: Ard Biesheuvel Cc: Leif Lindholm Cc: Sami Mujawar Cc: Gerd Hoffmann Cc: Daniel Schaefer Cc: Sunil V L Reviewed-by: Daniel Schaefer Reviewed-by: Sunil V L Acked-by: Gerd Hoffmann --- diff --git a/ArmPkg/ArmPkg.dec b/ArmPkg/ArmPkg.dec index 6ed51edd03..12584fb319 100644 --- a/ArmPkg/ArmPkg.dec +++ b/ArmPkg/ArmPkg.dec @@ -337,7 +337,7 @@ # UINT64 Mmio32CpuBase; // mapping target in 64-bit cpu-physical space # UINT64 Mmio64CpuBase; // mapping target in 64-bit cpu-physical space # - # PcdPciIoTranslation = IoCpuBase - PcdPciIoBase; + # gEfiMdePkgTokenSpaceGuid.PcdPciIoTranslation = IoCpuBase - PcdPciIoBase; # PcdPciMmio32Translation = Mmio32CpuBase - (UINT64)PcdPciMmio32Base; # PcdPciMmio64Translation = Mmio64CpuBase - PcdPciMmio64Base; # @@ -356,7 +356,7 @@ # UINT64 TranslatedMmio64Address; // output parameter # # TranslatedIoAddress = UntranslatedIoAddress + - # PcdPciIoTranslation; + # gEfiMdePkgTokenSpaceGuid.PcdPciIoTranslation; # TranslatedMmio32Address = (UINT64)UntranslatedMmio32Address + # PcdPciMmio32Translation; # TranslatedMmio64Address = UntranslatedMmio64Address + @@ -369,7 +369,6 @@ # gArmTokenSpaceGuid.PcdPciIoBase|0x0|UINT64|0x00000050 gArmTokenSpaceGuid.PcdPciIoSize|0x0|UINT64|0x00000051 - gArmTokenSpaceGuid.PcdPciIoTranslation|0x0|UINT64|0x00000052 gArmTokenSpaceGuid.PcdPciMmio32Base|0x0|UINT32|0x00000053 gArmTokenSpaceGuid.PcdPciMmio32Size|0x0|UINT32|0x00000054 gArmTokenSpaceGuid.PcdPciMmio32Translation|0x0|UINT64|0x00000055 diff --git a/ArmPkg/Drivers/ArmPciCpuIo2Dxe/ArmPciCpuIo2Dxe.inf b/ArmPkg/Drivers/ArmPciCpuIo2Dxe/ArmPciCpuIo2Dxe.inf index 2bc4571d06..9339c2b532 100644 --- a/ArmPkg/Drivers/ArmPciCpuIo2Dxe/ArmPciCpuIo2Dxe.inf +++ b/ArmPkg/Drivers/ArmPciCpuIo2Dxe/ArmPciCpuIo2Dxe.inf @@ -38,7 +38,7 @@ UefiBootServicesTableLib [Pcd] - gArmTokenSpaceGuid.PcdPciIoTranslation + gEfiMdePkgTokenSpaceGuid.PcdPciIoTranslation [Protocols] gEfiCpuIo2ProtocolGuid ## PRODUCES diff --git a/ArmVirtPkg/ArmVirtCloudHv.dsc b/ArmVirtPkg/ArmVirtCloudHv.dsc index ffc6b8ed7c..a6ceef6faf 100644 --- a/ArmVirtPkg/ArmVirtCloudHv.dsc +++ b/ArmVirtPkg/ArmVirtCloudHv.dsc @@ -193,7 +193,7 @@ # PCD and PcdPciDisableBusEnumeration above have not been assigned yet gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress|0xFFFFFFFFFFFFFFFF - gArmTokenSpaceGuid.PcdPciIoTranslation|0 + gEfiMdePkgTokenSpaceGuid.PcdPciIoTranslation|0 gEfiSecurityPkgTokenSpaceGuid.PcdTpmBaseAddress|0x0 diff --git a/ArmVirtPkg/ArmVirtKvmTool.dsc b/ArmVirtPkg/ArmVirtKvmTool.dsc index 745eae347b..ff70509542 100644 --- a/ArmVirtPkg/ArmVirtKvmTool.dsc +++ b/ArmVirtPkg/ArmVirtKvmTool.dsc @@ -184,7 +184,7 @@ # PCD and PcdPciDisableBusEnumeration above have not been assigned yet gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress|0xFFFFFFFFFFFFFFFF - gArmTokenSpaceGuid.PcdPciIoTranslation|0x0 + gEfiMdePkgTokenSpaceGuid.PcdPciIoTranslation|0x0 # # Set video resolution for boot options and for text setup. diff --git a/ArmVirtPkg/ArmVirtQemu.dsc b/ArmVirtPkg/ArmVirtQemu.dsc index 69e2402408..f7e5ea8f74 100644 --- a/ArmVirtPkg/ArmVirtQemu.dsc +++ b/ArmVirtPkg/ArmVirtQemu.dsc @@ -249,7 +249,7 @@ # PCD and PcdPciDisableBusEnumeration above have not been assigned yet gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress|0xFFFFFFFFFFFFFFFF - gArmTokenSpaceGuid.PcdPciIoTranslation|0x0 + gEfiMdePkgTokenSpaceGuid.PcdPciIoTranslation|0x0 # # Set video resolution for boot options and for text setup. diff --git a/ArmVirtPkg/ArmVirtQemuKernel.dsc b/ArmVirtPkg/ArmVirtQemuKernel.dsc index 6ffeabbd34..146b5731fe 100644 --- a/ArmVirtPkg/ArmVirtQemuKernel.dsc +++ b/ArmVirtPkg/ArmVirtQemuKernel.dsc @@ -228,7 +228,7 @@ # PCD and PcdPciDisableBusEnumeration above have not been assigned yet gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress|0xFFFFFFFFFFFFFFFF - gArmTokenSpaceGuid.PcdPciIoTranslation|0x0 + gEfiMdePkgTokenSpaceGuid.PcdPciIoTranslation|0x0 # # Set video resolution for boot options and for text setup. diff --git a/ArmVirtPkg/Library/FdtPciHostBridgeLib/FdtPciHostBridgeLib.inf b/ArmVirtPkg/Library/FdtPciHostBridgeLib/FdtPciHostBridgeLib.inf index 1549f9d884..f149693fa2 100644 --- a/ArmVirtPkg/Library/FdtPciHostBridgeLib/FdtPciHostBridgeLib.inf +++ b/ArmVirtPkg/Library/FdtPciHostBridgeLib/FdtPciHostBridgeLib.inf @@ -48,7 +48,7 @@ gArmTokenSpaceGuid.PcdPciMmio64Translation [Pcd] - gArmTokenSpaceGuid.PcdPciIoTranslation + gEfiMdePkgTokenSpaceGuid.PcdPciIoTranslation gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress [Depex] diff --git a/ArmVirtPkg/Library/FdtPciPcdProducerLib/FdtPciPcdProducerLib.inf b/ArmVirtPkg/Library/FdtPciPcdProducerLib/FdtPciPcdProducerLib.inf index bb055a5beb..1dfe779f6c 100644 --- a/ArmVirtPkg/Library/FdtPciPcdProducerLib/FdtPciPcdProducerLib.inf +++ b/ArmVirtPkg/Library/FdtPciPcdProducerLib/FdtPciPcdProducerLib.inf @@ -36,7 +36,7 @@ gFdtClientProtocolGuid ## CONSUMES [Pcd] - gArmTokenSpaceGuid.PcdPciIoTranslation ## PRODUCES + gEfiMdePkgTokenSpaceGuid.PcdPciIoTranslation ## PRODUCES gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress ## PRODUCES gEfiMdeModulePkgTokenSpaceGuid.PcdPciDisableBusEnumeration ## PRODUCES