[edk2-devel] [PATCH v1 1/1] UefiCpuPkg/CpuCacheInfoLib: Support no enabled AP case in DxeLib

Ni, Ray ray.ni at intel.com
Mon Feb 1 08:44:33 UTC 2021


Reviewed-by: Ray Ni <ray.ni at intel.com>

> -----Original Message-----
> From: Lou, Yun <yun.lou at intel.com>
> Sent: Monday, February 1, 2021 4:29 PM
> To: devel at edk2.groups.io
> Cc: Lou, Yun <yun.lou at intel.com>; Ni, Ray <ray.ni at intel.com>; Dong, Eric
> <eric.dong at intel.com>; Laszlo Ersek <lersek at redhat.com>; Kumar, Rahul1
> <rahul1.kumar at intel.com>
> Subject: [PATCH v1 1/1] UefiCpuPkg/CpuCacheInfoLib: Support no enabled
> AP case in DxeLib
> 
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3195
> 
> Support system has no enabled AP case in DxeCpuCacheInfoLib.
> Otherwise, if the system only has 1 BSP without any enabled AP,
> UEFI POST hangs when invoking StartupAllAPs protocol because
> EFI_NOT_STARTED is returned.
> 
> Signed-off-by: Jason Lou <yun.lou at intel.com>
> Cc: Ray Ni <ray.ni at intel.com>
> Cc: Eric Dong <eric.dong at intel.com>
> Cc: Laszlo Ersek <lersek at redhat.com>
> Cc: Rahul Kumar <rahul1.kumar at intel.com>
> ---
>  UefiCpuPkg/Library/CpuCacheInfoLib/DxeCpuCacheInfoLib.c | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/UefiCpuPkg/Library/CpuCacheInfoLib/DxeCpuCacheInfoLib.c
> b/UefiCpuPkg/Library/CpuCacheInfoLib/DxeCpuCacheInfoLib.c
> index bb788e36146b..d810294e2120 100644
> --- a/UefiCpuPkg/Library/CpuCacheInfoLib/DxeCpuCacheInfoLib.c
> +++ b/UefiCpuPkg/Library/CpuCacheInfoLib/DxeCpuCacheInfoLib.c
> @@ -51,6 +51,13 @@ CpuCacheInfoStartupAllCPUs (
>    EFI_STATUS                Status;
> 
> 
> 
>    Status = MpServices.Protocol->StartupAllAPs (MpServices.Protocol,
> Procedure, FALSE, NULL, 0, ProcedureArgument, NULL);
> 
> +  if (Status == EFI_NOT_STARTED) {
> 
> +    //
> 
> +    // EFI_NOT_STARTED is returned when there is no enabled AP.
> 
> +    // Treat this case as EFI_SUCCESS.
> 
> +    //
> 
> +    Status = EFI_SUCCESS;
> 
> +  }
> 
>    ASSERT_EFI_ERROR (Status);
> 
> 
> 
>    Procedure (ProcedureArgument);
> 
> --
> 2.28.0.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#71009): https://edk2.groups.io/g/devel/message/71009
Mute This Topic: https://groups.io/mt/80280078/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-






More information about the edk2-devel-archive mailing list