SourceLevelDebugPkg: Use CPU Local APIC timer to handle timeout.

Use CPU Local APIC timer to handle timeout when read data from debug port, instead of the TimerLib in Debug Communication lib instances.
It could remove much duplicated code in Debug Communication Lib instances.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>





git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17089 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
Jeff Fan
2015-04-01 07:51:15 +00:00
committed by vanjeff
parent 206f412113
commit 08021523f8
17 changed files with 283 additions and 667 deletions

View File

@@ -1,7 +1,7 @@
/** @file
Install Serial IO Protocol that layers on top of a Debug Communication Library instance.
Copyright (c) 2012 - 2013, Intel Corporation. All rights reserved.<BR>
Copyright (c) 2012 - 2015, 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
@@ -676,7 +676,7 @@ SerialRead (
if (!DebugPortPollBuffer (Handle)) {
break;
}
DebugPortReadBuffer (Handle, Data8, 1, 0);
DebugAgentReadBuffer (Handle, Data8, 1, 0);
if (*Data8 == DEBUG_STARTING_SYMBOL_ATTACH) {
//
@@ -752,7 +752,7 @@ DebugReadBreakFromDebugPort (
//
// Try to read the start symbol
//
DebugPortReadBuffer (Handle, Data8, 1, 0);
DebugAgentReadBuffer (Handle, Data8, 1, 0);
if (*Data8 == DEBUG_STARTING_SYMBOL_ATTACH) {
DebugAgentMsgPrint (DEBUG_AGENT_INFO, "Debug Timer attach symbol received %x", *Data8);
*BreakSymbol = *Data8;