public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Ard Biesheuvel via groups.io" <ardb+git=google.com@groups.io>
To: devel@edk2.groups.io
Cc: sami.mujawar@arm.com, quic_llindhol@quicinc.com,
	 Ard Biesheuvel <ardb@kernel.org>
Subject: [edk2-devel] [PATCH edk2-platforms 1/1] Platform/VExpress: Replace missing ArmGetCpuCountPerCluster()
Date: Tue, 27 Aug 2024 19:28:20 +0200	[thread overview]
Message-ID: <20240827172820.661646-1-ardb+git@google.com> (raw)

From: Ard Biesheuvel <ardb@kernel.org>

Commit

  8676e88233d4 ("Platform/ ARM AARCH64: Remove ArmPlatformLib MPCore boilerplate")

inadvertently removed the implementation of ArmGetCpuCountPerCluster(),
which was hiding in the RTSM ArmPlatformLib implementation, even though
it was not part of that library class interface.

Given that the implementation just returned PcdCoreCount, fix up the
code that got broken by using that value directly.

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
---
 Platform/ARM/VExpressPkg/Library/ArmVExpressLibRTSM/RTSM.c | 15 +--------------
 1 file changed, 1 insertion(+), 14 deletions(-)

diff --git a/Platform/ARM/VExpressPkg/Library/ArmVExpressLibRTSM/RTSM.c b/Platform/ARM/VExpressPkg/Library/ArmVExpressLibRTSM/RTSM.c
index 24275254815a..b564db2693be 100644
--- a/Platform/ARM/VExpressPkg/Library/ArmVExpressLibRTSM/RTSM.c
+++ b/Platform/ARM/VExpressPkg/Library/ArmVExpressLibRTSM/RTSM.c
@@ -15,19 +15,6 @@
 
 #include <ArmPlatform.h>
 
-/**
-  Return the core per cluster. The method may differ per core type
-
-  This function might be called from assembler before any stack is set.
-
-  @return   Return the core count per cluster
-
-**/
-UINTN
-ArmGetCpuCountPerCluster (
-  VOID
-  );
-
 ARM_CORE_INFO mVersatileExpressMpCoreInfoTable[] = {
   {
     // Cluster 0, Core 0
@@ -156,7 +143,7 @@ PrePeiCoreGetMpCoreInfo (
   ProcType = MmioRead32 (ARM_VE_SYS_PROCID0_REG) & ARM_VE_SYS_PROC_ID_MASK;
   if ((ProcType == ARM_VE_SYS_PROC_ID_CORTEX_A9) || (ProcType == ARM_VE_SYS_PROC_ID_CORTEX_A15)) {
     // Only support one cluster on all but ARMv8 FVP platform. FVP still uses CortexA9 ID.
-    *CoreCount    = ArmGetCpuCountPerCluster ();
+    *CoreCount    = FixedPcdGet32 (PcdCoreCount);
     *ArmCoreTable = mVersatileExpressMpCoreInfoTable;
     return EFI_SUCCESS;
   } else {
-- 
2.46.0.295.g3b9ea8a38a-goog



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#120418): https://edk2.groups.io/g/devel/message/120418
Mute This Topic: https://groups.io/mt/108128468/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-



             reply	other threads:[~2024-08-27 18:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-27 17:28 Ard Biesheuvel via groups.io [this message]
2024-08-30 15:45 ` [edk2-devel] [PATCH edk2-platforms 1/1] Platform/VExpress: Replace missing ArmGetCpuCountPerCluster() Sami Mujawar
2024-08-30 15:57   ` Ard Biesheuvel via groups.io
2024-08-30 16:04     ` Sami Mujawar
2024-08-30 17:25       ` Ard Biesheuvel via groups.io
2024-08-30 16:03   ` Sami Mujawar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240827172820.661646-1-ardb+git@google.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox