From 4de216c01641fe4362cabfa0687378a973490832 Mon Sep 17 00:00:00 2001 From: Jeff Fan Date: Fri, 18 Dec 2015 03:24:27 +0000 Subject: UefiCpuPkg/CpuMpPei: Add GetApLoopMode() to get AP loop mode Add GetApLoopMode() that will get PCD PcdCpuApLoopMode firstly. If it is ApInMwaitLoop, we will check if MONITOR/MWAIT feature supported by CPUID. If MONITOR/MWAIT feature is not supported, force AP loop mode to ApInHltLoop. GetApLoopMode() also return the largest line size required. Contributed-under: TianoCore Contribution Agreement 1.0 Cc: Feng Tian Cc: Michael Kinney Cc: Jordan Justen Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jeff Fan Signed-off-by: Michael Kinney Tested-by: Michael Kinney Reviewed-by: Michael Kinney git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19343 6f19259b-4bc3-4df7-8a09-765794883524 --- UefiCpuPkg/Include/Register/Cpuid.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'UefiCpuPkg/Include') diff --git a/UefiCpuPkg/Include/Register/Cpuid.h b/UefiCpuPkg/Include/Register/Cpuid.h index 6730551ff8..f8ff247d09 100644 --- a/UefiCpuPkg/Include/Register/Cpuid.h +++ b/UefiCpuPkg/Include/Register/Cpuid.h @@ -31,6 +31,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #define CPUID_CACHE_PARAMS 0x4 +#define CPUID_MONITOR_MWAIT 0x5 + #define CPUID_EXTENDED_TOPOLOGY 0xB #define CPUID_EXTENDED_TOPOLOGY_LEVEL_TYPE_INVALID 0x0 #define CPUID_EXTENDED_TOPOLOGY_LEVEL_TYPE_SMT 0x1 -- cgit v1.2.3