From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by mx.groups.io with SMTP id smtpd.web12.7218.1588683820917845062 for ; Tue, 05 May 2020 06:03:41 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: arm.com, ip: 217.140.110.172, mailfrom: aditya.angadi@arm.com) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 947B630E; Tue, 5 May 2020 06:03:40 -0700 (PDT) Received: from usa.arm.com (a073440-lin.blr.arm.com [10.162.16.34]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id A65493F68F; Tue, 5 May 2020 06:03:38 -0700 (PDT) From: "Aditya Angadi" To: devel@edk2.groups.io Cc: thomas.abraham@arm.com, ard.biesheuvel@arm.com, vijayenthiran.subramaniam@arm.com, leif@nuviainc.com, Aditya Angadi Subject: [PATCH v5][edk2-platforms 06/17] Platform/ARM/SgiPkg: Obtain rd-e1-edge platform core count from PCD Date: Tue, 5 May 2020 18:32:03 +0530 Message-Id: <20200505130214.25592-7-aditya.angadi@arm.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200505130214.25592-1-aditya.angadi@arm.com> References: <20200505130214.25592-1-aditya.angadi@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable The number of processing elements is hardcoded in the MADT ACPI table of the RD-E1-Edge platform. Remove the hardcoded value and obtain the core count on platform from PCDs instead. Signed-off-by: Aditya Angadi --- Platform/ARM/SgiPkg/AcpiTables/RdE1Edge/Madt.aslc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Platform/ARM/SgiPkg/AcpiTables/RdE1Edge/Madt.aslc b/Platform= /ARM/SgiPkg/AcpiTables/RdE1Edge/Madt.aslc index 48e7a61478e8..58378b570b12 100644 --- a/Platform/ARM/SgiPkg/AcpiTables/RdE1Edge/Madt.aslc +++ b/Platform/ARM/SgiPkg/AcpiTables/RdE1Edge/Madt.aslc @@ -14,6 +14,9 @@ #include #include =20 +#define CORE_CNT (FixedPcdGet32 (PcdClusterCount) * \ + FixedPcdGet32 (PcdCoreCount)) + // EFI_ACPI_6_2_GIC_STRUCTURE #define EFI_ACPI_6_2_GICC_STRUCTURE_INIT(GicId, AcpiCpuUid, Mpidr, Flags= , \ PmuIrq, GicBase, GicVBase, GicHBase, GsivId, GicRBase, Efficiency) = \ @@ -85,7 +88,7 @@ =20 typedef struct { EFI_ACPI_6_2_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER Header; - EFI_ACPI_6_2_GIC_STRUCTURE GicInterfaces[32= ]; + EFI_ACPI_6_2_GIC_STRUCTURE GicInterfaces[CO= RE_CNT]; EFI_ACPI_6_2_GIC_DISTRIBUTOR_STRUCTURE GicDistributor; EFI_ACPI_6_2_GICR_STRUCTURE GicRedistributor= ; EFI_ACPI_6_2_GIC_ITS_STRUCTURE GicIts; --=20 2.17.1