UefiCpuPkg/MpInitLib: Initialize CPU_AP_DATA for CPU APs
Initialize CPU_AP_DATA for CPU APs and add GetApState()/SetApState() helper functions to get/set AP state. Cc: Michael Kinney <michael.d.kinney@intel.com> Cc: Feng Tian <feng.tian@intel.com> Cc: Giri P Mudusuru <giri.p.mudusuru@intel.com> Cc: Laszlo Ersek <lersek@redhat.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jeff Fan <jeff.fan@intel.com> Reviewed-by: Michael Kinney <michael.d.kinney@intel.com> Tested-by: Laszlo Ersek <lersek@redhat.com> Tested-by: Michael Kinney <michael.d.kinney@intel.com>
This commit is contained in:
@@ -54,6 +54,17 @@ typedef enum {
|
||||
ApInitDone = 3
|
||||
} AP_INIT_STATE;
|
||||
|
||||
//
|
||||
// AP state
|
||||
//
|
||||
typedef enum {
|
||||
CpuStateIdle,
|
||||
CpuStateReady,
|
||||
CpuStateBusy,
|
||||
CpuStateFinished,
|
||||
CpuStateDisabled
|
||||
} CPU_STATE;
|
||||
|
||||
//
|
||||
// AP related data
|
||||
//
|
||||
@@ -66,6 +77,7 @@ typedef struct {
|
||||
UINT32 ApicId;
|
||||
UINT32 Health;
|
||||
BOOLEAN CpuHealthy;
|
||||
volatile CPU_STATE State;
|
||||
BOOLEAN Waiting;
|
||||
BOOLEAN *Finished;
|
||||
UINT64 ExpectedTime;
|
||||
|
Reference in New Issue
Block a user