mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-25 14:44:28 +02:00
Revert "UefiCpuPkg/PiSmmCpuDxeSmm: Consume PcdCpuSmmApSyncTimeout2"
This reverts commit cb3134612d11102fe066c94c8fa7edb20d62c1a8. Intel server platform sync this commit will hit conflict since our code base is old. We don't want to cherry-pick the dependent patches to avoid potential issue. We need to revert this commit first and then fix the conflict and reapply the change. Sorry for the incovenience. Signed-off-by: Yanbo Huang <yanbo.huang@intel.com>
This commit is contained in:
parent
a3359ffb25
commit
4efcd654ec
@ -1,7 +1,7 @@
|
|||||||
/** @file
|
/** @file
|
||||||
SMM MP service implementation
|
SMM MP service implementation
|
||||||
|
|
||||||
Copyright (c) 2009 - 2024, Intel Corporation. All rights reserved.<BR>
|
Copyright (c) 2009 - 2023, Intel Corporation. All rights reserved.<BR>
|
||||||
Copyright (c) 2017, AMD Incorporated. All rights reserved.<BR>
|
Copyright (c) 2017, AMD Incorporated. All rights reserved.<BR>
|
||||||
|
|
||||||
SPDX-License-Identifier: BSD-2-Clause-Patent
|
SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||||
@ -268,7 +268,7 @@ SmmWaitForApArrival (
|
|||||||
// Sync with APs 1st timeout
|
// Sync with APs 1st timeout
|
||||||
//
|
//
|
||||||
for (Timer = StartSyncTimer ();
|
for (Timer = StartSyncTimer ();
|
||||||
!IsSyncTimerTimeout (Timer, mTimeoutTicker) && !(LmceEn && LmceSignal);
|
!IsSyncTimerTimeout (Timer) && !(LmceEn && LmceSignal);
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
mSmmMpSyncData->AllApArrivedWithException = AllCpusInSmmExceptBlockedDisabled ();
|
mSmmMpSyncData->AllApArrivedWithException = AllCpusInSmmExceptBlockedDisabled ();
|
||||||
@ -309,7 +309,7 @@ SmmWaitForApArrival (
|
|||||||
// Sync with APs 2nd timeout.
|
// Sync with APs 2nd timeout.
|
||||||
//
|
//
|
||||||
for (Timer = StartSyncTimer ();
|
for (Timer = StartSyncTimer ();
|
||||||
!IsSyncTimerTimeout (Timer, mTimeoutTicker2);
|
!IsSyncTimerTimeout (Timer);
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
mSmmMpSyncData->AllApArrivedWithException = AllCpusInSmmExceptBlockedDisabled ();
|
mSmmMpSyncData->AllApArrivedWithException = AllCpusInSmmExceptBlockedDisabled ();
|
||||||
@ -736,7 +736,7 @@ APHandler (
|
|||||||
// Timeout BSP
|
// Timeout BSP
|
||||||
//
|
//
|
||||||
for (Timer = StartSyncTimer ();
|
for (Timer = StartSyncTimer ();
|
||||||
!IsSyncTimerTimeout (Timer, mTimeoutTicker) &&
|
!IsSyncTimerTimeout (Timer) &&
|
||||||
!(*mSmmMpSyncData->InsideSmm);
|
!(*mSmmMpSyncData->InsideSmm);
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
@ -764,7 +764,7 @@ APHandler (
|
|||||||
// Now clock BSP for the 2nd time
|
// Now clock BSP for the 2nd time
|
||||||
//
|
//
|
||||||
for (Timer = StartSyncTimer ();
|
for (Timer = StartSyncTimer ();
|
||||||
!IsSyncTimerTimeout (Timer, mTimeoutTicker2) &&
|
!IsSyncTimerTimeout (Timer) &&
|
||||||
!(*mSmmMpSyncData->InsideSmm);
|
!(*mSmmMpSyncData->InsideSmm);
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
|
@ -471,9 +471,6 @@ extern BOOLEAN mSmmDebugAgentSupport;
|
|||||||
//
|
//
|
||||||
extern UINT64 mAddressEncMask;
|
extern UINT64 mAddressEncMask;
|
||||||
|
|
||||||
extern UINT64 mTimeoutTicker;
|
|
||||||
extern UINT64 mTimeoutTicker2;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Create 4G PageTable in SMRAM.
|
Create 4G PageTable in SMRAM.
|
||||||
|
|
||||||
@ -536,17 +533,15 @@ StartSyncTimer (
|
|||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Check if the SMM AP Sync Timer is timeout specified by Timeout.
|
Check if the SMM AP Sync timer is timeout.
|
||||||
|
|
||||||
@param Timer The start timer from the begin.
|
@param Timer The start timer from the begin.
|
||||||
@param Timeout The timeout ticker to wait.
|
|
||||||
|
|
||||||
**/
|
**/
|
||||||
BOOLEAN
|
BOOLEAN
|
||||||
EFIAPI
|
EFIAPI
|
||||||
IsSyncTimerTimeout (
|
IsSyncTimerTimeout (
|
||||||
IN UINT64 Timer,
|
IN UINT64 Timer
|
||||||
IN UINT64 Timeout
|
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -134,7 +134,6 @@
|
|||||||
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmProfileSize ## SOMETIMES_CONSUMES
|
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmProfileSize ## SOMETIMES_CONSUMES
|
||||||
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmStackSize ## CONSUMES
|
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmStackSize ## CONSUMES
|
||||||
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmApSyncTimeout ## CONSUMES
|
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmApSyncTimeout ## CONSUMES
|
||||||
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmApSyncTimeout2 ## CONSUMES
|
|
||||||
gUefiCpuPkgTokenSpaceGuid.PcdCpuHotPlugDataAddress ## SOMETIMES_PRODUCES
|
gUefiCpuPkgTokenSpaceGuid.PcdCpuHotPlugDataAddress ## SOMETIMES_PRODUCES
|
||||||
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmCodeAccessCheckEnable ## CONSUMES
|
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmCodeAccessCheckEnable ## CONSUMES
|
||||||
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmSyncMode ## CONSUMES
|
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmSyncMode ## CONSUMES
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/** @file
|
/** @file
|
||||||
SMM Timer feature support
|
SMM Timer feature support
|
||||||
|
|
||||||
Copyright (c) 2009 - 2024, Intel Corporation. All rights reserved.<BR>
|
Copyright (c) 2009 - 2015, Intel Corporation. All rights reserved.<BR>
|
||||||
SPDX-License-Identifier: BSD-2-Clause-Patent
|
SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||||
|
|
||||||
**/
|
**/
|
||||||
@ -9,9 +9,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
|
|||||||
#include "PiSmmCpuDxeSmm.h"
|
#include "PiSmmCpuDxeSmm.h"
|
||||||
|
|
||||||
UINT64 mTimeoutTicker = 0;
|
UINT64 mTimeoutTicker = 0;
|
||||||
|
|
||||||
UINT64 mTimeoutTicker2 = 0;
|
|
||||||
|
|
||||||
//
|
//
|
||||||
// Number of counts in a roll-over cycle of the performance counter.
|
// Number of counts in a roll-over cycle of the performance counter.
|
||||||
//
|
//
|
||||||
@ -39,10 +36,6 @@ InitializeSmmTimer (
|
|||||||
MultU64x64 (TimerFrequency, PcdGet64 (PcdCpuSmmApSyncTimeout)),
|
MultU64x64 (TimerFrequency, PcdGet64 (PcdCpuSmmApSyncTimeout)),
|
||||||
1000 * 1000
|
1000 * 1000
|
||||||
);
|
);
|
||||||
mTimeoutTicker2 = DivU64x32 (
|
|
||||||
MultU64x64 (TimerFrequency, PcdGet64 (PcdCpuSmmApSyncTimeout2)),
|
|
||||||
1000 * 1000
|
|
||||||
);
|
|
||||||
if (End < Start) {
|
if (End < Start) {
|
||||||
mCountDown = TRUE;
|
mCountDown = TRUE;
|
||||||
mCycle = Start - End;
|
mCycle = Start - End;
|
||||||
@ -66,17 +59,15 @@ StartSyncTimer (
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Check if the SMM AP Sync Timer is timeout specified by Timeout.
|
Check if the SMM AP Sync timer is timeout.
|
||||||
|
|
||||||
@param Timer The start timer from the begin.
|
@param Timer The start timer from the begin.
|
||||||
@param Timeout The timeout ticker to wait.
|
|
||||||
|
|
||||||
**/
|
**/
|
||||||
BOOLEAN
|
BOOLEAN
|
||||||
EFIAPI
|
EFIAPI
|
||||||
IsSyncTimerTimeout (
|
IsSyncTimerTimeout (
|
||||||
IN UINT64 Timer,
|
IN UINT64 Timer
|
||||||
IN UINT64 Timeout
|
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
UINT64 CurrentTimer;
|
UINT64 CurrentTimer;
|
||||||
@ -114,5 +105,5 @@ IsSyncTimerTimeout (
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return (BOOLEAN)(Delta >= Timeout);
|
return (BOOLEAN)(Delta >= mTimeoutTicker);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user