UINT64 FwCfgSelectorSize;\r
UINT64 FwCfgDataAddress;\r
UINT64 FwCfgDataSize;\r
+ UINT64 FwCfgDmaAddress;\r
+ UINT64 FwCfgDmaSize;\r
\r
Hob = GetFirstGuidHob(&gFdtHobGuid);\r
if (Hob == NULL || GET_GUID_HOB_DATA_SIZE (Hob) != sizeof (UINT64)) {\r
\r
DEBUG ((EFI_D_INFO, "Found FwCfg @ 0x%Lx/0x%Lx\n", FwCfgSelectorAddress,\r
FwCfgDataAddress));\r
+\r
+ if (fdt64_to_cpu (((UINT64 *)RegProp)[1]) >= 0x18) {\r
+ FwCfgDmaAddress = FwCfgDataAddress + 0x10;\r
+ FwCfgDmaSize = 0x08;\r
+\r
+ //\r
+ // See explanation above.\r
+ //\r
+ ASSERT (FwCfgDmaAddress <= MAX_UINTN - FwCfgDmaSize + 1);\r
+\r
+ PcdSet64 (PcdFwCfgDmaAddress, FwCfgDmaAddress);\r
+ DEBUG ((EFI_D_INFO, "Found FwCfg DMA @ 0x%Lx\n", FwCfgDmaAddress));\r
+ }\r
break;\r
\r
case PropertyTypeVirtio:\r
\r
PcdSet32 (PcdGicDistributorBase, (UINT32)DistBase);\r
PcdSet32 (PcdGicInterruptInterfaceBase, (UINT32)CpuBase);\r
+ PcdSet32 (PcdArmGicRevision, 2);\r
\r
DEBUG ((EFI_D_INFO, "Found GIC @ 0x%Lx/0x%Lx\n", DistBase, CpuBase));\r
break;\r
\r
PcdSet32 (PcdGicDistributorBase, (UINT32)DistBase);\r
PcdSet32 (PcdGicRedistributorsBase, (UINT32)RedistBase);\r
+ PcdSet32 (PcdArmGicRevision, 3);\r
\r
DEBUG ((EFI_D_INFO, "Found GIC v3 (re)distributor @ 0x%Lx (0x%Lx)\n",\r
DistBase, RedistBase));\r