diff options
author | Ruiyu Ni <ruiyu.ni@intel.com> | 2018-01-05 17:08:13 +0800 |
---|---|---|
committer | Ruiyu Ni <ruiyu.ni@intel.com> | 2018-01-09 13:18:47 +0800 |
commit | a2ea6894e6ca95e8d7a254593661a79e4b988626 (patch) | |
tree | 798ef00f318612a4c3b488b96254574a6574a18d /UefiCpuPkg | |
parent | 5f354f6a4a635e4fb5aa4c0be1c7943475037ad6 (diff) | |
download | edk2-a2ea6894e6ca95e8d7a254593661a79e4b988626.tar.gz edk2-a2ea6894e6ca95e8d7a254593661a79e4b988626.tar.bz2 edk2-a2ea6894e6ca95e8d7a254593661a79e4b988626.zip |
UefiCpuPkg/MpInitLib: Fix a bug that AP enters timer INT handler
When SourceLevelDebug is enabled, AP randomly executes the DXECORE
timer handler logic. The root cause is the interrupts are not
masked in AP wake up procedure.
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Jeff Fan <vanjeff_919@hotmail.com>
Diffstat (limited to 'UefiCpuPkg')
-rw-r--r-- | UefiCpuPkg/Library/MpInitLib/MpLib.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/UefiCpuPkg/Library/MpInitLib/MpLib.c b/UefiCpuPkg/Library/MpInitLib/MpLib.c index 0c2058a7b0..1a6cdb678e 100644 --- a/UefiCpuPkg/Library/MpInitLib/MpLib.c +++ b/UefiCpuPkg/Library/MpInitLib/MpLib.c @@ -1,7 +1,7 @@ /** @file
CPU MP Initialize Library common functions.
- Copyright (c) 2016 - 2017, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2016 - 2018, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -582,6 +582,10 @@ ApWakeupFunction ( // We need to re-initialize them at here
//
ProgramVirtualWireMode ();
+ //
+ // Mask the LINT0 and LINT1 so that AP doesn't enter the system timer interrupt handler.
+ //
+ DisableLvtInterrupts ();
SyncLocalApicTimerSetting (CpuMpData);
CurrentApicMode = GetApicMode ();
|