UefiCpuPkg/PiSmmCpuDxeSmm: Clean up CheckFeatureSupported()

Removed EFIAPI and parameter from CheckFeatureSupported() and removed
CheckProcessorFeature() totally.

Cc: Michael Kinney <michael.d.kinney@intel.com>
Cc: Feng Tian <feng.tian@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
Reviewed-by: Michael Kinney <michael.d.kinney@intel.com>
Regression-tested-by: Laszlo Ersek <lersek@redhat.com>
This commit is contained in:
Jeff Fan 2016-07-02 12:01:02 +08:00 committed by Michael Kinney
parent a46a4c90d3
commit 51773d49de
3 changed files with 3 additions and 60 deletions

View File

@ -359,7 +359,7 @@ SmmInitHandler (
// //
// Check XD and BTS features on each processor on normal boot // Check XD and BTS features on each processor on normal boot
// //
CheckFeatureSupported (NULL); CheckFeatureSupported ();
} }
if (mIsBsp) { if (mIsBsp) {

View File

@ -925,13 +925,10 @@ InitSmmProfileInternal (
/** /**
Check if XD feature is supported by a processor. Check if XD feature is supported by a processor.
@param[in,out] Buffer The pointer to private data buffer.
**/ **/
VOID VOID
EFIAPI
CheckFeatureSupported ( CheckFeatureSupported (
IN OUT VOID *Buffer VOID
) )
{ {
UINT32 RegEax; UINT32 RegEax;
@ -978,48 +975,6 @@ CheckFeatureSupported (
} }
} }
/**
Check if XD and BTS features are supported by all processors.
**/
VOID
CheckProcessorFeature (
VOID
)
{
EFI_STATUS Status;
EFI_MP_SERVICES_PROTOCOL *MpServices;
Status = gBS->LocateProtocol (&gEfiMpServiceProtocolGuid, NULL, (VOID **)&MpServices);
ASSERT_EFI_ERROR (Status);
//
// First detect if XD and BTS are supported
//
mXdSupported = TRUE;
mBtsSupported = TRUE;
//
// Check if XD and BTS are supported on all processors.
//
CheckFeatureSupported (NULL);
//
//Check on other processors if BSP supports this
//
if (mXdSupported || mBtsSupported) {
MpServices->StartupAllAPs (
MpServices,
CheckFeatureSupported,
TRUE,
NULL,
0,
NULL,
NULL
);
}
}
/** /**
Enable XD feature. Enable XD feature.

View File

@ -90,13 +90,10 @@ PageFaultIdtHandlerSmmProfile (
/** /**
Check if XD feature is supported by a processor. Check if XD feature is supported by a processor.
@param[in,out] Buffer The pointer to private data buffer.
**/ **/
VOID VOID
EFIAPI
CheckFeatureSupported ( CheckFeatureSupported (
IN OUT VOID *Buffer VOID
); );
/** /**
@ -117,15 +114,6 @@ InitPaging (
VOID VOID
); );
/**
Check if XD and BTS features are supported by all processors.
**/
VOID
CheckProcessorFeature (
VOID
);
extern BOOLEAN mXdSupported; extern BOOLEAN mXdSupported;
extern BOOLEAN mXdEnabled; extern BOOLEAN mXdEnabled;