]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Include/Protocol/SimpleTextOut.h
Change SMM CPU I/O to SMM CPU I/O 2
[mirror_edk2.git] / MdePkg / Include / Protocol / SimpleTextOut.h
index 5e3e1f5f19307f15ba1217a67bedb40e348b7ee7..f3e88ee6853acadc4fd639d61a8302474c57b21d 100644 (file)
@@ -3,10 +3,10 @@
 \r
   Abstraction of a very simple text based output device like VGA text mode or\r
   a serial terminal. The Simple Text Out protocol instance can represent\r
-  a single hardware device or a virtual device that is an agregation\r
+  a single hardware device or a virtual device that is an aggregation\r
   of multiple physical devices.\r
 \r
-  Copyright (c) 2006, Intel Corporation                                                         \r
+  Copyright (c) 2006 - 2008, Intel Corporation                                                         \r
   All rights reserved. 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
 #ifndef __SIMPLE_TEXT_OUT_H__\r
 #define __SIMPLE_TEXT_OUT_H__\r
 \r
-#include <PiDxe.h>\r
-\r
 #define EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL_GUID \\r
   { \\r
     0x387477c2, 0x69c7, 0x11d2, {0x8e, 0x39, 0x0, 0xa0, 0xc9, 0x69, 0x72, 0x3b } \\r
   }\r
 \r
-//\r
-// Protocol GUID defined in EFI1.1.\r
-// \r
+///\r
+/// Protocol GUID defined in EFI1.1.\r
+/// \r
 #define SIMPLE_TEXT_OUTPUT_PROTOCOL   EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL_GUID\r
 \r
 typedef struct _EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL;\r
 \r
-//\r
-// Backward-compatible with EFI1.1.\r
-// \r
+///\r
+/// Backward-compatible with EFI1.1.\r
+/// \r
 typedef EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL   SIMPLE_TEXT_OUTPUT_INTERFACE;\r
 \r
 //\r
@@ -139,11 +137,11 @@ typedef EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL   SIMPLE_TEXT_OUTPUT_INTERFACE;
 \r
 //\r
 // We currently define attributes from 0 - 7F for color manipulations\r
-// To internally handle the local display characteristics for a particular character, we are defining\r
-// Bit 7 to signify the local glyph representation for a character.  If turned on, glyphs will be\r
+// To internally handle the local display characteristics for a particular character, \r
+// Bit 7 signifies the local glyph representation for a character.  If turned on, glyphs will be\r
 // pulled from the wide glyph database and will display locally as a wide character (16 X 19 versus 8 X 19)\r
 // If bit 7 is off, the narrow glyph database will be used.  This does NOT affect information that is sent to\r
-// non-local displays (e.g. serial or LAN consoles).\r
+// non-local displays, such as serial or LAN consoles.\r
 //\r
 #define EFI_WIDE_ATTRIBUTE  0x80\r
 \r
