summaryrefslogtreecommitdiffstats
path: root/UefiCpuPkg
diff options
context:
space:
mode:
authorLaszlo Ersek <lersek@redhat.com>2016-03-18 20:56:04 +0100
committerLaszlo Ersek <lersek@redhat.com>2016-03-25 10:52:59 +0100
commitdc0a7143148508ef8eac2c8a5fb239d84561af14 (patch)
tree5f8d5189fa5439efbfe7ea2901250643bf9ce484 /UefiCpuPkg
parent16e93125b506e30e53f63be4af0255a3afb0210b (diff)
downloadedk2-dc0a7143148508ef8eac2c8a5fb239d84561af14.tar.gz
edk2-dc0a7143148508ef8eac2c8a5fb239d84561af14.tar.bz2
edk2-dc0a7143148508ef8eac2c8a5fb239d84561af14.zip
UefiCpuPkg: PiSmmCpuDxeSmm: remove set but unused variables
Cc: Jeff Fan <jeff.fan@intel.com> Cc: Michael Kinney <michael.d.kinney@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Jeff Fan <jeff.fan@intel.com>
Diffstat (limited to 'UefiCpuPkg')
-rw-r--r--UefiCpuPkg/PiSmmCpuDxeSmm/SmmProfile.c34
1 files changed, 11 insertions, 23 deletions
diff --git a/UefiCpuPkg/PiSmmCpuDxeSmm/SmmProfile.c b/UefiCpuPkg/PiSmmCpuDxeSmm/SmmProfile.c
index 2078421a12..71fff0e5b0 100644
--- a/UefiCpuPkg/PiSmmCpuDxeSmm/SmmProfile.c
+++ b/UefiCpuPkg/PiSmmCpuDxeSmm/SmmProfile.c
@@ -342,7 +342,6 @@ InitProtectedMemRange (
UINTN NumberOfSpliteRange;
EFI_GCD_MEMORY_SPACE_DESCRIPTOR *MemorySpaceMap;
UINTN TotalSize;
- EFI_STATUS Status;
EFI_PHYSICAL_ADDRESS ProtectBaseAddress;
EFI_PHYSICAL_ADDRESS ProtectEndAddress;
EFI_PHYSICAL_ADDRESS Top2MBAlignedAddress;
@@ -358,10 +357,10 @@ InitProtectedMemRange (
//
// Get MMIO ranges from GCD and add them into protected memory ranges.
//
- Status = gDS->GetMemorySpaceMap (
- &NumberOfDescriptors,
- &MemorySpaceMap
- );
+ gDS->GetMemorySpaceMap (
+ &NumberOfDescriptors,
+ &MemorySpaceMap
+ );
for (Index = 0; Index < NumberOfDescriptors; Index++) {
if (MemorySpaceMap[Index].GcdMemoryType == EfiGcdMemoryTypeMemoryMappedIo) {
NumberOfMmioDescriptors++;
@@ -776,18 +775,16 @@ InitSmmProfileCallBack (
IN EFI_HANDLE Handle
)
{
- EFI_STATUS Status;
-
//
// Save to variable so that SMM profile data can be found.
//
- Status = gRT->SetVariable (
- SMM_PROFILE_NAME,
- &gEfiCallerIdGuid,
- EFI_VARIABLE_BOOTSERVICE_ACCESS | EFI_VARIABLE_RUNTIME_ACCESS,
- sizeof(mSmmProfileBase),
- &mSmmProfileBase
- );
+ gRT->SetVariable (
+ SMM_PROFILE_NAME,
+ &gEfiCallerIdGuid,
+ EFI_VARIABLE_BOOTSERVICE_ACCESS | EFI_VARIABLE_RUNTIME_ACCESS,
+ sizeof(mSmmProfileBase),
+ &mSmmProfileBase
+ );
//
// Get Software SMI from FADT
@@ -1311,7 +1308,6 @@ SmmProfilePFHandler (
SMM_PROFILE_ENTRY *SmmProfileEntry;
UINT64 SmiCommand;
EFI_STATUS Status;
- UINTN SwSmiCpuIndex;
UINT8 SoftSmiValue;
EFI_SMM_SAVE_STATE_IO_INFO IoInfo;
@@ -1355,10 +1351,6 @@ SmmProfilePFHandler (
}
//
- // Try to find which CPU trigger SWSMI
- //
- SwSmiCpuIndex = 0;
- //
// Indicate it is not software SMI
//
SmiCommand = 0xFFFFFFFFFFFFFFFFULL;
@@ -1369,10 +1361,6 @@ SmmProfilePFHandler (
}
if (IoInfo.IoPort == mSmiCommandPort) {
//
- // Great! Find it.
- //
- SwSmiCpuIndex = Index;
- //
// A software SMI triggered by SMI command port has been found, get SmiCommand from SMI command port.
//
SoftSmiValue = IoRead8 (mSmiCommandPort);