From nobody Sat Apr 27 07:22:43 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85090+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85090+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=kernel.org ARC-Seal: i=1; a=rsa-sha256; t=1639776860; cv=none; d=zohomail.com; s=zohoarc; b=mS5r/RZYMxLwIwdnkq7mTaY8bER6YKnFn/0Y3PSIqZE1lSOcD3ocworCV3WVnHhkg92zKe/fZZY9598SiLD4oisQxvOwpOPenlHzhFtAm/memI/l8cYfSywfv4HsFD78WJvyLzxHo13rrT6Ews8W6GGgf1KkztCyLsvqFN72NpU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1639776860; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=kBaNHokouYrPGt2EWx4FEtYHHk0UAEwhmu4qPMVcYTY=; b=S/E8xCU7XZqeSOLHFi9ke3pvsAlt/S2uU4UO8mm5ziXFrcQBfecZiYrgaVrbL5OAZuh+5LSQ3Z0ZFeNOTmrorp23bGprdZjtYHflLaeTpF0yIYM8VcHa7oHNqv/CUeHuA4ya3ZD4rdBSHb6TECeDaJ0BoHmxgsrzqUcmVP+QVjw= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85090+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1639776860564489.21142922759884; Fri, 17 Dec 2021 13:34:20 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id woXFYY1788612xthBHCJ9lMT; Fri, 17 Dec 2021 13:34:20 -0800 X-Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by mx.groups.io with SMTP id smtpd.web10.2531.1639776859028316603 for ; Fri, 17 Dec 2021 13:34:19 -0800 X-Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id D7AB3B82AE0; Fri, 17 Dec 2021 21:34:15 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6D41EC36AE5; Fri, 17 Dec 2021 21:34:13 +0000 (UTC) From: "Ard Biesheuvel" To: devel@edk2.groups.io Cc: Ard Biesheuvel , Rebecca Cran , Leif Lindholm , Sami Mujawar Subject: [edk2-devel] [PATCH v2 1/2] ArmPkg/MpInitLib: avoid ARM_PROCESSOR_TABLE Date: Fri, 17 Dec 2021 22:34:02 +0100 Message-Id: <20211217213403.15585-2-ardb@kernel.org> In-Reply-To: <20211217213403.15585-1-ardb@kernel.org> References: <20211217213403.15585-1-ardb@kernel.org> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,ardb@kernel.org X-Gm-Message-State: ri4cCpHipJfMjjB2pAtnRBGGx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1639776860; bh=Nir5xw/KnJCaPH3JqatQBRFd/2I4HZkoOLa4v5dTuCA=; h=Cc:Date:From:Reply-To:Subject:To; b=an9fUzHfOUq9lzxhcF16wPK8ft4ahJUthQuBNpBIAJsFt5Bx6sQichFyPXgUKd2UCsp yLLW3+Ym1CWqikCoWlljIy8cYrX0spJG2vnHlfxdBpaJ35yoUiSYZBA3BAoWVzqumeRn3 M4Wkd3+T82U9MZB9jotx/FGEScYQGYza5O8= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1639776862707100005 Content-Type: text/plain; charset="utf-8" Pass ARM_CORE_INFO[] directly into the MpInitLib init function so we don't need to rely on an obsolete and unrelated data structure. Signed-off-by: Ard Biesheuvel Reviewed-by: Rebecca Cran --- ArmPkg/Include/Library/MpInitLib.h | 2 +- ArmPkg/Drivers/CpuDxe/CpuMpInit.c | 10 ++++------ ArmPkg/Library/MpInitLib/DxeMpLib.c | 6 +++--- 3 files changed, 8 insertions(+), 10 deletions(-) diff --git a/ArmPkg/Include/Library/MpInitLib.h b/ArmPkg/Include/Library/Mp= InitLib.h index 582bb788fd59..7a29fe3e367e 100644 --- a/ArmPkg/Include/Library/MpInitLib.h +++ b/ArmPkg/Include/Library/MpInitLib.h @@ -356,7 +356,7 @@ MpInitLibWhoAmI ( VOID MpInitLibInitialize ( IN UINTN NumberOfProcessors, - IN ARM_PROCESSOR_TABLE *CpuInfo + IN CONST ARM_CORE_INFO *CoreInfo ); =20 #endif /* MP_INITLIB_H_ */ diff --git a/ArmPkg/Drivers/CpuDxe/CpuMpInit.c b/ArmPkg/Drivers/CpuDxe/CpuM= pInit.c index 876a29e09b1b..4f5b4268aee5 100644 --- a/ArmPkg/Drivers/CpuDxe/CpuMpInit.c +++ b/ArmPkg/Drivers/CpuDxe/CpuMpInit.c @@ -570,10 +570,9 @@ InitializeMpSupport ( EFI_HOB_GENERIC_HEADER *Hob; VOID *HobData; UINTN HobDataSize; - ARM_PROCESSOR_TABLE CpuInfo; + CONST ARM_CORE_INFO *CoreInfo; =20 MaxCpus =3D 1; - ZeroMem (&CpuInfo, sizeof (ARM_PROCESSOR_TABLE)); =20 DEBUG ((DEBUG_INFO, "Starting MP services")); =20 @@ -581,9 +580,8 @@ InitializeMpSupport ( if (Hob !=3D NULL) { HobData =3D GET_GUID_HOB_DATA (Hob); HobDataSize =3D GET_GUID_HOB_DATA_SIZE (Hob); - CpuInfo.ArmCpus =3D (ARM_CORE_INFO *)HobData; - CpuInfo.NumberOfEntries =3D HobDataSize / sizeof (ARM_CORE_INFO); - MaxCpus =3D CpuInfo.NumberOfEntries; + CoreInfo =3D (ARM_CORE_INFO *)HobData; + MaxCpus =3D HobDataSize / sizeof (ARM_CORE_INFO); } =20 if (MaxCpus =3D=3D 1) { @@ -592,7 +590,7 @@ InitializeMpSupport ( return; } =20 - MpInitLibInitialize (MaxCpus, &CpuInfo); + MpInitLibInitialize (MaxCpus, CoreInfo); =20 // // Now install the MP services protocol. diff --git a/ArmPkg/Library/MpInitLib/DxeMpLib.c b/ArmPkg/Library/MpInitLib= /DxeMpLib.c index b00893a5ea7a..5ecd5a2b3366 100644 --- a/ArmPkg/Library/MpInitLib/DxeMpLib.c +++ b/ArmPkg/Library/MpInitLib/DxeMpLib.c @@ -1380,7 +1380,7 @@ FillInProcessorInformation ( VOID MpInitLibInitialize ( IN UINTN NumberOfProcessors, - IN ARM_PROCESSOR_TABLE *CpuInfo + IN CONST ARM_CORE_INFO *CoreInfo ) { EFI_STATUS Status; @@ -1407,7 +1407,7 @@ MpInitLibInitialize ( gProcessorIDs =3D AllocatePool ((mCpuMpData.NumberOfProcessors + 1) * si= zeof (UINT64)); ASSERT (gProcessorIDs !=3D NULL); =20 - FillInProcessorInformation (TRUE, CpuInfo->ArmCpus[0].Mpidr, 0); + FillInProcessorInformation (TRUE, CoreInfo[0].Mpidr, 0); gProcessorIDs[0] =3D mCpuMpData.CpuData[0].Info.ProcessorId; =20 Status =3D gBS->CreateEvent ( @@ -1431,7 +1431,7 @@ MpInitLibInitialize ( continue; } =20 - FillInProcessorInformation (FALSE, CpuInfo->ArmCpus[Index].Mpidr, Inde= x); + FillInProcessorInformation (FALSE, CoreInfo[Index].Mpidr, Index); =20 gProcessorIDs[Index] =3D mCpuMpData.CpuData[Index].Info.ProcessorId; =20 --=20 2.30.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85090): https://edk2.groups.io/g/devel/message/85090 Mute This Topic: https://groups.io/mt/87803241/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Sat Apr 27 07:22:43 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85089+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85089+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=kernel.org ARC-Seal: i=1; a=rsa-sha256; t=1639776860; cv=none; d=zohomail.com; s=zohoarc; b=CSNdqz5rjKeBao7OjWOy4UqF1rGHlr/nMpbpWAMh145LP5x1Dbe2nqIAta8+7cqGJwcmXVNgxRdg49ZP8A20PlynvYVf7yo9Nqjd+FpFCsQa2XusBAEXZRhx79cKu6tjB0g4NPN3WkwHA4ILssxEi7qCVbBUhgdSa8+zWD+Vh6E= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1639776860; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=NqZndPFgbn8sEHPMaoDbFrONwERn+B9zbzdm336L2sE=; b=WDOgM4YxutZtEPYAv+nH+mGptGY6wJcMWfFJSicXtHZYGeY8SvQOJOmLTC/YLxunP7iNOX86fycdJLZdLVT+XPUhgTbv06Dt2ZrpsjjfOWXiOa4OTGUSrr2lp4F5ThPlnxYZAdQvBr7zfKLQ9Wykooj8oJtUh5Y4Q95YV2JAP+U= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85089+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1639776860171476.4827056453539; Fri, 17 Dec 2021 13:34:20 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id NaddYY1788612xNqOMRbMkmw; Fri, 17 Dec 2021 13:34:19 -0800 X-Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by mx.groups.io with SMTP id smtpd.web11.2560.1639776858893580343 for ; Fri, 17 Dec 2021 13:34:19 -0800 X-Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 679CEB82AD9; Fri, 17 Dec 2021 21:34:17 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0FB3FC36AE9; Fri, 17 Dec 2021 21:34:14 +0000 (UTC) From: "Ard Biesheuvel" To: devel@edk2.groups.io Cc: Ard Biesheuvel , Rebecca Cran , Leif Lindholm , Sami Mujawar Subject: [edk2-devel] [PATCH v2 2/2] ArmPkg/CpuDxe: drop ARM_PROCESSOR_TABLE pseudo-ACPI table Date: Fri, 17 Dec 2021 22:34:03 +0100 Message-Id: <20211217213403.15585-3-ardb@kernel.org> In-Reply-To: <20211217213403.15585-1-ardb@kernel.org> References: <20211217213403.15585-1-ardb@kernel.org> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,ardb@kernel.org X-Gm-Message-State: etnxGFkhIYfRrrEhlu3QMKKpx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1639776859; bh=vd32SNwnH0+asJGxOZ5HMWADc2zJkAc5Av0Q4vHi/No=; h=Cc:Date:From:Reply-To:Subject:To; b=d7bG1HFtbXWfhQCAL5etAZz2rdAN8rNKpM9K5uQFPz1AnPw+IZJuVDNdIQ7/6cNaGEI LPMv8FtAGoHv3LF8zQ9ZE5jJLPrKttEVdAirJLcmdFX4Pr21xKYLsEzuegr0l3HwrkOno bh7DiuKBTEFeFc8IsgbLOv4YttTHV4KOJgo= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1639776860707100002 Content-Type: text/plain; charset="utf-8" The ARM_PROCESSOR_TABLE pseudo-ACPI table (which carries a ACPI-table like header but is published as a EFI config table) is not described in any relevant spec, and is not known to be relied upon by any OS. Let's just get rid of it. Signed-off-by: Ard Biesheuvel Reviewed-by: Rebecca Cran Reviewed-by: Sami Mujawar Tested-by: Sami Mujawar --- ArmPkg/Drivers/CpuDxe/CpuDxe.inf | 1 - ArmPkg/Drivers/CpuDxe/CpuDxe.h | 15 --- ArmPkg/Include/Guid/ArmMpCoreInfo.h | 27 ------ ArmPkg/Drivers/CpuDxe/CpuDxe.c | 6 -- ArmPkg/Drivers/CpuDxe/CpuMpCore.c | 98 -------------------- 5 files changed, 147 deletions(-) diff --git a/ArmPkg/Drivers/CpuDxe/CpuDxe.inf b/ArmPkg/Drivers/CpuDxe/CpuDx= e.inf index f4cdb8ab5613..4eda960ede36 100644 --- a/ArmPkg/Drivers/CpuDxe/CpuDxe.inf +++ b/ArmPkg/Drivers/CpuDxe/CpuDxe.inf @@ -21,7 +21,6 @@ [Defines] [Sources.Common] CpuDxe.c CpuDxe.h - CpuMpCore.c CpuMmuCommon.c Exception.c =20 diff --git a/ArmPkg/Drivers/CpuDxe/CpuDxe.h b/ArmPkg/Drivers/CpuDxe/CpuDxe.h index 3f04b89d7ad0..7858c12aea55 100644 --- a/ArmPkg/Drivers/CpuDxe/CpuDxe.h +++ b/ArmPkg/Drivers/CpuDxe/CpuDxe.h @@ -104,21 +104,6 @@ SyncCacheConfig ( IN EFI_CPU_ARCH_PROTOCOL *CpuProtocol ); =20 -/** - * Publish ARM Processor Data table in UEFI SYSTEM Table. - * @param HobStart Pointer to the beginning of the HOB List= from PEI. - * - * Description : This function iterates through HOB list and finds ARM pro= cessor Table Entry HOB. - * If the ARM processor Table Entry HOB is found, the HOB d= ata is copied to run-time memory - * and a pointer is assigned to it in ARM processor table. T= hen the ARM processor table is - * installed in EFI configuration table. -**/ -VOID -EFIAPI -PublishArmProcessorTable ( - VOID - ); - // The ARM Attributes might be defined on 64-bit (case of the long format = description table) UINT64 EfiAttributeToArmAttribute ( diff --git a/ArmPkg/Include/Guid/ArmMpCoreInfo.h b/ArmPkg/Include/Guid/ArmM= pCoreInfo.h index 43f0848e78b8..3a10fffb6fe4 100644 --- a/ArmPkg/Include/Guid/ArmMpCoreInfo.h +++ b/ArmPkg/Include/Guid/ArmMpCoreInfo.h @@ -23,36 +23,9 @@ typedef struct { UINT64 MailboxClearValue; } ARM_CORE_INFO; =20 -typedef struct { - UINT64 Signature; - UINT32 Length; - UINT32 Revision; - UINT64 OemId; - UINT64 OemTableId; - UINTN OemRevision; - UINTN CreatorId; - UINTN CreatorRevision; - EFI_GUID Identifier; - UINTN DataLen; -} ARM_PROCESSOR_TABLE_HEADER; - -typedef struct { - ARM_PROCESSOR_TABLE_HEADER Header; - UINTN NumberOfEntries; - ARM_CORE_INFO *ArmCpus; -} ARM_PROCESSOR_TABLE; - #define ARM_MP_CORE_INFO_GUID \ { 0xa4ee0728, 0xe5d7, 0x4ac5, {0xb2, 0x1e, 0x65, 0x8e, 0xd8, 0x57, 0xe8= , 0x34} } =20 -#define EFI_ARM_PROCESSOR_TABLE_SIGNATURE SIGNATURE_64 ('C', 'P', = 'U', 'T', 'A', 'B', 'L', 'E') -#define EFI_ARM_PROCESSOR_TABLE_REVISION 0x00010000// 1.0 -#define EFI_ARM_PROCESSOR_TABLE_OEM_ID SIGNATURE_64('A','R','M'= ,' ', 'L', 't', 'd', ' ') -#define EFI_ARM_PROCESSOR_TABLE_OEM_TABLE_ID SIGNATURE_64('V', 'E', '= R', 'S', 'A', 'T', 'I', 'L') -#define EFI_ARM_PROCESSOR_TABLE_OEM_REVISION 0x00000001 -#define EFI_ARM_PROCESSOR_TABLE_CREATOR_ID 0xA5A5A5A5 -#define EFI_ARM_PROCESSOR_TABLE_CREATOR_REVISION 0x01000001 - extern EFI_GUID gArmMpCoreInfoGuid; =20 #endif /* ARM_MP_CORE_INFO_GUID_H_ */ diff --git a/ArmPkg/Drivers/CpuDxe/CpuDxe.c b/ArmPkg/Drivers/CpuDxe/CpuDxe.c index 6c076982a1bd..1ee7c9237a3a 100644 --- a/ArmPkg/Drivers/CpuDxe/CpuDxe.c +++ b/ArmPkg/Drivers/CpuDxe/CpuDxe.c @@ -256,12 +256,6 @@ CpuDxeInitialize ( SyncCacheConfig (&mCpu); mIsFlushingGCD =3D FALSE; =20 - // If the platform is a MPCore system then install the Configuration Tab= le describing the - // secondary core states - if (ArmIsMpCore ()) { - PublishArmProcessorTable (); - } - // // Setup a callback for idle events // diff --git a/ArmPkg/Drivers/CpuDxe/CpuMpCore.c b/ArmPkg/Drivers/CpuDxe/CpuM= pCore.c deleted file mode 100644 index 08de46464515..000000000000 --- a/ArmPkg/Drivers/CpuDxe/CpuMpCore.c +++ /dev/null @@ -1,98 +0,0 @@ -/** @file -* -* Copyright (c) 2011-2021, Arm Limited. All rights reserved.
-* -* SPDX-License-Identifier: BSD-2-Clause-Patent -* -**/ - -#include -#include -#include -#include -#include - -#include - -ARM_PROCESSOR_TABLE mArmProcessorTableTemplate =3D { - { - EFI_ARM_PROCESSOR_TABLE_SIGNATURE, - 0, - EFI_ARM_PROCESSOR_TABLE_REVISION, - EFI_ARM_PROCESSOR_TABLE_OEM_ID, - EFI_ARM_PROCESSOR_TABLE_OEM_TABLE_ID, - EFI_ARM_PROCESSOR_TABLE_OEM_REVISION, - EFI_ARM_PROCESSOR_TABLE_CREATOR_ID, - EFI_ARM_PROCESSOR_TABLE_CREATOR_REVISION, - { 0 }, - 0 - }, // ARM Processor table header - 0, // Number of entries in ARM processor Table - NULL // ARM Processor Table -}; - -/** Publish ARM Processor Data table in UEFI SYSTEM Table. - * @param HobStart Pointer to the beginning of the HOB List= from PEI. - * - * Description : This function iterates through HOB list and finds ARM pro= cessor Table Entry HOB. - * If the ARM processor Table Entry HOB is found, the HOB d= ata is copied to run-time memory - * and a pointer is assigned to it in ARM processor table. T= hen the ARM processor table is - * installed in EFI configuration table. -**/ -VOID -EFIAPI -PublishArmProcessorTable ( - VOID - ) -{ - EFI_PEI_HOB_POINTERS Hob; - - Hob.Raw =3D GetHobList (); - - // Iterate through the HOBs and find if there is ARM PROCESSOR ENTRY HOB - for ( ; !END_OF_HOB_LIST (Hob); Hob.Raw =3D GET_NEXT_HOB (Hob)) { - // Check for Correct HOB type - if ((GET_HOB_TYPE (Hob)) =3D=3D EFI_HOB_TYPE_GUID_EXTENSION) { - // Check for correct GUID type - if (CompareGuid (&(Hob.Guid->Name), &gArmMpCoreInfoGuid)) { - ARM_PROCESSOR_TABLE *ArmProcessorTable; - EFI_STATUS Status; - - // Allocate Runtime memory for ARM processor table - ArmProcessorTable =3D (ARM_PROCESSOR_TABLE *)AllocateRuntimePool (= sizeof (ARM_PROCESSOR_TABLE)); - - // Check if the memory allocation is successful or not - ASSERT (NULL !=3D ArmProcessorTable); - - // Set ARM processor table to default values - CopyMem (ArmProcessorTable, &mArmProcessorTableTemplate, sizeof (A= RM_PROCESSOR_TABLE)); - - // Fill in Length fields of ARM processor table - ArmProcessorTable->Header.Length =3D sizeof (ARM_PROCESSOR_TABLE); - ArmProcessorTable->Header.DataLen =3D GET_GUID_HOB_DATA_SIZE (Hob); - - // Fill in Identifier(ARM processor table GUID) - ArmProcessorTable->Header.Identifier =3D gArmMpCoreInfoGuid; - - // Set Number of ARM core entries in the Table - ArmProcessorTable->NumberOfEntries =3D GET_GUID_HOB_DATA_SIZE (Hob= )/sizeof (ARM_CORE_INFO); - - // Allocate runtime memory for ARM processor Table entries - ArmProcessorTable->ArmCpus =3D (ARM_CORE_INFO *)AllocateRuntimePoo= l ( - ArmProcessorTable-= >NumberOfEntries * sizeof (ARM_CORE_INFO) - ); - - // Check if the memory allocation is successful or not - ASSERT (NULL !=3D ArmProcessorTable->ArmCpus); - - // Copy ARM Processor Table data from HOB list to newly allocated = memory - CopyMem (ArmProcessorTable->ArmCpus, GET_GUID_HOB_DATA (Hob), ArmP= rocessorTable->Header.DataLen); - - // Install the ARM Processor table into EFI system configuration t= able - Status =3D gBS->InstallConfigurationTable (&gArmMpCoreInfoGuid, Ar= mProcessorTable); - - ASSERT_EFI_ERROR (Status); - } - } - } -} --=20 2.30.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85089): https://edk2.groups.io/g/devel/message/85089 Mute This Topic: https://groups.io/mt/87803240/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-