@@ -161,19 +159,18 @@ typedef EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL   SIMPLE_TEXT_OUTPUT_INTERFACE;
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_TEXT_RESET) (\r
-  IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL           *This,\r
+(EFIAPI *EFI_TEXT_RESET)(\r
+  IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL        *This,\r
   IN BOOLEAN                                ExtendedVerification\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
-  Write a Unicode string to the output device.\r
+  Write a string to the output device.\r
 \r
   @param  This   Protocol instance pointer.\r
-  @param  String The NULL-terminated Unicode string to be displayed on the output\r
+  @param  String The NULL-terminated string to be displayed on the output\r
                  device(s). All output devices must also support the Unicode\r
-                 drawing defined in this file.\r
+                 drawing character codes defined in this file.\r
 \r
   @retval EFI_SUCCESS             The string was output to the device.\r
   @retval EFI_DEVICE_ERROR        The device reported an error while attempting to output\r
@@ -181,39 +178,37 @@ EFI_STATUS
   @retval EFI_UNSUPPORTED         The output device's mode is not currently in a\r
                                   defined text mode.\r
   @retval EFI_WARN_UNKNOWN_GLYPH  This warning code indicates that some of the\r
-                                  characters in the Unicode string could not be\r
+                                  characters in the string could not be\r
                                   rendered and were skipped.\r
 \r
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_TEXT_STRING) (\r
+(EFIAPI *EFI_TEXT_STRING)(\r
   IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL        *This,\r
   IN CHAR16                                 *String\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
-  Verifies that all characters in a Unicode string can be output to the \r
+  Verifies that all characters in a string can be output to the \r
   target device.\r
 \r
   @param  This   Protocol instance pointer.\r
-  @param  String The NULL-terminated Unicode string to be examined for the output\r
+  @param  String The NULL-terminated string to be examined for the output\r
                  device(s).\r
 \r
   @retval EFI_SUCCESS      The device(s) are capable of rendering the output string.\r
-  @retval EFI_UNSUPPORTED  Some of the characters in the Unicode string cannot be\r
+  @retval EFI_UNSUPPORTED  Some of the characters in the string cannot be\r
                            rendered by one or more of the output devices mapped\r
                            by the EFI handle.\r
 \r
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_TEXT_TEST_STRING) (\r
+(EFIAPI *EFI_TEXT_TEST_STRING)(\r
   IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL        *This,\r
   IN CHAR16                                 *String\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Returns information for an available text mode that the output device(s)\r
@@ -233,13 +228,12 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_TEXT_QUERY_MODE) (\r
+(EFIAPI *EFI_TEXT_QUERY_MODE)(\r
   IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL        *This,\r
   IN UINTN                                  ModeNumber,\r
   OUT UINTN                                 *Columns,\r
   OUT UINTN                                 *Rows\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Sets the output device(s) to a specified mode.\r
@@ -254,11 +248,10 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_TEXT_SET_MODE) (\r
+(EFIAPI *EFI_TEXT_SET_MODE)(\r
   IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL        *This,\r
   IN UINTN                                  ModeNumber\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Sets the background and foreground colors for the OutputString () and\r
@@ -269,18 +262,17 @@ EFI_STATUS
                     bits 4..6 are the background color. All other bits are undefined\r
                     and must be zero. The valid Attributes are defined in this file.\r
 \r
-  @retval EFI_SUCCESS     The attribute was set.\r
-  @retval EFI_DEVICE_     ERROR The device had an error and could not complete the request.\r
-  @retval EFI_UNSUPPORTED The attribute requested is not defined.\r
+  @retval EFI_SUCCESS       The attribute was set.\r
+  @retval EFI_DEVICE_ERROR  The device had an error and could not complete the request.\r
+  @retval EFI_UNSUPPORTED   The attribute requested is not defined.\r
 \r
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_TEXT_SET_ATTRIBUTE) (\r
+(EFIAPI *EFI_TEXT_SET_ATTRIBUTE)(\r
   IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL        *This,\r
   IN UINTN                                  Attribute\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Clears the output device(s) display to the currently selected background \r
@@ -295,10 +287,9 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_TEXT_CLEAR_SCREEN) (\r
+(EFIAPI *EFI_TEXT_CLEAR_SCREEN)(\r
   IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL   *This\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Sets the current coordinates of the cursor position\r
@@ -319,12 +310,11 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_TEXT_SET_CURSOR_POSITION) (\r
+(EFIAPI *EFI_TEXT_SET_CURSOR_POSITION)(\r
   IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL        *This,\r
   IN UINTN                                  Column,\r
   IN UINTN                                  Row\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Makes the cursor visible or invisible\r
@@ -342,36 +332,53 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_TEXT_ENABLE_CURSOR) (\r
+(EFIAPI *EFI_TEXT_ENABLE_CURSOR)(\r
   IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL        *This,\r
   IN BOOLEAN                                Visible\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
+  @par Data Structure Description:\r
   Mode Structure pointed to by Simple Text Out protocol.\r
-\r
-  MaxMode   - The number of modes supported by QueryMode () and SetMode ().\r
-  Mode      - The text mode of the output device(s).\r
-  Attribute - The current character output attribute\r
-  CursorColumn  - The cursor's column.\r
-  CursorRow     - The cursor's row.\r
-  CursorVisible - The cursor is currently visbile or not.\r
-\r
 **/\r
 typedef struct {\r
+  ///\r
+  /// The number of modes supported by QueryMode () and SetMode ().\r
+  ///\r
   INT32   MaxMode;\r
 \r
   //\r
   // current settings\r
   //\r
+\r
+  ///\r
+  /// The text mode of the output device(s).\r
+  ///\r
   INT32   Mode;\r
+  ///\r
+  /// The current character output attribute\r
+  ///\r
   INT32   Attribute;\r
+  ///\r
+  /// The cursor's column.\r
+  ///\r
   INT32   CursorColumn;\r
+  ///\r
+  /// The cursor's row.\r
+  ///\r
   INT32   CursorRow;\r
+  ///\r
+  /// The cursor is currently visbile or not.\r
+  ///\r
   BOOLEAN CursorVisible;\r
 } EFI_SIMPLE_TEXT_OUTPUT_MODE;\r
 \r
+///\r
+/// The SIMPLE_TEXT_OUTPUT protocol is used to control text-based output devices. \r
+/// It is the minimum required protocol for any handle supplied as the ConsoleOut \r
+/// or StandardError device. In addition, the minimum supported text mode of such \r
+/// devices is at least 80 x 25 characters.\r
+///\r
 struct _EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL {\r
   EFI_TEXT_RESET                Reset;\r
 \r
@@ -386,9 +393,9 @@ struct _EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL {
   EFI_TEXT_SET_CURSOR_POSITION  SetCursorPosition;\r
   EFI_TEXT_ENABLE_CURSOR        EnableCursor;\r
 \r
-  //\r
-  // Current mode\r
-  //\r
+  ///\r
+  /// Pointer to SIMPLE_TEXT_OUTPUT_MODE data.\r
+  ///\r
   EFI_SIMPLE_TEXT_OUTPUT_MODE   *Mode;\r
 };\r
 \r