diff options
author | Jeff Fan <jeff.fan@intel.com> | 2016-04-01 12:53:06 +0800 |
---|---|---|
committer | Jeff Fan <jeff.fan@intel.com> | 2016-04-06 09:13:18 +0800 |
commit | f3ee38dd958d0bdbebc05441db15a84e70126552 (patch) | |
tree | 145dfbccfa63282e9c15aca4d03ce9b0b61ea529 /SourceLevelDebugPkg/Library/DebugAgent/SmmDebugAgent | |
parent | de70b8c51b996ebcfd010603729d7c925154d9ab (diff) | |
download | edk2-f3ee38dd958d0bdbebc05441db15a84e70126552.zip edk2-f3ee38dd958d0bdbebc05441db15a84e70126552.tar.gz edk2-f3ee38dd958d0bdbebc05441db15a84e70126552.tar.bz2 |
SourceLevelDebugPkg/SmmDebugAgent: mMailboxPointer is used before set
mMailboxPointer is used before it is initialization. This issue only happens
when SmmDebugAgent is initialized without PeiDebugAgent or DxeDebugAgent
initialization. The fix is to use Mailbox instead.
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Hao Wu <hao.a.wu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
Diffstat (limited to 'SourceLevelDebugPkg/Library/DebugAgent/SmmDebugAgent')
-rw-r--r-- | SourceLevelDebugPkg/Library/DebugAgent/SmmDebugAgent/SmmDebugAgentLib.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/SourceLevelDebugPkg/Library/DebugAgent/SmmDebugAgent/SmmDebugAgentLib.c b/SourceLevelDebugPkg/Library/DebugAgent/SmmDebugAgent/SmmDebugAgentLib.c index 32b1ae6..701c4be 100644 --- a/SourceLevelDebugPkg/Library/DebugAgent/SmmDebugAgent/SmmDebugAgentLib.c +++ b/SourceLevelDebugPkg/Library/DebugAgent/SmmDebugAgent/SmmDebugAgentLib.c @@ -1,7 +1,7 @@ /** @file
Debug Agent library implementition.
- Copyright (c) 2010 - 2015, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2010 - 2016, 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
@@ -243,7 +243,7 @@ InitializeDebugAgent ( // Initialize Debug Timer hardware and save its frequency
//
InitializeDebugTimer (&DebugTimerFrequency, TRUE);
- UpdateMailboxContent (mMailboxPointer, DEBUG_MAILBOX_DEBUG_TIMER_FREQUENCY, DebugTimerFrequency);
+ UpdateMailboxContent (Mailbox, DEBUG_MAILBOX_DEBUG_TIMER_FREQUENCY, DebugTimerFrequency);
DebugPortHandle = (UINT64) (UINTN)DebugPortInitialize ((DEBUG_PORT_HANDLE) (UINTN)Mailbox->DebugPortHandle, NULL);
UpdateMailboxContent (Mailbox, DEBUG_MAILBOX_DEBUG_PORT_HANDLE_INDEX, DebugPortHandle);
|