summaryrefslogtreecommitdiff
path: root/MdeModulePkg/Universal/Console/TerminalDxe/Terminal.h
diff options
context:
space:
mode:
authorRuiyu Ni <ruiyu.ni@intel.com>2017-01-10 11:23:17 +0800
committerRuiyu Ni <ruiyu.ni@intel.com>2017-01-11 17:25:24 +0800
commit8ce87fffbf822ac85e05aa4f097c53a10ccc61d4 (patch)
treef7f1bd1dadbf65064b396bc1695229c50d9af1c7 /MdeModulePkg/Universal/Console/TerminalDxe/Terminal.h
parent0772737347816ced8df6299b1c88cccb9de9164c (diff)
downloadedk2-8ce87fffbf822ac85e05aa4f097c53a10ccc61d4.zip
edk2-8ce87fffbf822ac85e05aa4f097c53a10ccc61d4.tar.gz
edk2-8ce87fffbf822ac85e05aa4f097c53a10ccc61d4.tar.bz2
MdeModulePkg/TerminalDxe: Replace macro with enum for terminal types
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Cc: Star Zeng <star.zeng@intel.com> Reviewed-by: Feng Tian <feng.tian@intel.com>
Diffstat (limited to 'MdeModulePkg/Universal/Console/TerminalDxe/Terminal.h')
-rw-r--r--MdeModulePkg/Universal/Console/TerminalDxe/Terminal.h21
1 files changed, 12 insertions, 9 deletions
diff --git a/MdeModulePkg/Universal/Console/TerminalDxe/Terminal.h b/MdeModulePkg/Universal/Console/TerminalDxe/Terminal.h
index e16b89c..c15d17c 100644
--- a/MdeModulePkg/Universal/Console/TerminalDxe/Terminal.h
+++ b/MdeModulePkg/Universal/Console/TerminalDxe/Terminal.h
@@ -1,7 +1,7 @@
/** @file
Header file for Terminal driver.
-Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2006 - 2017, Intel Corporation. All rights reserved.<BR>
Copyright (C) 2016 Silicon Graphics, Inc. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
@@ -81,10 +81,19 @@ typedef struct _TERMINAL_CONSOLE_IN_EX_NOTIFY {
EFI_KEY_NOTIFY_FUNCTION KeyNotificationFn;
LIST_ENTRY NotifyEntry;
} TERMINAL_CONSOLE_IN_EX_NOTIFY;
+
+typedef enum {
+ TerminalTypePcAnsi,
+ TerminalTypeVt100,
+ TerminalTypeVt100Plus,
+ TerminalTypeVtUtf8,
+ TerminalTypeTtyTerm
+} TERMINAL_TYPE;
+
typedef struct {
UINTN Signature;
EFI_HANDLE Handle;
- UINT8 TerminalType;
+ TERMINAL_TYPE TerminalType;
EFI_SERIAL_IO_PROTOCOL *SerialIo;
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
EFI_SIMPLE_TEXT_INPUT_PROTOCOL SimpleInput;
@@ -139,12 +148,6 @@ typedef union {
UINT8 Utf8_3[3];
} UTF8_CHAR;
-#define PCANSITYPE 0
-#define VT100TYPE 1
-#define VT100PLUSTYPE 2
-#define VTUTF8TYPE 3
-#define TTYTERMTYPE 4
-
#define LEFTOPENBRACKET 0x5b // '['
#define ACAP 0x41
#define BCAP 0x42
@@ -859,7 +862,7 @@ TerminalRemoveConsoleDevVariable (
**/
EFI_STATUS
SetTerminalDevicePath (
- IN UINT8 TerminalType,
+ IN TERMINAL_TYPE TerminalType,
IN EFI_DEVICE_PATH_PROTOCOL *ParentDevicePath,
OUT EFI_DEVICE_PATH_PROTOCOL **TerminalDevicePath
);