mirror of
https://github.com/tianocore/edk2
synced 2026-08-27 00:23:19 -04:00
MdeModulePkg/Core/Dxe: Refactor CoreSetInterruptState enable path
Refactor the CoreSetInterruptState(TRUE) flow so EnableInterrupt() is invoked through a single call site. Behavior is unchanged: interrupts remain disabled in SMM and are enabled outside SMM. Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com>
This commit is contained in:
parent
04679c85b4
commit
1d2e73c4af
1 changed files with 6 additions and 7 deletions
|
|
@ -32,15 +32,14 @@ CoreSetInterruptState (
|
|||
return;
|
||||
}
|
||||
|
||||
if (gSmmBase2 == NULL) {
|
||||
gCpu->EnableInterrupt (gCpu);
|
||||
return;
|
||||
if (gSmmBase2 != NULL) {
|
||||
Status = gSmmBase2->InSmm (gSmmBase2, &InSmm);
|
||||
if (EFI_ERROR (Status) || InSmm) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
Status = gSmmBase2->InSmm (gSmmBase2, &InSmm);
|
||||
if (!EFI_ERROR (Status) && !InSmm) {
|
||||
gCpu->EnableInterrupt (gCpu);
|
||||
}
|
||||
gCpu->EnableInterrupt (gCpu);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue