From: "Laszlo Ersek" <lersek@redhat.com>
To: devel@edk2.groups.io, eric.dong@intel.com
Cc: Ray Ni <ray.ni@intel.com>
Subject: Re: [edk2-devel] [Patch v5 2/2] UefiCpuPkg/PiSmmCpuDxeSmm: Enable MM MP Protocol
Date: Thu, 11 Jul 2019 19:53:54 +0200 [thread overview]
Message-ID: <bddebd39-0ce1-30eb-1168-ba8cba92a3a2@redhat.com> (raw)
In-Reply-To: <20190710075624.16420-3-eric.dong@intel.com>
Hello Eric,
On 07/10/19 09:56, Dong, Eric wrote:
> V5 changes:
> 1. some small enhancement.
>
> v4 changes:
> 1. Use link list to save the token info.
>
> v3 changes:
> 1. Fix Token clean up too early caused CheckProcedure return error.
>
> v2 changes:
> 1. Remove some duplicated global variables.
> 2. Enhance token design to support multiple task trig for different APs at the same time.
>
> V1 changes:
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1937
>
> Add MM Mp Protocol in PiSmmCpuDxeSmm driver.
>
> Cc: Ray Ni <ray.ni@intel.com>
> Cc: Laszlo Ersek <lersek@redhat.com>
> Signed-off-by: Eric Dong <eric.dong@intel.com>
> ---
> UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c | 570 ++++++++++++++++++-
> UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c | 18 +
> UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.h | 193 ++++++-
> UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.inf | 3 +
> UefiCpuPkg/PiSmmCpuDxeSmm/SmmMp.c | 344 +++++++++++
> UefiCpuPkg/PiSmmCpuDxeSmm/SmmMp.h | 286 ++++++++++
> 6 files changed, 1391 insertions(+), 23 deletions(-)
> create mode 100644 UefiCpuPkg/PiSmmCpuDxeSmm/SmmMp.c
> create mode 100644 UefiCpuPkg/PiSmmCpuDxeSmm/SmmMp.h
>
> diff --git a/UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c b/UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c
> index 64fb4d6344..f09e2738c3 100644
> --- a/UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c
> +++ b/UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c
> @@ -140,7 +140,7 @@ ReleaseAllAPs (
>
> BspIndex = mSmmMpSyncData->BspIndex;
> for (Index = mMaxNumberOfCpus; Index-- > 0;) {
> - if (Index != BspIndex && *(mSmmMpSyncData->CpuData[Index].Present)) {
> + if (IsPresentAp (Index)) {
> ReleaseSemaphore (mSmmMpSyncData->CpuData[Index].Run);
> }
> }
version 5 again fails to build for me, with the following error message:
> UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c: In function 'ReleaseAllAPs':
> UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c:139:37: error: variable 'BspIndex' set but not used [-Werror=unused-but-set-variable]
With the following incremental patch:
> diff --git a/UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c b/UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c
> index f09e2738c30d..ef16997547b8 100644
> --- a/UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c
> +++ b/UefiCpuPkg/PiSmmCpuDxeSmm/MpService.c
> @@ -136,9 +136,7 @@ ReleaseAllAPs (
> )
> {
> UINTN Index;
> - UINTN BspIndex;
>
> - BspIndex = mSmmMpSyncData->BspIndex;
> for (Index = mMaxNumberOfCpus; Index-- > 0;) {
> if (IsPresentAp (Index)) {
> ReleaseSemaphore (mSmmMpSyncData->CpuData[Index].Run);
the build completes fine (using GCC48).
If you change nothing on the series other than squashing the above fix,
you can add my:
Regression-tested-by: Laszlo Ersek <lersek@redhat.com>
to both patches in the series.
-*-
Important: please do not push the series until the 5-level paging
commits are reverted, and reapplied (with Mike's R-b on the MdePkg
patch).
Thanks!
Laszlo
next prev parent reply other threads:[~2019-07-11 17:53 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-10 7:56 [Patch v5 0/2] Enable new MM MP protocol Dong, Eric
2019-07-10 7:56 ` [Patch v5 1/2] MdePkg: Add new MM MP Protocol definition Dong, Eric
2019-07-11 6:42 ` Ni, Ray
2019-07-11 16:13 ` [edk2-devel] " Laszlo Ersek
2019-07-10 7:56 ` [Patch v5 2/2] UefiCpuPkg/PiSmmCpuDxeSmm: Enable MM MP Protocol Dong, Eric
2019-07-10 8:56 ` Ni, Ray
2019-07-11 17:53 ` Laszlo Ersek [this message]
2019-07-12 0:56 ` [edk2-devel] " Dong, Eric
2019-07-10 16:10 ` [edk2-devel] [Patch v5 0/2] Enable new MM MP protocol Laszlo Ersek
[not found] ` <15AFFCA66AC7A422.21469@groups.io>
2019-07-11 6:39 ` [edk2-devel] [Patch v5 1/2] MdePkg: Add new MM MP Protocol definition Dong, Eric
2019-07-11 6:50 ` Liming Gao
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=bddebd39-0ce1-30eb-1168-ba8cba92a3a2@redhat.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