Thanks.

Chen

On 03/05/2015 02:53 PM, Fan, Jeff wrote:
> Chen,
>
> I am ok with the new serial of patches.  I will help to check-in the patches 
> at next week.
>
> Reviewed-by: Jeff Fan <[email protected]>
>
> Thanks!
> Jeff
> -----Original Message-----
> From: Chen Fan [mailto:[email protected]]
> Sent: Thursday, March 05, 2015 2:30 PM
> To: [email protected]
> Cc: Fan, Jeff
> Subject: [edk2] [v4 2/4] UefiCpuPkg/MpService: put AP to busy state when 
> execution
>
> CpuState should follow the process:
>
>      Idle -> Ready -> Busy -> Finished
>       ^                         |
>       |                         |
>       + - - - - - - - - - - - - +
>
> Contributed-under: TianoCore Contribution Agreement 1.0
> Signed-off-by: Chen Fan <[email protected]>
> ---
>   UefiCpuPkg/CpuDxe/CpuMp.c | 9 +++++++--
>   1 file changed, 7 insertions(+), 2 deletions(-)
>
> diff --git a/UefiCpuPkg/CpuDxe/CpuMp.c b/UefiCpuPkg/CpuDxe/CpuMp.c index 
> 25b6fcb..25c9091 100644
> --- a/UefiCpuPkg/CpuDxe/CpuMp.c
> +++ b/UefiCpuPkg/CpuDxe/CpuMp.c
> @@ -1176,11 +1176,14 @@ ProcessorToIdleState (
>     }
>   
>     //
> -  // Avoid forcibly reset AP caused the AP State is not updated.
> +  // Avoid forcibly reset AP caused the timeout AP State is not  //
> + updated.
>     //
>     GetMpSpinLock (CpuData);
> +  if (CpuData->State == CpuStateBusy) {
> +    CpuData->Procedure = NULL;
> +  }
>     CpuData->State = CpuStateIdle;
> -  CpuData->Procedure = NULL;
>     ReleaseMpSpinLock (CpuData);
>   
>     while (TRUE) {
> @@ -1190,6 +1193,8 @@ ProcessorToIdleState (
>       ReleaseMpSpinLock (CpuData);
>   
>       if (Procedure != NULL) {
> +      SetApState (CpuData, CpuStateBusy);
> +
>         Procedure (ProcedureArgument);
>   
>         GetMpSpinLock (CpuData);
> --
> 1.9.3
>
>
> ------------------------------------------------------------------------------
> Dive into the World of Parallel Programming The Go Parallel Website, sponsored
> by Intel and developed in partnership with Slashdot Media, is your hub for all
> things parallel software development, from weekly thought leadership blogs to
> news, videos, case studies, tutorials and more. Take a look and join the
> conversation now. http://goparallel.sourceforge.net/
> _______________________________________________
> edk2-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/edk2-devel
> ------------------------------------------------------------------------------
> Dive into the World of Parallel Programming The Go Parallel Website, sponsored
> by Intel and developed in partnership with Slashdot Media, is your hub for all
> things parallel software development, from weekly thought leadership blogs to
> news, videos, case studies, tutorials and more. Take a look and join the
> conversation now. http://goparallel.sourceforge.net/
> _______________________________________________
> edk2-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/edk2-devel


------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
edk2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to