Transfer protocol defintions used by debug agent and host. It is only\r
intended to be used by Debug related module implementation.\r
\r
- Copyright (c) 2010 - 2013, Intel Corporation. All rights reserved.<BR>\r
- This program and the accompanying materials\r
- are licensed and made available under the terms and conditions of the BSD License\r
- which accompanies this distribution. The full text of the license may be found at\r
- http://opensource.org/licenses/bsd-license.php.\r
-\r
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+ Copyright (c) 2010 - 2017, Intel Corporation. All rights reserved.<BR>\r
+ SPDX-License-Identifier: BSD-2-Clause-Patent\r
\r
**/\r
\r
\r
//\r
// Current revision of transfer protocol\r
+// 0.4: Packet compression and decompression.\r
//\r
-#define DEBUG_AGENT_REVISION ((0 << 16) | 03)\r
+#define DEBUG_AGENT_REVISION_03 ((0 << 16) | 03)\r
+#define DEBUG_AGENT_REVISION_04 ((0 << 16) | 04)\r
#define DEBUG_AGENT_CAPABILITIES 0\r
\r
//\r
-// Definitions for attach command\r
+// Definitions for the (A)ttach command\r
//\r
#define DEBUG_STARTING_SYMBOL_ATTACH (0xFA)\r
\r
//\r
#define DEBUG_STARTING_SYMBOL_NORMAL (0xFE)\r
\r
+//\r
+// Definition for starting symbol of a (C)ompressed debug packet. Choose a non-ASCII to avoid conflict with other serial output.\r
+//\r
+#define DEBUG_STARTING_SYMBOL_COMPRESS (0xFC)\r
+\r
#pragma pack(1)\r
\r
//\r
-// Definition for debug packet header for normal debug packets (not including break/attach command)\r
+// Definition for debug packet header for debug packets (not including attach command)\r
//\r
typedef struct {\r
UINT8 StartSymbol;\r
#define DEBUG_COMMAND_REQUEST (0 << 7)\r
#define DEBUG_COMMAND_RESPONSE (1 << 7)\r
\r
+#define IS_REQUEST(x) (((x)->Command & DEBUG_COMMAND_RESPONSE) == 0)\r
+\r
//\r
// HOST initiated commands\r
//\r