From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2a00:1450:400c:c0c::243; helo=mail-wr0-x243.google.com; envelope-from=leif.lindholm@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-wr0-x243.google.com (mail-wr0-x243.google.com [IPv6:2a00:1450:400c:c0c::243]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 56228220F3C3E for ; Fri, 24 Nov 2017 09:00:30 -0800 (PST) Received: by mail-wr0-x243.google.com with SMTP id k61so20918938wrc.4 for ; Fri, 24 Nov 2017 09:04:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=ns0kb+iSf+EcePqVCy8ig+6nAzayZT42tqHhEdVoUro=; b=TuBCaJJZbf25TDNKutB7HRkIZ+ob0Mf1xDuF4abunsD9fDVLv6f2L2UAB++pGk/R3z u07WBncZns76uFWKlVZCh95bzwoeqS/BJxyigPaEd6eHS9enQ6xUvvsWZhUh3W0OTCHB 6oBwl/DklswdXKDApU8fF571t27FRx0c0b/OQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=ns0kb+iSf+EcePqVCy8ig+6nAzayZT42tqHhEdVoUro=; b=E3XLN9BvBGXEtpLAnvVa/LFir1Ne1sGRBsD8GbaUxsXSl2bqhaskt6gCciWXz7cwyf hy6W4cYF20yvlcYhM8hwUtWsJOTuiG/u/JXDr5735H4btqMsVPPnMrHEsc5O87jYXTuS s0r+RXVTgoSCgpOF5GjaaTHiblnq7XGN87rbuKtvWD/NzGIj96uxycoQq+weZhiQUwy4 /SLOCBp+ekIWGdfhQgPmuEjk/raC2lB+3jDdd2awJPKLybDaoi+7HyhcgyMOwh9wlI8I VpgOxu8f+t0HROw4HPFZJrM+gWbNcn2Mb5YxciqDuvrfOxz8oQorl938TBqcjDctYb3k 3C+g== X-Gm-Message-State: AJaThX7Pn/+BJnuX98oaAM6f2N/oKoZFXSCPpSOgzzilPvsYAd9+/o1A txpNXvQ3ZQ81lyAgRSquzP5vvg== X-Google-Smtp-Source: AGs4zMaVmTKaFuovicjjFKLPKXeqsE4g/Cb7/IjUHlz9+DTgXKJT44k4AjwODri5GzScs+P/oIu8eg== X-Received: by 10.223.157.206 with SMTP id q14mr16524345wre.223.1511543088101; Fri, 24 Nov 2017 09:04:48 -0800 (PST) Received: from bivouac.eciton.net (bivouac.eciton.net. [2a00:1098:0:86:1000:23:0:2]) by smtp.gmail.com with ESMTPSA id e71sm11018806wma.13.2017.11.24.09.04.46 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 24 Nov 2017 09:04:46 -0800 (PST) Date: Fri, 24 Nov 2017 17:04:45 +0000 From: Leif Lindholm To: Ard Biesheuvel Cc: edk2-devel@lists.01.org Message-ID: <20171124170445.gd2kzjhazdwwwmjw@bivouac.eciton.net> References: <20171115142048.9928-1-ard.biesheuvel@linaro.org> MIME-Version: 1.0 In-Reply-To: <20171115142048.9928-1-ard.biesheuvel@linaro.org> User-Agent: NeoMutt/20170113 (1.7.2) Subject: Re: [PATCH] ArmPlatformPkg: remove ArmGetCpuCountPerCluster () from ArmPlatformLib X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Nov 2017 17:00:31 -0000 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Nov 15, 2017 at 02:20:48PM +0000, Ard Biesheuvel wrote: > The only user of ArmPlatformLib's ArmGetCpuCountPerCluster () is itself > an ArmPlatformLib implementation, i.e., ArmVExpressLibRTSM. > > Given that we'd prefer to get rid of ArmPlatformLib entirely, let's > remove ArmGetCpuCountPerCluster () from the API as a first step. > > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Ard Biesheuvel I'm thinking this is technically a bit iffy. But the less iffy way would be to add a local .h file to hold the prototype, which feels a bit crazy for a transitional thing. So: Reviewed-by: Leif Lindholm > --- > > This is another prerequisite of the edk2-platforms series I am about to > post. After that, I will follow up with a couple of cleanup patches that > get rid of a lot of ArmPlatformPkg cruft. > > ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/RTSM.c | 13 +++++++++++++ > ArmPlatformPkg/Include/Library/ArmPlatformLib.h | 13 ------------- > 2 files changed, 13 insertions(+), 13 deletions(-) > > diff --git a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/RTSM.c b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/RTSM.c > index d8d1c9ac26dd..11dd7ff1bfb0 100644 > --- a/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/RTSM.c > +++ b/ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/RTSM.c > @@ -21,6 +21,19 @@ > > #include > > +/** > + 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 > diff --git a/ArmPlatformPkg/Include/Library/ArmPlatformLib.h b/ArmPlatformPkg/Include/Library/ArmPlatformLib.h > index fe3bc4bb8e6c..77561a3d05b3 100644 > --- a/ArmPlatformPkg/Include/Library/ArmPlatformLib.h > +++ b/ArmPlatformPkg/Include/Library/ArmPlatformLib.h > @@ -41,19 +41,6 @@ typedef struct { > } ARM_SYSTEM_MEMORY_REGION_DESCRIPTOR; > > /** > - 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 > - ); > - > -/** > Return the core position from the value of its MpId register > > This function returns the core position from the position 0 in the processor. > -- > 2.11.0 >