a single hardware device or a virtual device that is an aggregation\r
of multiple physical devices.\r
\r
-Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved<BR>\r
-This program and the accompanying materials are licensed and made available under \r
-the terms and conditions of the BSD License that accompanies this distribution. \r
-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) 2006 - 2018, Intel Corporation. All rights reserved.<BR>\r
+SPDX-License-Identifier: BSD-2-Clause-Patent\r
\r
**/\r
\r
\r
///\r
/// Protocol GUID defined in EFI1.1.\r
-/// \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
typedef EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL SIMPLE_TEXT_OUTPUT_INTERFACE;\r
\r
//\r
#define EFI_BROWN (EFI_GREEN | EFI_RED)\r
#define EFI_LIGHTGRAY (EFI_BLUE | EFI_GREEN | EFI_RED)\r
#define EFI_BRIGHT 0x08\r
-#define EFI_DARKGRAY (EFI_BRIGHT)\r
+#define EFI_DARKGRAY (EFI_BLACK | EFI_BRIGHT)\r
#define EFI_LIGHTBLUE (EFI_BLUE | EFI_BRIGHT)\r
#define EFI_LIGHTGREEN (EFI_GREEN | EFI_BRIGHT)\r
#define EFI_LIGHTCYAN (EFI_CYAN | EFI_BRIGHT)\r
#define EFI_YELLOW (EFI_BROWN | EFI_BRIGHT)\r
#define EFI_WHITE (EFI_BLUE | EFI_GREEN | EFI_RED | EFI_BRIGHT)\r
\r
-#define EFI_TEXT_ATTR(f, b) ((f) | ((b) << 4))\r
+//\r
+// Macro to accept color values in their raw form to create\r
+// a value that represents both a foreground and background\r
+// color in a single byte.\r
+// For Foreground, and EFI_* value is valid from EFI_BLACK(0x00) to\r
+// EFI_WHITE (0x0F).\r
+// For Background, only EFI_BLACK, EFI_BLUE, EFI_GREEN, EFI_CYAN,\r
+// EFI_RED, EFI_MAGENTA, EFI_BROWN, and EFI_LIGHTGRAY are acceptable\r
+//\r
+// Do not use EFI_BACKGROUND_xxx values with this macro.\r
+//\r
+#define EFI_TEXT_ATTR(Foreground,Background) ((Foreground) | ((Background) << 4))\r
\r
#define EFI_BACKGROUND_BLACK 0x00\r
#define EFI_BACKGROUND_BLUE 0x10\r
\r
//\r
// We currently define attributes from 0 - 7F for color manipulations\r
-// To internally handle the local display characteristics for a particular character, \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
Reset the text output device hardware and optionaly run diagnostics\r
\r
@param This The protocol instance pointer.\r
- @param ExtendedVerification Driver may perform more exhaustive verfication\r
+ @param ExtendedVerification Driver may perform more exhaustive verification\r
operation of the device during reset.\r
\r
@retval EFI_SUCCESS The text output device was reset.\r
);\r
\r
/**\r
- Verifies that all characters in a 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 The protocol instance pointer.\r
requested ModeNumber.\r
@param Rows Returns the geometry of the text output device for the\r
requested ModeNumber.\r
- \r
+\r
@retval EFI_SUCCESS The requested mode information was returned.\r
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.\r
@retval EFI_UNSUPPORTED The mode number was not valid.\r
);\r
\r
/**\r
- Clears the output device(s) display to the currently selected background \r
+ Clears the output device(s) display to the currently selected background\r
color.\r
\r
@param This The protocol instance pointer.\r
- \r
+\r
@retval EFI_SUCCESS The operation completed successfully.\r
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.\r
@retval EFI_UNSUPPORTED The output device is not in a valid text mode.\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
+/// 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