]> git.proxmox.com Git - mirror_edk2.git/commitdiff
apply for doxgen format.
authorvanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 10 Apr 2008 08:49:28 +0000 (08:49 +0000)
committervanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 10 Apr 2008 08:49:28 +0000 (08:49 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5038 6f19259b-4bc3-4df7-8a09-765794883524

38 files changed:
MdeModulePkg/Bus/Usb/UsbMassStorageDxe/ComponentName.c
MdeModulePkg/Core/RuntimeDxe/Crc32.c
MdeModulePkg/Core/RuntimeDxe/Runtime.c
MdeModulePkg/Core/RuntimeDxe/Runtime.h
MdeModulePkg/Universal/Console/ConPlatformDxe/ComponentName.c
MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatform.c
MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatform.h
MdeModulePkg/Universal/Console/ConSplitterDxe/ComponentName.c
MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterGraphics.c
MdeModulePkg/Universal/Console/GraphicsConsoleDxe/ComponentName.c
MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.h
MdeModulePkg/Universal/Console/GraphicsConsoleDxe/LaffStd.c
MdeModulePkg/Universal/Console/TerminalDxe/ComponentName.c
MdeModulePkg/Universal/Console/TerminalDxe/Terminal.c
MdeModulePkg/Universal/Console/TerminalDxe/Terminal.h
MdeModulePkg/Universal/Console/TerminalDxe/TerminalConIn.c
MdeModulePkg/Universal/Console/TerminalDxe/TerminalConOut.c
MdeModulePkg/Universal/Console/TerminalDxe/ansi.c
MdeModulePkg/Universal/Console/TerminalDxe/vtutf8.c
MdeModulePkg/Universal/DebugPortDxe/ComponentName.c
MdeModulePkg/Universal/DebugPortDxe/DebugPort.c
MdeModulePkg/Universal/DebugPortDxe/DebugPort.h
MdeModulePkg/Universal/DebugSupportDxe/DebugSupport.c
MdeModulePkg/Universal/EbcDxe/EbcExecute.c
MdeModulePkg/Universal/EbcDxe/EbcExecute.h
MdeModulePkg/Universal/EbcDxe/EbcInt.c
MdeModulePkg/Universal/EbcDxe/EbcInt.h
MdeModulePkg/Universal/EbcDxe/Ia32/EbcSupport.c
MdeModulePkg/Universal/EbcDxe/Ipf/EbcSupport.c
MdeModulePkg/Universal/EbcDxe/Ipf/EbcSupport.h
MdeModulePkg/Universal/EbcDxe/x64/EbcSupport.c
MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounter.c
MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounter.h
MdeModulePkg/Universal/Network/SnpDxe/Callback.c
MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/Ia32/Ia32PcRtc.c
MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c
MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.h
MdeModulePkg/Universal/PcatSingleSegmentPciCfg2Pei/PciCfg2.c

index e2e5c4557a09a37acad9d37fb5d5cb8773ee6194..60d51cda24b974e14f52c0666211d9541107da67 100644 (file)
@@ -1,4 +1,5 @@
- /*++\r
+/** @file\r
+  UEFI Component Name(2) protocol implementation.\r
 \r
 Copyright (c) 2004 - 2007, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
@@ -15,7 +16,8 @@ Module Name:
 \r
 Abstract:\r
 \r
---*/\r
+\r
+**/\r
 \r
 \r
 #include <PiDxe.h>\r
index f2c8f0227aa4bc48035317058ab6068a93d2b3bd..0e7e793365d2f1f5096e32c845b54747c763e0dd 100644 (file)
@@ -1,13 +1,14 @@
-/*++\r
+/** @file\r
+  CalculateCrc32 Boot Services as defined in DXE CIS.\r
+\r
+Copyright (c) 2006, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Copyright (c) 2006, 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
-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
+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
 \r
 Module Name:\r
 \r
@@ -15,22 +16,30 @@ Module Name:
 \r
 Abstract:\r
 \r
-  CalculateCrc32 Boot Services as defined in DXE CIS.\r
-\r
   This Boot Services is in the Runtime Driver because this service is\r
   also required by SetVirtualAddressMap() when the EFI System Table and\r
-  EFI Runtime Services Table are converted from physical address to \r
+  EFI Runtime Services Table are converted from physical address to\r
   virtual addresses.  This requires that the 32-bit CRC be recomputed.\r
 \r
-Revision History:\r
-\r
---*/\r
+**/\r
 \r
 \r
 #include <PiDxe.h>\r
 \r
 UINT32  mCrcTable[256];\r
 \r
+/**\r
+  Calculate CRC32 for target data.\r
+\r
+  @param  Len                   The target data.\r
+  @param  DataSize              The target data size.\r
+  @param  CrcOut                The CRC32 for target data.\r
+\r
+  @retval EFI_SUCCESS           The CRC32 for target data is calculated successfully.\r
+  @retval EFI_INVALID_PARAMETER Some parameter is not valid, so the CRC32 is not\r
+                                calculated.\r
+\r
+**/\r
 EFI_STATUS\r
 EFIAPI\r
 RuntimeDriverCalculateCrc32 (\r
@@ -38,25 +47,6 @@ RuntimeDriverCalculateCrc32 (
   IN  UINTN   DataSize,\r
   OUT UINT32  *CrcOut\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Calculate CRC32 for target data\r
-\r
-Arguments:\r
-\r
-  Data     - The target data.\r
-  DataSize - The target data size.\r
-  CrcOut   - The CRC32 for target data.\r
-\r
-Returns:\r
-\r
-  EFI_SUCCESS           - The CRC32 for target data is calculated successfully.\r
-  EFI_INVALID_PARAMETER - Some parameter is not valid, so the CRC32 is not \r
-                          calculated.\r
-\r
---*/\r
 {\r
   UINT32  Crc;\r
   UINTN   Index;\r
@@ -75,26 +65,20 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-UINT32\r
-ReverseBits (\r
-  UINT32  Value\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Reverse bits for 32bit data.\r
 \r
-Arguments:\r
-\r
-  Value - the data to be reversed.\r
-\r
-Returns:\r
+  @param  Value                 The data to be reversed.\r
 \r
-  UINT32 data reversed.\r
+  @retrun                       Data reversed.\r
 \r
---*/\r
+**/\r
+STATIC\r
+UINT32\r
+ReverseBits (\r
+  UINT32  Value\r
+  )\r
 {\r
   UINTN   Index;\r
   UINT32  NewValue;\r
@@ -109,25 +93,18 @@ Returns:
   return NewValue;\r
 }\r
 \r
-VOID\r
-RuntimeDriverInitializeCrc32Table (\r
-  VOID\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
-\r
+/**\r
   Initialize CRC32 table.\r
 \r
-Arguments:\r
-\r
-  None.\r
+  @param  None\r
 \r
-Returns:\r
+  @retrun None\r
 \r
-  None.\r
-\r
---*/\r
+**/\r
+VOID\r
+RuntimeDriverInitializeCrc32Table (\r
+  VOID\r
+  )\r
 {\r
   UINTN   TableEntry;\r
   UINTN   Index;\r
index 1f09fa383f24e65c5e7b5aabdb5401e616b9945b..efd7dec05cfdfc6d95c28816ccb09268fdbbf43e 100644 (file)
@@ -1,6 +1,7 @@
-/*++\r
+/** @file\r
+  Runtime Architectural Protocol as defined in the DXE CIS.\r
 \r
-Copyright (c) 2006, Intel Corporation\r
+Copyright (c) 2006, Intel Corporation. <BR>\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
@@ -15,8 +16,6 @@ Module Name:
 \r
 Abstract:\r
 \r
-  Runtime Architectural Protocol as defined in the DXE CIS\r
-\r
   This code is used to produce the EFI runtime virtual switch over\r
 \r
   THIS IS VERY DANGEROUS CODE BE VERY CAREFUL IF YOU CHANGE IT\r
@@ -49,7 +48,7 @@ Revision History:
   Runtime Arch Protocol definition no longer contains CalculateCrc32. Boot Service\r
   Table now contains an item named CalculateCrc32.\r
 \r
---*/\r
+**/\r
 \r
 #include "Runtime.h"\r
 \r
@@ -367,7 +366,7 @@ Returns:
 \r
   //\r
   // UEFI don't require System Configuration Tables Conversion.\r
-  // \r
+  //\r
 \r
   //\r
   // Convert the runtime fields of the EFI System Table and recompute the CRC-32\r
index 0078da2b9102d54c61fc163cd64b2e80c8ea8c5f..4ff21ea5b68fb6c7a727ff6d1da83cc5399fbd0a 100644 (file)
@@ -1,25 +1,25 @@
-/*++\r
+/** @file\r
+  Runtime Architectural Protocol as defined in the DXE CIS.\r
 \r
-Copyright (c) 2006, Intel Corporation\r
+Copyright (c) 2006, Intel Corporation. <BR>\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
 http://opensource.org/licenses/bsd-license.php\r
-                                                                                          \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
 \r
+\r
 Module Name:\r
 \r
   Runtime.h\r
 \r
 Abstract:\r
 \r
-  Runtime Architectural Protocol as defined in the DXE CIS\r
-\r
   This code is used to produce the EFI runtime architectural protocol.\r
 \r
---*/\r
+**/\r
 \r
 #ifndef _RUNTIME_H_\r
 #define _RUNTIME_H_\r
index 075b6956822ccb77a8970b7a4a4d765c6e5f4513..8dfd8d8ac7b1ebe83487bbc43cd2dbc2afd1e493 100644 (file)
@@ -1,21 +1,16 @@
-/*++\r
+/** @file\r
+  UEFI Component Name(2) protocol implementation for ConPlatform driver.\r
 \r
-Copyright (c) 2006, 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
-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, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Module Name:\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
 \r
-  ComponentName.c\r
-\r
-Abstract:\r
-\r
---*/\r
+**/\r
 \r
 //\r
 // Include common header file for this module.\r
index d5120eb5b21748aeac553e36d3c142ace893f94f..af2d2221fe7e97549eae71012aeb87a25912d413 100644 (file)
@@ -1,6 +1,7 @@
-/*++\r
+/** @file\r
+  Console Platfrom DXE Driver, install Console protocols.\r
 \r
-Copyright (c) 2006 - 2007, Intel Corporation\r
+Copyright (c) 2006 - 2007, Intel Corporation. <BR>\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
@@ -9,13 +10,7 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
-Module Name:\r
-\r
-    ConPlatform.c\r
-\r
-Abstract:\r
-\r
---*/\r
+**/\r
 \r
 #include <ConPlatform.h>\r
 \r
index 231a20c776e3b99eca83b879367e6fd918d3d82a..c24d80e0b16a020a2840dfd1958526f558f59920 100644 (file)
@@ -1,21 +1,16 @@
-/*++\r
+/** @file\r
+  Header file for Console Platfrom DXE Driver.\r
 \r
-Copyright (c) 2006, 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
-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 - 2007, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Module Name:\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
 \r
-    ConPlatform.h\r
-    \r
-Abstract:\r
-\r
---*/\r
+**/\r
 \r
 #ifndef CON_MANAGE_H_\r
 #define CON_MANAGE_H_\r
@@ -24,11 +19,12 @@ Abstract:
 #include <Protocol/SimpleTextOut.h>\r
 #include <Guid/GlobalVariable.h>\r
 #include <Guid/ConsoleInDevice.h>\r
+#include <Guid/StandardErrorDevice.h>\r
+#include <Guid/ConsoleOutDevice.h>\r
 #include <Protocol/DevicePath.h>\r
 #include <Protocol/SimpleTextIn.h>\r
 #include <Guid/HotPlugDevice.h>\r
-#include <Guid/StandardErrorDevice.h>\r
-#include <Guid/ConsoleOutDevice.h>\r
+\r
 #include <Library/DebugLib.h>\r
 #include <Library/UefiDriverEntryPoint.h>\r
 #include <Library/UefiLib.h>\r
index 45b7cf745bc7f6cb199d9b7e82b108b29a7d1413..927f7a5a687667b0e845abeaf66b5a440b2a8071 100644 (file)
@@ -1,21 +1,16 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
+/** @file\r
+  UEFI Component Name(2) protocol implementation for ConSplitter driver.\r
 \r
-  ComponentName.c\r
+Copyright (c) 2006, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Abstract:\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
 \r
---*/\r
+**/\r
 \r
 #include "ConSplitter.h"\r
 \r
@@ -510,40 +505,40 @@ ConSplitterAbsolutePointerComponentNameGetControllerName (
 \r
   Arguments:\r
     This             - A pointer to the EFI_COMPONENT_NAME_PROTOCOL instance.\r
-    ControllerHandle - The handle of a controller that the driver specified by \r
-                       This is managing.  This handle specifies the controller \r
+    ControllerHandle - The handle of a controller that the driver specified by\r
+                       This is managing.  This handle specifies the controller\r
                        whose name is to be returned.\r
-    ChildHandle      - The handle of the child controller to retrieve the name \r
-                       of.  This is an optional parameter that may be NULL.  It \r
-                       will be NULL for device drivers.  It will also be NULL \r
-                       for a bus drivers that wish to retrieve the name of the \r
-                       bus controller.  It will not be NULL for a bus driver \r
+    ChildHandle      - The handle of the child controller to retrieve the name\r
+                       of.  This is an optional parameter that may be NULL.  It\r
+                       will be NULL for device drivers.  It will also be NULL\r
+                       for a bus drivers that wish to retrieve the name of the\r
+                       bus controller.  It will not be NULL for a bus driver\r
                        that wishes to retrieve the name of a child controller.\r
-    Language         - A pointer to RFC3066 language identifier. \r
-                       This is the language of the controller name \r
+    Language         - A pointer to RFC3066 language identifier.\r
+                       This is the language of the controller name\r
                        that that the caller is requesting, and it must match one\r
-                       of the languages specified in SupportedLanguages.  The \r
-                       number of languages supported by a driver is up to the \r
+                       of the languages specified in SupportedLanguages.  The\r
+                       number of languages supported by a driver is up to the\r
                        driver writer.\r
     ControllerName   - A pointer to the Unicode string to return.  This Unicode\r
-                       string is the name of the controller specified by \r
-                       ControllerHandle and ChildHandle in the language \r
-                       specified by Language from the point of view of the \r
-                       driver specified by This. \r
+                       string is the name of the controller specified by\r
+                       ControllerHandle and ChildHandle in the language\r
+                       specified by Language from the point of view of the\r
+                       driver specified by This.\r
 \r
   Returns:\r
     EFI_SUCCESS           - The Unicode string for the user readable name in the\r
-                            language specified by Language for the driver \r
+                            language specified by Language for the driver\r
                             specified by This was returned in DriverName.\r
     EFI_INVALID_PARAMETER - ControllerHandle is not a valid EFI_HANDLE.\r
-    EFI_INVALID_PARAMETER - ChildHandle is not NULL and it is not a valid \r
+    EFI_INVALID_PARAMETER - ChildHandle is not NULL and it is not a valid\r
                             EFI_HANDLE.\r
     EFI_INVALID_PARAMETER - Language is NULL.\r
     EFI_INVALID_PARAMETER - ControllerName is NULL.\r
-    EFI_UNSUPPORTED       - The driver specified by This is not currently \r
-                            managing the controller specified by \r
+    EFI_UNSUPPORTED       - The driver specified by This is not currently\r
+                            managing the controller specified by\r
                             ControllerHandle and ChildHandle.\r
-    EFI_UNSUPPORTED       - The driver specified by This does not support the \r
+    EFI_UNSUPPORTED       - The driver specified by This does not support the\r
                             language specified by Language.\r
 \r
 --*/\r
index 20f27a20fbd21f61b4f4d0c11bce32b6abee67c2..28de49c773b1633d511412c85de85dfa2494f182 100644 (file)
@@ -1,6 +1,10 @@
-/*++\r
+/** @file\r
+  Support for ConsoleControl protocol. Support for Graphics output spliter.\r
+  Support for DevNull Console Out. This console uses memory buffers\r
+  to represnt the console. It allows a console to start very early and\r
+  when a new console is added it is synced up with the current console.\r
 \r
-Copyright (c) 2006 - 2008, Intel Corporation\r
+Copyright (c) 2006 - 2008, Intel Corporation. <BR>\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
@@ -9,18 +13,8 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
-Module Name:\r
-\r
-  ConSplitterGraphics.c\r
-\r
-Abstract:\r
+**/\r
 \r
-  Support for ConsoleControl protocol. Support for Graphics output spliter.\r
-  Support for DevNull Console Out. This console uses memory buffers\r
-  to represnt the console. It allows a console to start very early and\r
-  when a new console is added it is synced up with the current console\r
-\r
---*/\r
 \r
 #include "ConSplitter.h"\r
 \r
index 5b4dd01b63bec23a2c74d77764124343da7c4f0a..98bbfc2c66e56e72051f975c5ec63f4e1a39bf44 100644 (file)
@@ -1,21 +1,16 @@
-/*++\r
+/** @file\r
+  UEFI Component Name(2) protocol implementation for GraphicsConsole driver.\r
 \r
-Copyright (c) 2006, 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
-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, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Module Name:\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
 \r
-  ComponentName.c\r
-\r
-Abstract:\r
-\r
---*/\r
+**/\r
 \r
 #include "GraphicsConsole.h"\r
 \r
index 5bdbf7f4cd9854feb3a350a3819192c97913e0b7..7d300a7660d708a2240fbe29bdc760c080c5bc94 100644 (file)
@@ -1,6 +1,7 @@
-/*++\r
+/** @file\r
+  Header file for GraphicsConsole driver.\r
 \r
-Copyright (c) 2006 - 2008, Intel Corporation\r
+Copyright (c) 2006, Intel Corporation. <BR>\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
@@ -9,16 +10,7 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
-Module Name:\r
-\r
-  GraphicsConsole.h\r
-\r
-Abstract:\r
-\r
-\r
-Revision History\r
-\r
---*/\r
+**/\r
 \r
 #ifndef _GRAPHICS_CONSOLE_H\r
 #define _GRAPHICS_CONSOLE_H\r
index ac8dd168337e208e3926ead215f6787d2a9b22ba..76c8fca64f1f35b76370498561b5c5c1a9de74e3 100644 (file)
@@ -1,24 +1,16 @@
-/*++\r
+/** @file\r
+  Narrow font Data definition for GraphicsConsole driver.\r
 \r
-Copyright (c) 2006, 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
-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, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Module Name:\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
 \r
-  LaffStd.c\r
-\r
-Abstract:\r
-\r
-  \r
-Revision History\r
-\r
---*/\r
+**/\r
 \r
 #include "GraphicsConsole.h"\r
 \r
index 11ee906c25dc573f5079e6bba8e164867a71362b..f12b6241b4950c45601926239d9b1154bdbc7769 100644 (file)
@@ -1,21 +1,16 @@
-/*++\r
+/** @file\r
+  UEFI Component Name(2) protocol implementation for Terminal driver.\r
 \r
-Copyright (c) 2006, 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
-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 - 2008, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Module Name:\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
 \r
-  ComponentName.c\r
-\r
-Abstract:\r
-\r
---*/\r
+**/\r
 \r
 #include "Terminal.h"\r
 \r
index 06c4f66e08673d7f9cee3b75cd241b24aae9ea04..76b603c3a3db006f74d7ae44b3ba354a7cf7d120 100644 (file)
@@ -1,6 +1,8 @@
-/*++\r
+/** @file\r
+  Produces Simple Text Input Protocl, Simple Text Input Extended Protocol and\r
+  Simple Text Output Protocol upon Serial IO Protocol.\r
 \r
-Copyright (c) 2006, Intel Corporation\r
+Copyright (c) 2006 - 2008, Intel Corporation. <BR>\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
@@ -9,15 +11,7 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
-Module Name:\r
-\r
-    Terminal.c\r
-\r
-Abstract:\r
-\r
-Revision History:\r
-\r
---*/\r
+**/\r
 \r
 \r
 #include "Terminal.h"\r
@@ -26,7 +20,7 @@ STATIC
 EFI_STATUS\r
 TerminalFreeNotifyList (\r
   IN OUT LIST_ENTRY           *ListHead\r
-  );  \r
+  );\r
 \r
 //\r
 // Globals\r
@@ -97,7 +91,7 @@ TERMINAL_DEV  gTerminalDevTemplate = {
     { {0} }\r
   },\r
   NULL, // ControllerNameTable\r
-  NULL, \r
+  NULL,\r
   INPUT_STATE_DEFAULT,\r
   RESET_STATE_DEFAULT,\r
   FALSE,\r
@@ -960,15 +954,15 @@ Returns:
   }\r
   while (!IsListEmpty (ListHead)) {\r
     NotifyNode = CR (\r
-                   ListHead->ForwardLink, \r
-                   TERMINAL_CONSOLE_IN_EX_NOTIFY, \r
-                   NotifyEntry, \r
+                   ListHead->ForwardLink,\r
+                   TERMINAL_CONSOLE_IN_EX_NOTIFY,\r
+                   NotifyEntry,\r
                    TERMINAL_CONSOLE_IN_EX_NOTIFY_SIGNATURE\r
                    );\r
     RemoveEntryList (ListHead->ForwardLink);\r
     gBS->FreePool (NotifyNode);\r
   }\r
-  \r
+\r
   return EFI_SUCCESS;\r
 }\r
 \r
@@ -1344,9 +1338,9 @@ InitializeEfiKeyFiFo (
 /**\r
   The user Entry Point for module Terminal. The user code starts with this function.\r
 \r
-  @param[in] ImageHandle    The firmware allocated handle for the EFI image.  \r
+  @param[in] ImageHandle    The firmware allocated handle for the EFI image.\r
   @param[in] SystemTable    A pointer to the EFI System Table.\r
-  \r
+\r
   @retval EFI_SUCCESS       The entry point is executed successfully.\r
   @retval other             Some error occurs when executing this entry point.\r
 \r
index ba573a6efecff5a317a1354140872914017efab8..86808bbc56f716eca1ff58e188601a5e6dc0d42f 100644 (file)
@@ -1,24 +1,16 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
-\r
-  terminal.h\r
+/** @file\r
+  Header file for Terminal driver.\r
 \r
-Abstract:\r
+Copyright (c) 2006 - 2008, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-  \r
-Revision History\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
 \r
---*/\r
+**/\r
 \r
 #ifndef _TERMINAL_H\r
 #define _TERMINAL_H\r
@@ -212,15 +204,15 @@ Routine Description:
 \r
 Arguments:\r
 \r
-  RegsiteredData    - A pointer to a buffer that is filled in with the keystroke \r
+  RegsiteredData    - A pointer to a buffer that is filled in with the keystroke\r
                       state data for the key that was registered.\r
-  InputData         - A pointer to a buffer that is filled in with the keystroke \r
+  InputData         - A pointer to a buffer that is filled in with the keystroke\r
                       state data for the key that was pressed.\r
 \r
 Returns:\r
   TRUE              - Key be pressed matches a registered key.\r
-  FLASE             - Match failed. \r
-  \r
+  FLASE             - Match failed.\r
+\r
 --*/\r
 ;\r
 \r
@@ -230,7 +222,7 @@ TerminalConInWaitForKeyEx (
   IN  EFI_EVENT       Event,\r
   IN  VOID            *Context\r
   )\r
-;  \r
+;\r
 //\r
 // Simple Text Input Ex protocol prototypes\r
 //\r
@@ -252,7 +244,7 @@ TerminalConInResetEx (
 \r
   Returns:\r
     EFI_SUCCESS           - The device was reset.\r
-    EFI_DEVICE_ERROR      - The device is not functioning properly and could \r
+    EFI_DEVICE_ERROR      - The device is not functioning properly and could\r
                             not be reset.\r
 \r
 --*/\r
@@ -267,20 +259,20 @@ TerminalConInReadKeyStrokeEx (
 /*++\r
 \r
   Routine Description:\r
-    Reads the next keystroke from the input device. The WaitForKey Event can \r
+    Reads the next keystroke from the input device. The WaitForKey Event can\r
     be used to test for existance of a keystroke via WaitForEvent () call.\r
 \r
   Arguments:\r
     This       - Protocol instance pointer.\r
-    KeyData    - A pointer to a buffer that is filled in with the keystroke \r
+    KeyData    - A pointer to a buffer that is filled in with the keystroke\r
                  state data for the key that was pressed.\r
 \r
   Returns:\r
     EFI_SUCCESS           - The keystroke information was returned.\r
     EFI_NOT_READY         - There was no keystroke data availiable.\r
-    EFI_DEVICE_ERROR      - The keystroke information was not returned due to \r
+    EFI_DEVICE_ERROR      - The keystroke information was not returned due to\r
                             hardware errors.\r
-    EFI_INVALID_PARAMETER - KeyData is NULL.                        \r
+    EFI_INVALID_PARAMETER - KeyData is NULL.\r
 \r
 --*/\r
 ;\r
@@ -298,17 +290,17 @@ TerminalConInSetState (
 \r
   Arguments:\r
     This                  - Protocol instance pointer.\r
-    KeyToggleState        - A pointer to the EFI_KEY_TOGGLE_STATE to set the \r
+    KeyToggleState        - A pointer to the EFI_KEY_TOGGLE_STATE to set the\r
                             state for the input device.\r
-                          \r
-  Returns:                \r
+\r
+  Returns:\r
     EFI_SUCCESS           - The device state was set successfully.\r
-    EFI_DEVICE_ERROR      - The device is not functioning correctly and could \r
+    EFI_DEVICE_ERROR      - The device is not functioning correctly and could\r
                             not have the setting adjusted.\r
     EFI_UNSUPPORTED       - The device does not have the ability to set its state.\r
-    EFI_INVALID_PARAMETER - KeyToggleState is NULL.                       \r
+    EFI_INVALID_PARAMETER - KeyToggleState is NULL.\r
 \r
---*/   \r
+--*/\r
 ;\r
 \r
 EFI_STATUS\r
@@ -326,18 +318,18 @@ TerminalConInRegisterKeyNotify (
 \r
   Arguments:\r
     This                    - Protocol instance pointer.\r
-    KeyData                 - A pointer to a buffer that is filled in with the keystroke \r
+    KeyData                 - A pointer to a buffer that is filled in with the keystroke\r
                               information data for the key that was pressed.\r
-    KeyNotificationFunction - Points to the function to be called when the key \r
-                              sequence is typed specified by KeyData.                        \r
-    NotifyHandle            - Points to the unique handle assigned to the registered notification.                          \r
+    KeyNotificationFunction - Points to the function to be called when the key\r
+                              sequence is typed specified by KeyData.\r
+    NotifyHandle            - Points to the unique handle assigned to the registered notification.\r
 \r
   Returns:\r
     EFI_SUCCESS             - The notification function was registered successfully.\r
     EFI_OUT_OF_RESOURCES    - Unable to allocate resources for necesssary data structures.\r
-    EFI_INVALID_PARAMETER   - KeyData or NotifyHandle is NULL.                       \r
-                              \r
---*/   \r
+    EFI_INVALID_PARAMETER   - KeyData or NotifyHandle is NULL.\r
+\r
+--*/\r
 ;\r
 \r
 EFI_STATUS\r
@@ -352,15 +344,15 @@ TerminalConInUnregisterKeyNotify (
     Remove a registered notification function from a particular keystroke.\r
 \r
   Arguments:\r
-    This                    - Protocol instance pointer.    \r
+    This                    - Protocol instance pointer.\r
     NotificationHandle      - The handle of the notification function being unregistered.\r
 \r
   Returns:\r
     EFI_SUCCESS             - The notification function was unregistered successfully.\r
     EFI_INVALID_PARAMETER   - The NotificationHandle is invalid.\r
-    EFI_NOT_FOUND           - Can not find the matching entry in database.  \r
-                              \r
---*/   \r
+    EFI_NOT_FOUND           - Can not find the matching entry in database.\r
+\r
+--*/\r
 ;\r
 \r
 VOID\r
index a4ad034989ceaa13906bd941ffb89ec82f2a510b..404e46e0e73d38a07372cfeb46c114df2244a7e0 100644 (file)
@@ -1,14 +1,14 @@
 /**@file\r
   Implementation for EFI_SIMPLE_TEXT_INPUT_PROTOCOL protocol.\r
-  \r
-Copyright (c) 2006 - 2007 Intel Corporation. <BR>\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
-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
+\r
+Copyright (c) 2006 - 2007, Intel Corporation. <BR>\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
+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
 \r
 **/\r
 \r
@@ -24,20 +24,20 @@ ReadKeyStrokeWorker (
 /*++\r
 \r
   Routine Description:\r
-    Reads the next keystroke from the input device. The WaitForKey Event can \r
+    Reads the next keystroke from the input device. The WaitForKey Event can\r
     be used to test for existance of a keystroke via WaitForEvent () call.\r
 \r
   Arguments:\r
     TerminalDevice        - Terminal driver private structure\r
-    KeyData               - A pointer to a buffer that is filled in with the keystroke \r
+    KeyData               - A pointer to a buffer that is filled in with the keystroke\r
                             state data for the key that was pressed.\r
 \r
   Returns:\r
     EFI_SUCCESS           - The keystroke information was returned.\r
     EFI_NOT_READY         - There was no keystroke data availiable.\r
-    EFI_DEVICE_ERROR      - The keystroke information was not returned due to \r
+    EFI_DEVICE_ERROR      - The keystroke information was not returned due to\r
                             hardware errors.\r
-    EFI_INVALID_PARAMETER - KeyData is NULL.                        \r
+    EFI_INVALID_PARAMETER - KeyData is NULL.\r
 \r
 --*/\r
 {\r
@@ -47,7 +47,7 @@ ReadKeyStrokeWorker (
 \r
   if (KeyData == NULL) {\r
     return EFI_INVALID_PARAMETER;\r
-  }  \r
+  }\r
 \r
   //\r
   // Initialize *Key to nonsense value.\r
@@ -72,12 +72,12 @@ ReadKeyStrokeWorker (
   //\r
   for (Link = TerminalDevice->NotifyList.ForwardLink; Link != &TerminalDevice->NotifyList; Link = Link->ForwardLink) {\r
     CurrentNotify = CR (\r
-                      Link, \r
-                      TERMINAL_CONSOLE_IN_EX_NOTIFY, \r
-                      NotifyEntry, \r
+                      Link,\r
+                      TERMINAL_CONSOLE_IN_EX_NOTIFY,\r
+                      NotifyEntry,\r
                       TERMINAL_CONSOLE_IN_EX_NOTIFY_SIGNATURE\r
                       );\r
-    if (IsKeyRegistered (&CurrentNotify->KeyData, KeyData)) { \r
+    if (IsKeyRegistered (&CurrentNotify->KeyData, KeyData)) {\r
       CurrentNotify->KeyNotificationFn (KeyData);\r
     }\r
   }\r
@@ -95,25 +95,25 @@ TerminalConInReset (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Implements EFI_SIMPLE_TEXT_INPUT_PROTOCOL.Reset().\r
-    This driver only perform dependent serial device reset regardless of \r
+    This driver only perform dependent serial device reset regardless of\r
     the value of ExtendeVerification\r
-  \r
+\r
   Arguments:\r
-  \r
+\r
     This - Indicates the calling context.\r
-    \r
+\r
     ExtendedVerification - Skip by this driver.\r
-        \r
+\r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
-       The reset operation succeeds.   \r
-    \r
+       The reset operation succeeds.\r
+\r
     EFI_DEVICE_ERROR\r
       The dependent serial port reset fails.\r
-                \r
+\r
 --*/\r
 {\r
   EFI_STATUS    Status;\r
@@ -158,27 +158,27 @@ TerminalConInReadKeyStroke (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Implements EFI_SIMPLE_TEXT_INPUT_PROTOCOL.ReadKeyStroke().\r
-      \r
+\r
   Arguments:\r
-  \r
+\r
     This - Indicates the calling context.\r
-    \r
+\r
     Key  - A pointer to a buffer that is filled in with the keystroke\r
-        information for the key that was sent from terminal.        \r
-        \r
+        information for the key that was sent from terminal.\r
+\r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
       The keystroke information is returned successfully.\r
-       \r
+\r
     EFI_NOT_READY\r
       There is no keystroke data available.\r
\r
+\r
     EFI_DEVICE_ERROR\r
       The dependent serial device encounters error.\r
-                \r
+\r
 --*/\r
 {\r
   TERMINAL_DEV  *TerminalDevice;\r
@@ -213,24 +213,24 @@ Routine Description:
 \r
 Arguments:\r
 \r
-  RegsiteredData    - A pointer to a buffer that is filled in with the keystroke \r
+  RegsiteredData    - A pointer to a buffer that is filled in with the keystroke\r
                       state data for the key that was registered.\r
-  InputData         - A pointer to a buffer that is filled in with the keystroke \r
+  InputData         - A pointer to a buffer that is filled in with the keystroke\r
                       state data for the key that was pressed.\r
 \r
 Returns:\r
   TRUE              - Key be pressed matches a registered key.\r
-  FLASE             - Match failed. \r
-  \r
+  FLASE             - Match failed.\r
+\r
 --*/\r
 {\r
   ASSERT (RegsiteredData != NULL && InputData != NULL);\r
-  \r
+\r
   if ((RegsiteredData->Key.ScanCode    != InputData->Key.ScanCode) ||\r
       (RegsiteredData->Key.UnicodeChar != InputData->Key.UnicodeChar)) {\r
-    return FALSE;  \r
-  }      \r
-  \r
+    return FALSE;\r
+  }\r
+\r
   return TRUE;\r
 }\r
 \r
@@ -243,24 +243,24 @@ TerminalConInWaitForKeyEx (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Event notification function for EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL.WaitForKeyEx event\r
-    Signal the event if there is key available     \r
-  \r
+    Signal the event if there is key available\r
+\r
   Arguments:\r
-  \r
+\r
     Event - Indicates the event that invoke this function.\r
-    \r
+\r
     Context - Indicates the calling context.\r
-        \r
+\r
   Returns:\r
-  \r
+\r
     N/A\r
-                \r
+\r
 --*/\r
 {\r
   TERMINAL_DEV            *TerminalDevice;\r
-  \r
+\r
   TerminalDevice  = TERMINAL_CON_IN_EX_DEV_FROM_THIS (Context);\r
 \r
   TerminalConInWaitForKey (Event, &TerminalDevice->SimpleInput);\r
@@ -288,7 +288,7 @@ TerminalConInResetEx (
 \r
   Returns:\r
     EFI_SUCCESS           - The device was reset.\r
-    EFI_DEVICE_ERROR      - The device is not functioning properly and could \r
+    EFI_DEVICE_ERROR      - The device is not functioning properly and could\r
                             not be reset.\r
 \r
 --*/\r
@@ -304,7 +304,7 @@ TerminalConInResetEx (
   }\r
 \r
   return EFI_SUCCESS;\r
-  \r
+\r
 }\r
 \r
 EFI_STATUS\r
@@ -316,20 +316,20 @@ TerminalConInReadKeyStrokeEx (
 /*++\r
 \r
   Routine Description:\r
-    Reads the next keystroke from the input device. The WaitForKey Event can \r
+    Reads the next keystroke from the input device. The WaitForKey Event can\r
     be used to test for existance of a keystroke via WaitForEvent () call.\r
 \r
   Arguments:\r
     This       - Protocol instance pointer.\r
-    KeyData    - A pointer to a buffer that is filled in with the keystroke \r
+    KeyData    - A pointer to a buffer that is filled in with the keystroke\r
                  state data for the key that was pressed.\r
 \r
   Returns:\r
     EFI_SUCCESS           - The keystroke information was returned.\r
     EFI_NOT_READY         - There was no keystroke data availiable.\r
-    EFI_DEVICE_ERROR      - The keystroke information was not returned due to \r
+    EFI_DEVICE_ERROR      - The keystroke information was not returned due to\r
                             hardware errors.\r
-    EFI_INVALID_PARAMETER - KeyData is NULL.                        \r
+    EFI_INVALID_PARAMETER - KeyData is NULL.\r
 \r
 --*/\r
 {\r
@@ -337,7 +337,7 @@ TerminalConInReadKeyStrokeEx (
 \r
   if (KeyData == NULL) {\r
     return EFI_INVALID_PARAMETER;\r
-  }  \r
+  }\r
 \r
   TerminalDevice = TERMINAL_CON_IN_EX_DEV_FROM_THIS (This);\r
 \r
@@ -358,17 +358,17 @@ TerminalConInSetState (
 \r
   Arguments:\r
     This                  - Protocol instance pointer.\r
-    KeyToggleState        - A pointer to the EFI_KEY_TOGGLE_STATE to set the \r
+    KeyToggleState        - A pointer to the EFI_KEY_TOGGLE_STATE to set the\r
                             state for the input device.\r
-                          \r
-  Returns:                \r
+\r
+  Returns:\r
     EFI_SUCCESS           - The device state was set successfully.\r
-    EFI_DEVICE_ERROR      - The device is not functioning correctly and could \r
+    EFI_DEVICE_ERROR      - The device is not functioning correctly and could\r
                             not have the setting adjusted.\r
     EFI_UNSUPPORTED       - The device does not have the ability to set its state.\r
-    EFI_INVALID_PARAMETER - KeyToggleState is NULL.                       \r
+    EFI_INVALID_PARAMETER - KeyToggleState is NULL.\r
 \r
---*/   \r
+--*/\r
 {\r
   if (KeyToggleState == NULL) {\r
     return EFI_INVALID_PARAMETER;\r
@@ -392,24 +392,24 @@ TerminalConInRegisterKeyNotify (
 \r
   Arguments:\r
     This                    - Protocol instance pointer.\r
-    KeyData                 - A pointer to a buffer that is filled in with the keystroke \r
+    KeyData                 - A pointer to a buffer that is filled in with the keystroke\r
                               information data for the key that was pressed.\r
-    KeyNotificationFunction - Points to the function to be called when the key \r
-                              sequence is typed specified by KeyData.                        \r
-    NotifyHandle            - Points to the unique handle assigned to the registered notification.                          \r
+    KeyNotificationFunction - Points to the function to be called when the key\r
+                              sequence is typed specified by KeyData.\r
+    NotifyHandle            - Points to the unique handle assigned to the registered notification.\r
 \r
   Returns:\r
     EFI_SUCCESS             - The notification function was registered successfully.\r
     EFI_OUT_OF_RESOURCES    - Unable to allocate resources for necesssary data structures.\r
-    EFI_INVALID_PARAMETER   - KeyData or NotifyHandle is NULL.                       \r
-                              \r
---*/   \r
+    EFI_INVALID_PARAMETER   - KeyData or NotifyHandle is NULL.\r
+\r
+--*/\r
 {\r
   EFI_STATUS                      Status;\r
   TERMINAL_DEV                    *TerminalDevice;\r
   TERMINAL_CONSOLE_IN_EX_NOTIFY   *NewNotify;\r
   LIST_ENTRY                      *Link;\r
-  TERMINAL_CONSOLE_IN_EX_NOTIFY   *CurrentNotify;  \r
+  TERMINAL_CONSOLE_IN_EX_NOTIFY   *CurrentNotify;\r
 \r
   if (KeyData == NULL || NotifyHandle == NULL || KeyNotificationFunction == NULL) {\r
     return EFI_INVALID_PARAMETER;\r
@@ -422,14 +422,14 @@ TerminalConInRegisterKeyNotify (
   //\r
   for (Link = TerminalDevice->NotifyList.ForwardLink; Link != &TerminalDevice->NotifyList; Link = Link->ForwardLink) {\r
     CurrentNotify = CR (\r
-                      Link, \r
-                      TERMINAL_CONSOLE_IN_EX_NOTIFY, \r
-                      NotifyEntry, \r
+                      Link,\r
+                      TERMINAL_CONSOLE_IN_EX_NOTIFY,\r
+                      NotifyEntry,\r
                       TERMINAL_CONSOLE_IN_EX_NOTIFY_SIGNATURE\r
                       );\r
-    if (IsKeyRegistered (&CurrentNotify->KeyData, KeyData)) { \r
+    if (IsKeyRegistered (&CurrentNotify->KeyData, KeyData)) {\r
       if (CurrentNotify->KeyNotificationFn == KeyNotificationFunction) {\r
-        *NotifyHandle = CurrentNotify->NotifyHandle;        \r
+        *NotifyHandle = CurrentNotify->NotifyHandle;\r
         return EFI_SUCCESS;\r
       }\r
     }\r
@@ -437,19 +437,19 @@ TerminalConInRegisterKeyNotify (
 \r
   //\r
   // Allocate resource to save the notification function\r
-  //  \r
+  //\r
   NewNotify = (TERMINAL_CONSOLE_IN_EX_NOTIFY *) AllocateZeroPool (sizeof (TERMINAL_CONSOLE_IN_EX_NOTIFY));\r
   if (NewNotify == NULL) {\r
     return EFI_OUT_OF_RESOURCES;\r
-  }  \r
+  }\r
 \r
-  NewNotify->Signature         = TERMINAL_CONSOLE_IN_EX_NOTIFY_SIGNATURE;     \r
+  NewNotify->Signature         = TERMINAL_CONSOLE_IN_EX_NOTIFY_SIGNATURE;\r
   NewNotify->KeyNotificationFn = KeyNotificationFunction;\r
   CopyMem (&NewNotify->KeyData, KeyData, sizeof (KeyData));\r
   InsertTailList (&TerminalDevice->NotifyList, &NewNotify->NotifyEntry);\r
   //\r
   // Use gSimpleTextInExNotifyGuid to get a valid EFI_HANDLE\r
-  //  \r
+  //\r
   Status = gBS->InstallMultipleProtocolInterfaces (\r
                   &NewNotify->NotifyHandle,\r
                   &gSimpleTextInExNotifyGuid,\r
@@ -457,7 +457,7 @@ TerminalConInRegisterKeyNotify (
                   NULL\r
                   );\r
   ASSERT_EFI_ERROR (Status);\r
-  *NotifyHandle                = NewNotify->NotifyHandle;  \r
+  *NotifyHandle                = NewNotify->NotifyHandle;\r
 \r
   return EFI_SUCCESS;\r
 }\r
@@ -474,15 +474,15 @@ TerminalConInUnregisterKeyNotify (
     Remove a registered notification function from a particular keystroke.\r
 \r
   Arguments:\r
-    This                    - Protocol instance pointer.    \r
+    This                    - Protocol instance pointer.\r
     NotificationHandle      - The handle of the notification function being unregistered.\r
 \r
   Returns:\r
     EFI_SUCCESS             - The notification function was unregistered successfully.\r
     EFI_INVALID_PARAMETER   - The NotificationHandle is invalid.\r
-    EFI_NOT_FOUND           - Can not find the matching entry in database.  \r
-                              \r
---*/   \r
+    EFI_NOT_FOUND           - Can not find the matching entry in database.\r
+\r
+--*/\r
 {\r
   EFI_STATUS                      Status;\r
   TERMINAL_DEV                    *TerminalDevice;\r
@@ -491,8 +491,8 @@ TerminalConInUnregisterKeyNotify (
 \r
   if (NotificationHandle == NULL) {\r
     return EFI_INVALID_PARAMETER;\r
-  } \r
-  \r
+  }\r
+\r
   Status = gBS->OpenProtocol (\r
                   NotificationHandle,\r
                   &gSimpleTextInExNotifyGuid,\r
@@ -509,16 +509,16 @@ TerminalConInUnregisterKeyNotify (
 \r
   for (Link = TerminalDevice->NotifyList.ForwardLink; Link != &TerminalDevice->NotifyList; Link = Link->ForwardLink) {\r
     CurrentNotify = CR (\r
-                      Link, \r
-                      TERMINAL_CONSOLE_IN_EX_NOTIFY, \r
-                      NotifyEntry, \r
+                      Link,\r
+                      TERMINAL_CONSOLE_IN_EX_NOTIFY,\r
+                      NotifyEntry,\r
                       TERMINAL_CONSOLE_IN_EX_NOTIFY_SIGNATURE\r
                       );\r
     if (CurrentNotify->NotifyHandle == NotificationHandle) {\r
       //\r
       // Remove the notification function from NotifyList and free resources\r
       //\r
-      RemoveEntryList (&CurrentNotify->NotifyEntry);      \r
+      RemoveEntryList (&CurrentNotify->NotifyEntry);\r
       Status = gBS->UninstallMultipleProtocolInterfaces (\r
                       CurrentNotify->NotifyHandle,\r
                       &gSimpleTextInExNotifyGuid,\r
@@ -526,12 +526,12 @@ TerminalConInUnregisterKeyNotify (
                       NULL\r
                       );\r
       ASSERT_EFI_ERROR (Status);\r
-      gBS->FreePool (CurrentNotify);            \r
+      gBS->FreePool (CurrentNotify);\r
       return EFI_SUCCESS;\r
     }\r
   }\r
-  \r
-  return EFI_NOT_FOUND;  \r
+\r
+  return EFI_NOT_FOUND;\r
 }\r
 \r
 \r
@@ -541,7 +541,7 @@ TranslateRawDataToEfiKey (
   )\r
 /*++\r
     Step1: Turn raw data into Unicode (according to different encode).\r
-    Step2: Translate Unicode into key information. \r
+    Step2: Translate Unicode into key information.\r
     (according to different terminal standard).\r
 --*/\r
 {\r
@@ -579,20 +579,20 @@ TerminalConInWaitForKey (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Event notification function for EFI_SIMPLE_TEXT_INPUT_PROTOCOL.WaitForKey event\r
-    Signal the event if there is key available     \r
-  \r
+    Signal the event if there is key available\r
+\r
   Arguments:\r
-  \r
+\r
     Event - Indicates the event that invoke this function.\r
-    \r
+\r
     Context - Indicates the calling context.\r
-        \r
+\r
   Returns:\r
-  \r
+\r
     N/A\r
-                \r
+\r
 --*/\r
 {\r
   //\r
@@ -613,23 +613,23 @@ TerminalConInCheckForKey (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Check for a pending key in the Efi Key FIFO or Serial device buffer.\r
-  \r
+\r
   Arguments:\r
-  \r
+\r
     This - Indicates the calling context.\r
-        \r
+\r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
-       There is key pending.   \r
-    \r
+       There is key pending.\r
+\r
     EFI_NOT_READY\r
       There is no key pending.\r
-      \r
+\r
     EFI_DEVICE_ERROR\r
-                \r
+\r
 --*/\r
 {\r
   EFI_STATUS              Status;\r
@@ -741,7 +741,7 @@ GetOneKeyFromSerial (
     Get one key out of serial buffer.\r
     If serial buffer is empty, return EFI_NOT_READY;\r
     if reading serial buffer encounter error, returns EFI_DEVICE_ERROR;\r
-    if reading serial buffer successfully, put the fetched key to \r
+    if reading serial buffer successfully, put the fetched key to\r
     the parameter "Input", and return EFI_SUCCESS.\r
 --*/\r
 {\r
@@ -1130,33 +1130,33 @@ UnicodeToEfiKey (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Converts a stream of Unicode characters from a terminal input device into EFI Keys that\r
     can be read through the Simple Input Protocol.  The table below shows the keyboard\r
-    input mappings that this function supports.  If the ESC sequence listed in one of the \r
+    input mappings that this function supports.  If the ESC sequence listed in one of the\r
     columns is presented, then it is translated into the coorespoding EFI Scan Code.  If a\r
     matching sequence is not found, then the raw key strokes are converted into EFI Keys.\r
-    \r
-    2 seconds are allowed for an ESC sequence to be completed.  If the ESC sequence is not \r
-    completed in 2 seconds, then the raw key strokes of the partial ESC sequence are \r
+\r
+    2 seconds are allowed for an ESC sequence to be completed.  If the ESC sequence is not\r
+    completed in 2 seconds, then the raw key strokes of the partial ESC sequence are\r
     converted into EFI Keys.\r
-    \r
-    There is one special input sequence that will force the system to reset.  \r
+\r
+    There is one special input sequence that will force the system to reset.\r
     This is ESC R ESC r ESC R.\r
-  \r
+\r
   Arguments:\r
 \r
     TerminaDevice : The terminal device to use to translate raw input into EFI Keys\r
-        \r
+\r
   Returns:\r
 \r
     None\r
 \r
 Symbols used in table below\r
 ===========================\r
-  ESC = 0x1B  \r
-  CSI = 0x9B  \r
-  DEL = 0x7f  \r
+  ESC = 0x1B\r
+  CSI = 0x9B\r
+  DEL = 0x7f\r
   ^   = CTRL\r
 \r
 +=========+======+===========+==========+==========+\r
@@ -1167,7 +1167,7 @@ Symbols used in table below
 | NULL    | 0x00 |           |          |          |\r
 | UP      | 0x01 | ESC [ A   | ESC [ A  | ESC [ A  |\r
 | DOWN    | 0x02 | ESC [ B   | ESC [ B  | ESC [ B  |\r
-| RIGHT   | 0x03 | ESC [ C   | ESC [ C  | ESC [ C  | \r
+| RIGHT   | 0x03 | ESC [ C   | ESC [ C  | ESC [ C  |\r
 | LEFT    | 0x04 | ESC [ D   | ESC [ D  | ESC [ D  |\r
 | HOME    | 0x05 | ESC [ H   | ESC h    | ESC [ H  |\r
 | END     | 0x06 | ESC [ F   | ESC k    | ESC [ K  |\r
@@ -1204,7 +1204,7 @@ ESC R ESC r ESC R = Reset System
   UINT16              UnicodeChar;\r
   EFI_INPUT_KEY       Key;\r
   BOOLEAN             SetDefaultResetState;\r
-  \r
+\r
   TimerStatus = gBS->CheckEvent (TerminalDevice->TwoSecondTimeOut);\r
 \r
   if (!EFI_ERROR (TimerStatus)) {\r
@@ -1213,7 +1213,7 @@ ESC R ESC r ESC R = Reset System
   }\r
 \r
   while (!IsUnicodeFiFoEmpty(TerminalDevice)) {\r
-    \r
+\r
     if (TerminalDevice->InputState != INPUT_STATE_DEFAULT) {\r
       //\r
       // Check to see if the 2 second timer has expired\r
@@ -1252,71 +1252,71 @@ ESC R ESC r ESC R = Reset System
       }\r
 \r
       Key.ScanCode = SCAN_NULL;\r
-      \r
-      if (TerminalDevice->TerminalType == VT100PlusType || \r
+\r
+      if (TerminalDevice->TerminalType == VT100PlusType ||\r
           TerminalDevice->TerminalType == VTUTF8Type) {\r
         switch (UnicodeChar) {\r
-        case '1': \r
-          Key.ScanCode = SCAN_F1;         \r
+        case '1':\r
+          Key.ScanCode = SCAN_F1;\r
           break;\r
-        case '2': \r
-          Key.ScanCode = SCAN_F2;         \r
+        case '2':\r
+          Key.ScanCode = SCAN_F2;\r
           break;\r
-        case '3': \r
-          Key.ScanCode = SCAN_F3;         \r
+        case '3':\r
+          Key.ScanCode = SCAN_F3;\r
           break;\r
-        case '4': \r
-          Key.ScanCode = SCAN_F4;         \r
+        case '4':\r
+          Key.ScanCode = SCAN_F4;\r
           break;\r
-        case '5': \r
-          Key.ScanCode = SCAN_F5;         \r
+        case '5':\r
+          Key.ScanCode = SCAN_F5;\r
           break;\r
-        case '6': \r
-          Key.ScanCode = SCAN_F6;         \r
+        case '6':\r
+          Key.ScanCode = SCAN_F6;\r
           break;\r
-        case '7': \r
-          Key.ScanCode = SCAN_F7;         \r
+        case '7':\r
+          Key.ScanCode = SCAN_F7;\r
           break;\r
-        case '8': \r
-          Key.ScanCode = SCAN_F8;         \r
+        case '8':\r
+          Key.ScanCode = SCAN_F8;\r
           break;\r
-        case '9': \r
-          Key.ScanCode = SCAN_F9;         \r
+        case '9':\r
+          Key.ScanCode = SCAN_F9;\r
           break;\r
-        case '0': \r
-          Key.ScanCode = SCAN_F10;        \r
+        case '0':\r
+          Key.ScanCode = SCAN_F10;\r
           break;\r
         case '!':\r
           Key.ScanCode = SCAN_F11;\r
           break;\r
         case '@':\r
           Key.ScanCode = SCAN_F12;\r
-          break;          \r
-        case 'h': \r
-          Key.ScanCode = SCAN_HOME;       \r
           break;\r
-        case 'k': \r
-          Key.ScanCode = SCAN_END;        \r
+        case 'h':\r
+          Key.ScanCode = SCAN_HOME;\r
           break;\r
-        case '+': \r
-          Key.ScanCode = SCAN_INSERT;     \r
+        case 'k':\r
+          Key.ScanCode = SCAN_END;\r
           break;\r
-        case '-': \r
-          Key.ScanCode = SCAN_DELETE;     \r
+        case '+':\r
+          Key.ScanCode = SCAN_INSERT;\r
           break;\r
-        case '/': \r
-          Key.ScanCode = SCAN_PAGE_DOWN;  \r
+        case '-':\r
+          Key.ScanCode = SCAN_DELETE;\r
           break;\r
-        case '?': \r
-          Key.ScanCode = SCAN_PAGE_UP;    \r
-          break;        \r
-        default :                                 \r
+        case '/':\r
+          Key.ScanCode = SCAN_PAGE_DOWN;\r
+          break;\r
+        case '?':\r
+          Key.ScanCode = SCAN_PAGE_UP;\r
+          break;\r
+        default :\r
           break;\r
         }\r
       }\r
-      \r
+\r
       switch (UnicodeChar) {\r
-      case 'R': \r
+      case 'R':\r
         if (TerminalDevice->ResetState == RESET_STATE_DEFAULT) {\r
           TerminalDevice->ResetState = RESET_STATE_ESC_R;\r
           SetDefaultResetState = FALSE;\r
@@ -1325,14 +1325,14 @@ ESC R ESC r ESC R = Reset System
         }\r
         Key.ScanCode = SCAN_NULL;\r
         break;\r
-      case 'r': \r
+      case 'r':\r
         if (TerminalDevice->ResetState == RESET_STATE_ESC_R) {\r
           TerminalDevice->ResetState = RESET_STATE_ESC_R_ESC_r;\r
           SetDefaultResetState = FALSE;\r
         }\r
         Key.ScanCode = SCAN_NULL;\r
         break;\r
-      default : \r
+      default :\r
         break;\r
       }\r
 \r
@@ -1357,40 +1357,40 @@ ESC R ESC r ESC R = Reset System
       TerminalDevice->ResetState = RESET_STATE_DEFAULT;\r
 \r
       Key.ScanCode = SCAN_NULL;\r
-      \r
+\r
       if (TerminalDevice->TerminalType == VT100Type) {\r
         switch (UnicodeChar) {\r
-        case 'P': \r
-          Key.ScanCode = SCAN_F1;         \r
+        case 'P':\r
+          Key.ScanCode = SCAN_F1;\r
           break;\r
-        case 'Q': \r
-          Key.ScanCode = SCAN_F2;         \r
+        case 'Q':\r
+          Key.ScanCode = SCAN_F2;\r
           break;\r
-        case 'w': \r
-          Key.ScanCode = SCAN_F3;         \r
+        case 'w':\r
+          Key.ScanCode = SCAN_F3;\r
           break;\r
-        case 'x': \r
-          Key.ScanCode = SCAN_F4;         \r
+        case 'x':\r
+          Key.ScanCode = SCAN_F4;\r
           break;\r
-        case 't': \r
-          Key.ScanCode = SCAN_F5;         \r
+        case 't':\r
+          Key.ScanCode = SCAN_F5;\r
           break;\r
-        case 'u': \r
-          Key.ScanCode = SCAN_F6;         \r
+        case 'u':\r
+          Key.ScanCode = SCAN_F6;\r
           break;\r
-        case 'q': \r
-          Key.ScanCode = SCAN_F7;         \r
+        case 'q':\r
+          Key.ScanCode = SCAN_F7;\r
           break;\r
-        case 'r': \r
-          Key.ScanCode = SCAN_F8;         \r
+        case 'r':\r
+          Key.ScanCode = SCAN_F8;\r
           break;\r
-        case 'p': \r
-          Key.ScanCode = SCAN_F9;         \r
+        case 'p':\r
+          Key.ScanCode = SCAN_F9;\r
           break;\r
-        case 'M': \r
-          Key.ScanCode = SCAN_F10;        \r
+        case 'M':\r
+          Key.ScanCode = SCAN_F10;\r
           break;\r
-        default :                                 \r
+        default :\r
           break;\r
         }\r
       }\r
@@ -1408,127 +1408,127 @@ ESC R ESC r ESC R = Reset System
       break;\r
 \r
     case INPUT_STATE_ESC | INPUT_STATE_LEFTOPENBRACKET:\r
-    \r
+\r
       TerminalDevice->ResetState = RESET_STATE_DEFAULT;\r
-      \r
+\r
       Key.ScanCode = SCAN_NULL;\r
-      \r
+\r
       if (TerminalDevice->TerminalType == PcAnsiType    ||\r
           TerminalDevice->TerminalType == VT100Type     ||\r
-          TerminalDevice->TerminalType == VT100PlusType || \r
+          TerminalDevice->TerminalType == VT100PlusType ||\r
           TerminalDevice->TerminalType == VTUTF8Type) {\r
         switch (UnicodeChar) {\r
-        case 'A': \r
-          Key.ScanCode = SCAN_UP;         \r
+        case 'A':\r
+          Key.ScanCode = SCAN_UP;\r
           break;\r
-        case 'B': \r
-          Key.ScanCode = SCAN_DOWN;       \r
+        case 'B':\r
+          Key.ScanCode = SCAN_DOWN;\r
           break;\r
-        case 'C': \r
-          Key.ScanCode = SCAN_RIGHT;      \r
+        case 'C':\r
+          Key.ScanCode = SCAN_RIGHT;\r
           break;\r
-        case 'D': \r
-          Key.ScanCode = SCAN_LEFT;       \r
+        case 'D':\r
+          Key.ScanCode = SCAN_LEFT;\r
           break;\r
-        case 'H': \r
+        case 'H':\r
           if (TerminalDevice->TerminalType == PcAnsiType ||\r
               TerminalDevice->TerminalType == VT100Type) {\r
-            Key.ScanCode = SCAN_HOME;       \r
+            Key.ScanCode = SCAN_HOME;\r
           }\r
           break;\r
-        case 'F': \r
+        case 'F':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_END;\r
           }\r
           break;\r
-        case 'K': \r
+        case 'K':\r
           if (TerminalDevice->TerminalType == VT100Type) {\r
-            Key.ScanCode = SCAN_END;        \r
+            Key.ScanCode = SCAN_END;\r
           }\r
           break;\r
-        case 'L':   \r
-        case '@': \r
+        case 'L':\r
+        case '@':\r
           if (TerminalDevice->TerminalType == PcAnsiType ||\r
               TerminalDevice->TerminalType == VT100Type) {\r
-            Key.ScanCode = SCAN_INSERT;     \r
+            Key.ScanCode = SCAN_INSERT;\r
           }\r
           break;\r
-        case 'X': \r
+        case 'X':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_DELETE;\r
           }\r
           break;\r
-        case 'P': \r
+        case 'P':\r
           if (TerminalDevice->TerminalType == VT100Type) {\r
-            Key.ScanCode = SCAN_DELETE;        \r
+            Key.ScanCode = SCAN_DELETE;\r
           } else if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_F4;\r
           }\r
           break;\r
-        case 'I': \r
+        case 'I':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_PAGE_UP;\r
           }\r
-          break;        \r
-        case 'V': \r
+          break;\r
+        case 'V':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_F10;\r
-          }  \r
-        case '?': \r
+          }\r
+        case '?':\r
           if (TerminalDevice->TerminalType == VT100Type) {\r
-            Key.ScanCode = SCAN_PAGE_UP;        \r
+            Key.ScanCode = SCAN_PAGE_UP;\r
           }\r
           break;\r
-        case 'G': \r
+        case 'G':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_PAGE_DOWN;\r
           }\r
-          break;        \r
-        case 'U': \r
+          break;\r
+        case 'U':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_F9;\r
           }\r
-        case '/': \r
+        case '/':\r
           if (TerminalDevice->TerminalType == VT100Type) {\r
-            Key.ScanCode = SCAN_PAGE_DOWN;        \r
+            Key.ScanCode = SCAN_PAGE_DOWN;\r
           }\r
           break;\r
-        case 'M': \r
+        case 'M':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_F1;\r
           }\r
-          break;        \r
-        case 'N': \r
+          break;\r
+        case 'N':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_F2;\r
           }\r
-          break;        \r
-        case 'O': \r
+          break;\r
+        case 'O':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_F3;\r
           }\r
-          break;        \r
-        case 'Q': \r
+          break;\r
+        case 'Q':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_F5;\r
           }\r
-          break;        \r
-        case 'R': \r
+          break;\r
+        case 'R':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_F6;\r
           }\r
-          break;        \r
-        case 'S': \r
+          break;\r
+        case 'S':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_F7;\r
           }\r
-          break;        \r
-        case 'T': \r
+          break;\r
+        case 'T':\r
           if (TerminalDevice->TerminalType == PcAnsiType) {\r
             Key.ScanCode = SCAN_F8;\r
           }\r
-          break;        \r
-        default : \r
+          break;\r
+        default :\r
           break;\r
         }\r
       }\r
@@ -1545,7 +1545,7 @@ ESC R ESC r ESC R = Reset System
 \r
       break;\r
 \r
-    \r
+\r
     default:\r
       //\r
       // Invalid state. This should never happen.\r
@@ -1564,7 +1564,7 @@ ESC R ESC r ESC R = Reset System
     if (UnicodeChar == CSI) {\r
       TerminalDevice->InputState = INPUT_STATE_CSI;\r
     }\r
-    \r
+\r
     if (TerminalDevice->InputState != INPUT_STATE_DEFAULT) {\r
       Status = gBS->SetTimer(\r
                       TerminalDevice->TwoSecondTimeOut,\r
index 2be62ffa951fba3064195d29495120c2ba7b157e..65fbfc1ef47f7ce9b9bb1ec11e36eb85e5ce3cc6 100644 (file)
@@ -1,23 +1,16 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
+/** @file\r
+  Implementation for EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL protocol.\r
 \r
-Module Name:\r
+Copyright (c) 2006 - 2008, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-    TerminalConOut.c\r
-    \r
-Abstract: \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
 \r
-Revision History\r
---*/\r
+**/\r
 \r
 #include "Terminal.h"\r
 \r
@@ -28,7 +21,7 @@ Revision History
 //\r
 //\r
 STATIC UNICODE_TO_CHAR  UnicodeToPcAnsiOrAscii[] = {\r
-  { BOXDRAW_HORIZONTAL,                 0xc4, L'-' }, \r
+  { BOXDRAW_HORIZONTAL,                 0xc4, L'-' },\r
   { BOXDRAW_VERTICAL,                   0xb3, L'|' },\r
   { BOXDRAW_DOWN_RIGHT,                 0xda, L'/' },\r
   { BOXDRAW_DOWN_LEFT,                  0xbf, L'\\' },\r
@@ -101,27 +94,27 @@ TerminalConOutReset (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.Reset().\r
     If ExtendeVerification is TRUE, then perform dependent serial device reset,\r
     and set display mode to mode 0.\r
     If ExtendedVerification is FALSE, only set display mode to mode 0.\r
-  \r
+\r
   Arguments:\r
-  \r
+\r
     This - Indicates the calling context.\r
-    \r
+\r
     ExtendedVerification - Indicates that the driver may perform a more exhaustive\r
                            verification operation of the device during reset.\r
-        \r
+\r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
-       The reset operation succeeds.   \r
-    \r
+       The reset operation succeeds.\r
+\r
     EFI_DEVICE_ERROR\r
       The terminal is not functioning correctly or the serial port reset fails.\r
-                \r
+\r
 --*/\r
 {\r
   EFI_STATUS    Status;\r
@@ -172,33 +165,33 @@ TerminalConOutOutputString (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.OutputString().\r
     The Unicode string will be converted to terminal expressible data stream\r
     and send to terminal via serial port.\r
-    \r
-  \r
+\r
+\r
   Arguments:\r
-  \r
+\r
     This - Indicates the calling context.\r
-    \r
-    WString - The Null-terminated Unicode string to be displayed on \r
+\r
+    WString - The Null-terminated Unicode string to be displayed on\r
               the terminal screen.\r
-        \r
+\r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
-       The string is output successfully.   \r
-    \r
+       The string is output successfully.\r
+\r
     EFI_DEVICE_ERROR\r
       The serial port fails to send the string out.\r
-      \r
+\r
     EFI_WARN_UNKNOWN_GLYPH\r
-      Indicates that some of the characters in the Unicode string could not \r
-      be rendered and are skipped.          \r
-      \r
+      Indicates that some of the characters in the Unicode string could not\r
+      be rendered and are skipped.\r
+\r
     EFI_UNSUPPORTED\r
-                \r
+\r
 --*/\r
 {\r
   TERMINAL_DEV                *TerminalDevice;\r
@@ -229,7 +222,7 @@ TerminalConOutOutputString (
   //  Get current display mode\r
   //\r
   Mode = This->Mode;\r
-  \r
+\r
   if (Mode->Mode > 2) {\r
     return EFI_UNSUPPORTED;\r
   }\r
@@ -368,28 +361,28 @@ TerminalConOutTestString (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.TestString().\r
     If one of the characters in the *Wstring is\r
     neither valid Unicode drawing characters,\r
     not ASCII code, then this function will return\r
     EFI_UNSUPPORTED.\r
-        \r
-  \r
+\r
+\r
   Arguments:\r
-  \r
+\r
     This - Indicates the calling context.\r
-    \r
+\r
     WString - The Null-terminated Unicode string to be tested.\r
-        \r
+\r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
-       The terminal is capable of rendering the output string. \r
-    \r
+       The terminal is capable of rendering the output string.\r
+\r
     EFI_UNSUPPORTED\r
-      Some of the characters in the Unicode string cannot be rendered.      \r
-                \r
+      Some of the characters in the Unicode string cannot be rendered.\r
+\r
 --*/\r
 {\r
   TERMINAL_DEV  *TerminalDevice;\r
@@ -430,38 +423,38 @@ TerminalConOutQueryMode (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Implements EFI_SIMPLE_TEXT_OUT_PROTOCOL.QueryMode().\r
     It returns information for an available text mode\r
     that the terminal supports.\r
     In this driver, we support text mode 80x25 (mode 0),\r
     80x50 (mode 1), 100x31 (mode 2).\r
-        \r
-  \r
+\r
+\r
   Arguments:\r
-  \r
+\r
     *This\r
         Indicates the calling context.\r
-    \r
+\r
     ModeNumber\r
         The mode number to return information on.\r
-        \r
+\r
     Columns\r
         The returned columns of the requested mode.\r
-        \r
+\r
     Rows\r
-        The returned rows of the requested mode.                \r
-        \r
+        The returned rows of the requested mode.\r
+\r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
-      The requested mode information is returned. \r
-    \r
+      The requested mode information is returned.\r
+\r
     EFI_UNSUPPORTED\r
-      The mode number is not valid.   \r
-      \r
+      The mode number is not valid.\r
+\r
     EFI_DEVICE_ERROR\r
-                \r
+\r
 --*/\r
 {\r
   if (This->Mode->MaxMode > 3) {\r
@@ -472,7 +465,7 @@ TerminalConOutQueryMode (
     *Columns  = MODE0_COLUMN_COUNT;\r
     *Rows     = MODE0_ROW_COUNT;\r
     return EFI_SUCCESS;\r
-  } else if (ModeNumber == 1) {  \r
+  } else if (ModeNumber == 1) {\r
     *Columns  = MODE1_COLUMN_COUNT;\r
     *Rows     = MODE1_ROW_COUNT;\r
     return EFI_SUCCESS;\r
@@ -493,30 +486,30 @@ TerminalConOutSetMode (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Implements EFI_SIMPLE_TEXT_OUT.SetMode().\r
     Set the terminal to a specified display mode.\r
-    In this driver, we only support mode 0.        \r
-  \r
+    In this driver, we only support mode 0.\r
+\r
   Arguments:\r
-  \r
+\r
     This\r
         Indicates the calling context.\r
-    \r
+\r
     ModeNumber\r
         The text mode to set.\r
-        \r
+\r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
        The requested text mode is set.\r
-       \r
+\r
     EFI_DEVICE_ERROR\r
       The requested text mode cannot be set because of serial device error.\r
-    \r
+\r
     EFI_UNSUPPORTED\r
-      The text mode number is not valid.       \r
-                \r
+      The text mode number is not valid.\r
+\r
 --*/\r
 {\r
   EFI_STATUS    Status;\r
@@ -530,7 +523,7 @@ TerminalConOutSetMode (
   if (ModeNumber > 2) {\r
     return EFI_UNSUPPORTED;\r
   }\r
-  \r
+\r
   //\r
   // Set the current mode\r
   //\r
@@ -565,29 +558,29 @@ TerminalConOutSetAttribute (
   )\r
 /*++\r
   Routine Description:\r
-  \r
-    Implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetAttribute().       \r
-  \r
+\r
+    Implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetAttribute().\r
+\r
   Arguments:\r
-  \r
+\r
     This\r
         Indicates the calling context.\r
-    \r
+\r
     Attribute\r
         The attribute to set. Only bit0..6 are valid, all other bits\r
         are undefined and must be zero.\r
-        \r
+\r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
-      The requested attribute is set. \r
-       \r
+      The requested attribute is set.\r
+\r
     EFI_DEVICE_ERROR\r
       The requested attribute cannot be set due to serial port error.\r
-          \r
+\r
     EFI_UNSUPPORTED\r
-      The attribute requested is not defined by EFI spec.   \r
-                \r
+      The attribute requested is not defined by EFI spec.\r
+\r
 --*/\r
 {\r
   UINT8         ForegroundControl;\r
@@ -741,28 +734,28 @@ TerminalConOutClearScreen (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.ClearScreen().\r
-    It clears the ANSI terminal's display to the \r
+    It clears the ANSI terminal's display to the\r
     currently selected background color.\r
-        \r
-  \r
+\r
+\r
   Arguments:\r
-  \r
+\r
     This\r
         Indicates the calling context.\r
 \r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
       The operation completed successfully.\r
-       \r
+\r
     EFI_DEVICE_ERROR\r
-      The terminal screen cannot be cleared due to serial port error.        \r
-    \r
+      The terminal screen cannot be cleared due to serial port error.\r
+\r
     EFI_UNSUPPORTED\r
-      The terminal is not in a valid display mode.       \r
-                \r
+      The terminal is not in a valid display mode.\r
+\r
 --*/\r
 {\r
   EFI_STATUS    Status;\r
@@ -795,32 +788,32 @@ TerminalConOutSetCursorPosition (
   )\r
 /*++\r
   Routine Description:\r
-  \r
-    Implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetCursorPosition().          \r
-  \r
+\r
+    Implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetCursorPosition().\r
+\r
   Arguments:\r
-  \r
+\r
     This\r
         Indicates the calling context.\r
-        \r
+\r
     Column\r
         The row to set cursor to.\r
-        \r
+\r
     Row\r
-        The column to set cursor to.                \r
+        The column to set cursor to.\r
 \r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
       The operation completed successfully.\r
-       \r
+\r
     EFI_DEVICE_ERROR\r
-      The request fails due to serial port error.        \r
-    \r
+      The request fails due to serial port error.\r
+\r
     EFI_UNSUPPORTED\r
       The terminal is not in a valid text mode, or the cursor position\r
-      is invalid for current mode.     \r
-                \r
+      is invalid for current mode.\r
+\r
 --*/\r
 {\r
   EFI_SIMPLE_TEXT_OUTPUT_MODE *Mode;\r
@@ -885,27 +878,27 @@ TerminalConOutEnableCursor (
   )\r
 /*++\r
   Routine Description:\r
-  \r
+\r
     Implements SIMPLE_TEXT_OUTPUT.EnableCursor().\r
-    In this driver, the cursor cannot be hidden.        \r
-  \r
+    In this driver, the cursor cannot be hidden.\r
+\r
   Arguments:\r
-  \r
+\r
     This\r
         Indicates the calling context.\r
-        \r
+\r
     Visible\r
         If TRUE, the cursor is set to be visible,\r
-        If FALSE, the cursor is set to be invisible.        \r
+        If FALSE, the cursor is set to be invisible.\r
 \r
   Returns:\r
-  \r
+\r
     EFI_SUCCESS\r
       The request is valid.\r
-       \r
+\r
     EFI_UNSUPPORTED\r
-      The terminal does not support cursor hidden.   \r
-                \r
+      The terminal does not support cursor hidden.\r
+\r
 --*/\r
 {\r
   if (!Visible) {\r
index babc4bbedc8245466cfff79f6b0f714c4bb38679..813779e0d1696ff78178bc1fce10aed7ee0a9158 100644 (file)
@@ -1,23 +1,16 @@
-/*++\r
+/** @file\r
+  Provides misc functions upon ansi.\r
 \r
-Copyright (c) 2006, 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
-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, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Module Name:\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
 \r
-    ansi.c\r
-    \r
-Abstract: \r
-    \r
-\r
-Revision History\r
---*/\r
+**/\r
 \r
 \r
 #include "Terminal.h"\r
@@ -56,7 +49,7 @@ AnsiTestString (
   //\r
   for (; *WString != CHAR_NULL; WString++) {\r
 \r
-    if ( !(TerminalIsValidAscii (*WString) || \r
+    if ( !(TerminalIsValidAscii (*WString) ||\r
         TerminalIsValidEfiCntlChar (*WString) ||\r
         TerminalIsValidTextGraphics (*WString, &GraphicChar, NULL) )) {\r
 \r
index 648344a279c911c9b4669583eff5b376db19b64c..286c937d42bd7f372722fb19da9bcbf90c411e1f 100644 (file)
@@ -1,23 +1,16 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
-\r
-    vtutf8.c\r
-    \r
-Abstract: \r
-    \r
-\r
-Revision History\r
---*/\r
+/**@file\r
+  Implementation translation among different code tyies.\r
+\r
+Copyright (c) 2006, Intel Corporation. <BR>\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
+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
+\r
+**/\r
 \r
 #include "Terminal.h"\r
 \r
index 321f57bf42922df021e078291494e06f65b6a87a..ae0233596f95efe7b3237ca37b6679434a84dcf1 100644 (file)
@@ -1,21 +1,16 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
-  ComponentName.c\r
-\r
-Abstract:\r
-  Component name protocol member functions for DebugPort...\r
-  \r
---*/\r
+/** @file\r
+  UEFI Component Name(2) protocol implementation for DebugPort driver.\r
+\r
+Copyright (c) 2006 - 2008, Intel Corporation. <BR>\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
+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
+\r
+**/\r
 \r
 #include "DebugPort.h"\r
 \r
index e3e47302a3086df2d1e336a2fe55e179d991854a..914a8c703c4be2427fbad26296a09bbff150a3be 100644 (file)
@@ -1,29 +1,19 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
+/** @file\r
+  Top level C file for debugport driver.  Contains initialization function.\r
+  This driver layers on top of SerialIo.\r
+  ALL CODE IN THE SERIALIO STACK MUST BE RE-ENTRANT AND CALLABLE FROM\r
+  INTERRUPT CONTEXT\r
 \r
-    DebugPort.c\r
+Copyright (c) 2006 - 2008, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Abstract:\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
 \r
-    Top level C file for debugport driver.  Contains initialization function.\r
-    This driver layers on top of SerialIo.\r
-    \r
-    ALL CODE IN THE SERIALIO STACK MUST BE RE-ENTRANT AND CALLABLE FROM\r
-    INTERRUPT CONTEXT.\r
-\r
-Revision History\r
-\r
---*/\r
+**/\r
 \r
 \r
 #include "DebugPort.h"\r
@@ -41,7 +31,7 @@ GetDebugPortVariable (
 Routine Description:\r
   Local worker function to obtain device path information from DebugPort variable.\r
   Records requested settings in DebugPort device structure.\r
-  \r
+\r
 Arguments:\r
   DEBUGPORT_DEVICE  *DebugPortDevice,\r
 \r
@@ -145,8 +135,8 @@ InitializeDebugPortDriver (
 Routine Description:\r
   Driver entry point.  Reads DebugPort variable to determine what device and settings\r
   to use as the debug port.  Binds exclusively to SerialIo. Reverts to defaults \\r
-  if no variable is found.  \r
-  \r
+  if no variable is found.\r
+\r
   Creates debugport and devicepath protocols on new handle.\r
 \r
 Arguments:\r
@@ -215,13 +205,13 @@ DebugPortSupported (
 Routine Description:\r
   Checks to see that there's not already a DebugPort interface somewhere.  If so,\r
   fail.\r
-  \r
+\r
   If there's a DEBUGPORT variable, the device path must match exactly.  If there's\r
   no DEBUGPORT variable, then device path is not checked and does not matter.\r
-  \r
+\r
   Checks to see that there's a serial io interface on the controller handle\r
   that can be bound BY_DRIVER | EXCLUSIVE.\r
-  \r
+\r
   If all these tests succeed, then we return EFI_SUCCESS, else, EFI_UNSUPPORTED\r
   or other error returned by OpenProtocol.\r
 \r
@@ -229,12 +219,12 @@ Arguments:
   This\r
   ControllerHandle\r
   RemainingDevicePath\r
-  \r
+\r
 Returns:\r
   EFI_UNSUPPORTED\r
   EFI_OUT_OF_RESOURCES\r
   EFI_SUCCESS\r
-  \r
+\r
 --*/\r
 {\r
   EFI_STATUS                Status;\r
@@ -332,7 +322,7 @@ Arguments:
   This\r
   ControllerHandle\r
   RemainingDevicePath\r
-  \r
+\r
 Returns:\r
   EFI_OUT_OF_RESOURCES\r
   EFI_SUCCESS\r
@@ -501,11 +491,11 @@ Routine Description:
 \r
 Arguments:\r
   Per UEFI 2.0 driver model\r
-  \r
+\r
 Returns:\r
   EFI_UNSUPPORTED\r
   EFI_SUCCESS\r
-  \r
+\r
 --*/\r
 {\r
   EFI_STATUS  Status;\r
@@ -590,9 +580,9 @@ Routine Description:
   We cannot call SerialIo:SetAttributes because it uses pool services, which use\r
   locks, which affect TPL, so it's not interrupt context safe or re-entrant.\r
   SerialIo:Reset() calls SetAttributes, so it can't be used either.\r
-  \r
-  The port itself should be fine since it was set up during initialization.  \r
-  \r
+\r
+  The port itself should be fine since it was set up during initialization.\r
+\r
 Arguments:\r
   This\r
 \r
@@ -626,7 +616,7 @@ DebugPortRead (
 Routine Description:\r
   DebugPort protocol member function.  Calls SerialIo:Read() after setting\r
   if it's different than the last SerialIo access.\r
-  \r
+\r
 Arguments:\r
   IN EFI_DEBUGPORT_PROTOCOL   *This\r
   IN UINT32                   Timeout,\r
@@ -686,11 +676,11 @@ Routine Description:
   DebugPort protocol member function.  Calls SerialIo:Write() Writes 8 bytes at\r
   a time and does a GetControl between 8 byte writes to help insure reads are\r
   interspersed This is poor-man's flow control..\r
-  \r
+\r
 Arguments:\r
   This               - Pointer to DebugPort protocol\r
   Timeout            - Timeout value\r
-  BufferSize         - On input, the size of Buffer. \r
+  BufferSize         - On input, the size of Buffer.\r
                        On output, the amount of data actually written.\r
   Buffer             - Pointer to buffer to write\r
 \r
@@ -741,7 +731,7 @@ DebugPortPoll (
 Routine Description:\r
   DebugPort protocol member function.  Calls SerialIo:Write() after setting\r
   if it's different than the last SerialIo access.\r
-  \r
+\r
 Arguments:\r
   IN EFI_DEBUGPORT_PROTOCOL   *This\r
 \r
@@ -785,7 +775,7 @@ Routine Description:
   Unload function that is registered in the LoadImage protocol.  It un-installs\r
   protocols produced and deallocates pool used by the driver.  Called by the core\r
   when unloading the driver.\r
-  \r
+\r
 Arguments:\r
   EFI_HANDLE ImageHandle\r
 \r
index de2fd4e50bd0d4c3794a89fbdd302f930da751c8..f19de75809519537f2082f477d92881a91e22967 100644 (file)
@@ -1,21 +1,16 @@
-/*++\r
+/** @file\r
+  Definitions and prototypes for DebugPort driver.\r
 \r
-Copyright (c) 2006, 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
-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 - 2008, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Module Name:\r
-  DebugPort.h\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
 \r
-Abstract:\r
-  Definitions and prototypes for DebugPort driver\r
-\r
---*/\r
+**/\r
 \r
 #ifndef __DEBUGPORT_H__\r
 #define __DEBUGPORT_H__\r
index a0ec6c5934bb5a8b4285e6bbcb40339b55899f68..33f2ad12692decbb37b1c59d74d9defe59137ed6 100644 (file)
@@ -1,25 +1,16 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
+/** @file\r
+  Top level C file for debug support driver.  Contains initialization function.\r
 \r
-    DebugSupport.c\r
+Copyright (c) 2006 - 2008, Intel Corporation. <BR>\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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Abstract:\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
 \r
-    Top level C file for debug support driver.  Contains initialization function.\r
-\r
-Revision History\r
-\r
---*/\r
+**/\r
 \r
 //\r
 // private header files\r
index 174e774de3087d81f3be5529346f88093b5ca1a7..d44892e84af3b6be9f0b5d3f74db81fb19830f72 100644 (file)
@@ -1,23 +1,16 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
-\r
-  EbcExecute.c\r
+/** @file\r
+  Contains code that implements the virtual machine.\r
 \r
-Abstract:\r
+Copyright (c) 2006, 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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-  Contains code that implements the virtual machine.\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
 \r
---*/\r
+**/\r
 \r
 #include "EbcInt.h"\r
 #include "EbcExecute.h"\r
@@ -573,31 +566,25 @@ static CONST UINT8                    mJMPLen[] = { 2, 2, 6, 10 };
 //\r
 EFI_GUID mEbcSimpleDebuggerProtocolGuid = EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL_GUID;\r
 \r
-EFI_STATUS\r
-EbcExecuteInstructions (\r
-  IN EFI_EBC_VM_TEST_PROTOCOL *This,\r
-  IN VM_CONTEXT               *VmPtr,\r
-  IN OUT UINTN                *InstructionCount\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
-  \r
+/**\r
   Given a pointer to a new VM context, execute one or more instructions. This\r
   function is only used for test purposes via the EBC VM test protocol.\r
 \r
-Arguments:\r
-\r
-  This              - pointer to protocol interface\r
-  VmPtr             - pointer to a VM context\r
-  InstructionCount  - how many instructions to execute. 0 if don't count.\r
+  @param  This              pointer to protocol interface\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  InstructionCount  how many instructions to execute. 0 if don't count.\r
 \r
-Returns:\r
+  @return EFI_UNSUPPORTED\r
+  @return EFI_SUCCESS\r
 \r
-  EFI_UNSUPPORTED\r
-  EFI_SUCCESS\r
-\r
---*/\r
+**/\r
+EFI_STATUS\r
+EbcExecuteInstructions (\r
+  IN EFI_EBC_VM_TEST_PROTOCOL *This,\r
+  IN VM_CONTEXT               *VmPtr,\r
+  IN OUT UINTN                *InstructionCount\r
+  )\r
 {\r
   UINTN       ExecFunc;\r
   EFI_STATUS  Status;\r
@@ -641,25 +628,19 @@ Returns:
   return Status;\r
 }\r
 \r
-EFI_STATUS\r
-EbcExecute (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
-  \r
+/**\r
   Execute an EBC image from an entry point or from a published protocol.\r
 \r
-Arguments:\r
-\r
-  VmPtr - pointer to prepared VM context.\r
+  @param  VmPtr             pointer to prepared VM context.\r
 \r
-Returns:\r
+  @return Standard EBC status.\r
 \r
-  Standard EBC status.\r
-\r
---*/\r
+**/\r
+EFI_STATUS\r
+EbcExecute (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINTN                             ExecFunc;\r
   UINT8                             StackCorrupted;\r
@@ -770,39 +751,28 @@ Done:
   return Status;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteMOVxx (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
-  \r
+/**\r
   Execute the MOVxx instructions.\r
 \r
-Arguments:\r
-\r
-  VmPtr - pointer to a VM context.\r
-\r
-Returns:\r
+  @param  VmPtr             pointer to a VM context.\r
 \r
-  EFI_UNSUPPORTED\r
-  EFI_SUCCESS\r
+  @return EFI_UNSUPPORTED\r
+  @return EFI_SUCCESS\r
+  @return Instruction format:\r
+  @return MOV[b|w|d|q|n]{w|d} {@}R1 {Index16|32}, {@}R2 {Index16|32}\r
+  @return MOVqq {@}R1 {Index64}, {@}R2 {Index64}\r
+  @return Copies contents of [R2] -> [R1], zero extending where required.\r
+  @return First character indicates the size of the move.\r
+  @return Second character indicates the size of the index(s).\r
+  @return Invalid to have R1 direct with index.\r
 \r
-Instruction format:\r
-  \r
-  MOV[b|w|d|q|n]{w|d} {@}R1 {Index16|32}, {@}R2 {Index16|32}\r
-  MOVqq {@}R1 {Index64}, {@}R2 {Index64}\r
-\r
-  Copies contents of [R2] -> [R1], zero extending where required.\r
-\r
-  First character indicates the size of the move.\r
-  Second character indicates the size of the index(s).\r
-\r
-  Invalid to have R1 direct with index.\r
-  \r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteMOVxx (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8   Opcode;\r
   UINT8   OpcMasked;\r
@@ -1059,27 +1029,21 @@ Instruction format:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteBREAK (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
-  \r
+/**\r
   Execute the EBC BREAK instruction\r
 \r
-Arguments:\r
-\r
-  VmPtr - pointer to current VM context\r
+  @param  VmPtr             pointer to current VM context\r
 \r
-Returns:\r
+  @return EFI_UNSUPPORTED\r
+  @return EFI_SUCCESS\r
 \r
-  EFI_UNSUPPORTED\r
-  EFI_SUCCESS\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteBREAK (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8       Operands;\r
   VOID        *EbcEntryPoint;\r
@@ -1175,39 +1139,30 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
+\r
+/**\r
+  Execute the JMP instruction\r
+\r
+  @param  VmPtr             pointer to VM context\r
+\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return JMP64{cs|cc} Immed64\r
+  @return JMP32{cs|cc} {@}R1 {Immed32|Index32}\r
+  @return Encoding:\r
+  @retval b0.7              immediate data present\r
+  @retval b0.6              1 = 64 bit immediate data 0 = 32 bit immediate data\r
+  @retval b1.7              1 = conditional b1.6    1 = CS (condition set) 0 = CC\r
+                            (condition clear) b1.4    1 = relative address 0 =\r
+                            absolute address b1.3    1 = operand1 indirect b1.2-0\r
+                            operand 1\r
+\r
+**/\r
 STATIC\r
 EFI_STATUS\r
 ExecuteJMP (\r
   IN VM_CONTEXT *VmPtr\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the JMP instruction\r
-\r
-Arguments:\r
-  VmPtr      - pointer to VM context\r
-\r
-Returns:\r
-  Standard EFI_STATUS\r
-\r
-Instruction syntax:\r
-  JMP64{cs|cc} Immed64\r
-  JMP32{cs|cc} {@}R1 {Immed32|Index32}\r
-\r
-Encoding:\r
-  b0.7 -  immediate data present\r
-  b0.6 -  1 = 64 bit immediate data\r
-          0 = 32 bit immediate data\r
-  b1.7 -  1 = conditional\r
-  b1.6    1 = CS (condition set)\r
-          0 = CC (condition clear)\r
-  b1.4    1 = relative address\r
-          0 = absolute address\r
-  b1.3    1 = operand1 indirect\r
-  b1.2-0  operand 1\r
-\r
---*/\r
 {\r
   UINT8   Opcode;\r
   UINT8   CompareSet;\r
@@ -1354,26 +1309,22 @@ Encoding:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteJMP8 (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Execute the EBC JMP8 instruction\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
-\r
-Returns:\r
-  Standard EFI_STATUS\r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Instruction syntax:\r
-  JMP8{cs|cc}  Offset/2\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return JMP8{cs|cc}  Offset/2\r
 \r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteJMP8 (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8 Opcode;\r
   UINT8 ConditionFlag;\r
@@ -1408,38 +1359,27 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC MOVI\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return MOVI[b|w|d|q][w|d|q] {@}R1 {Index16}, ImmData16|32|64\r
+  @return First variable character specifies the move size\r
+  @return Second variable character specifies size of the immediate data\r
+  @return Sign-extend the immediate data to the size of the operation, and zero-extend\r
+  @return if storing to a register.\r
+  @return Operand1 direct with index/immed is invalid.\r
+\r
+**/\r
 STATIC\r
 EFI_STATUS\r
 ExecuteMOVI (\r
   IN VM_CONTEXT *VmPtr\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  \r
-  Execute the EBC MOVI \r
-\r
-Arguments:\r
-\r
-  VmPtr   - pointer to a VM context  \r
-\r
-Returns:\r
-\r
-  Standard EFI_STATUS\r
-\r
-Instruction syntax:\r
-\r
-  MOVI[b|w|d|q][w|d|q] {@}R1 {Index16}, ImmData16|32|64\r
-\r
-  First variable character specifies the move size\r
-  Second variable character specifies size of the immediate data\r
-\r
-  Sign-extend the immediate data to the size of the operation, and zero-extend\r
-  if storing to a register.\r
-\r
-  Operand1 direct with index/immed is invalid.\r
-    \r
---*/\r
 {\r
   UINT8   Opcode;\r
   UINT8   Operands;\r
@@ -1539,31 +1479,23 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteMOVIn (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
-  \r
+/**\r
   Execute the EBC MOV immediate natural. This instruction moves an immediate\r
   index value into a register or memory location.\r
 \r
-Arguments:\r
-\r
-  VmPtr   - pointer to a VM context  \r
-\r
-Returns:\r
-\r
-  Standard EFI_STATUS\r
-\r
-Instruction syntax:\r
+  @param  VmPtr             pointer to a VM context\r
 \r
-  MOVIn[w|d|q] {@}R1 {Index16}, Index16|32|64\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return MOVIn[w|d|q] {@}R1 {Index16}, Index16|32|64\r
 \r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteMOVIn (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8   Opcode;\r
   UINT8   Operands;\r
@@ -1647,31 +1579,23 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteMOVREL (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
-  \r
+/**\r
   Execute the EBC MOVREL instruction.\r
   Dest <- Ip + ImmData\r
 \r
-Arguments:\r
-\r
-  VmPtr   - pointer to a VM context  \r
-\r
-Returns:\r
+  @param  VmPtr             pointer to a VM context\r
 \r
-  Standard EFI_STATUS\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return MOVREL[w|d|q] {@}R1 {Index16}, ImmData16|32|64\r
 \r
-Instruction syntax:\r
-\r
-  MOVREL[w|d|q] {@}R1 {Index16}, ImmData16|32|64\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteMOVREL (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8   Opcode;\r
   UINT8   Operands;\r
@@ -1754,36 +1678,27 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteMOVsnw (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
-  \r
-  Execute the EBC MOVsnw instruction. This instruction loads a signed \r
+/**\r
+  Execute the EBC MOVsnw instruction. This instruction loads a signed\r
   natural value from memory or register to another memory or register. On\r
   32-bit machines, the value gets sign-extended to 64 bits if the destination\r
   is a register.\r
 \r
-Arguments:\r
+  @param  VmPtr             pointer to a VM context\r
 \r
-  VmPtr   - pointer to a VM context  \r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return MOVsnw {@}R1 {Index16}, {@}R2 {Index16|Immed16}\r
+  @return 0:7 1=>operand1 index present\r
+  @return 0:6 1=>operand2 index present\r
 \r
-Returns:\r
-\r
-  Standard EFI_STATUS\r
-\r
-Instruction syntax:\r
-\r
-  MOVsnw {@}R1 {Index16}, {@}R2 {Index16|Immed16}\r
-\r
-  0:7 1=>operand1 index present\r
-  0:6 1=>operand2 index present\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteMOVsnw (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8   Opcode;\r
   UINT8   Operands;\r
@@ -1853,36 +1768,27 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteMOVsnd (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
-  \r
-  Execute the EBC MOVsnw instruction. This instruction loads a signed \r
+/**\r
+  Execute the EBC MOVsnw instruction. This instruction loads a signed\r
   natural value from memory or register to another memory or register. On\r
   32-bit machines, the value gets sign-extended to 64 bits if the destination\r
   is a register.\r
 \r
-Arguments:\r
-\r
-  VmPtr   - pointer to a VM context  \r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Returns:\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return MOVsnd {@}R1 {Indx32}, {@}R2 {Index32|Immed32}\r
+  @return 0:7 1=>operand1 index present\r
+  @return 0:6 1=>operand2 index present\r
 \r
-  Standard EFI_STATUS\r
-\r
-Instruction syntax:\r
-\r
-  MOVsnd {@}R1 {Indx32}, {@}R2 {Index32|Immed32}\r
-\r
-  0:7 1=>operand1 index present\r
-  0:6 1=>operand2 index present\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteMOVsnd (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8   Opcode;\r
   UINT8   Operands;\r
@@ -1952,26 +1858,22 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecutePUSHn (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Execute the EBC PUSHn instruction\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Returns:\r
-  Standard EFI_STATUS\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return PUSHn {@}R1 {Index16|Immed16}\r
 \r
-Instruction syntax:\r
-   PUSHn {@}R1 {Index16|Immed16}\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecutePUSHn (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8 Opcode;\r
   UINT8 Operands;\r
@@ -2015,26 +1917,22 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecutePUSH (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Execute the EBC PUSH instruction\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
-\r
-Returns:\r
-  Standard EFI_STATUS\r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Instruction syntax:\r
-   PUSH[32|64] {@}R1 {Index16|Immed16}\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return PUSH[32|64] {@}R1 {Index16|Immed16}\r
 \r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecutePUSH (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8   Opcode;\r
   UINT8   Operands;\r
@@ -2095,26 +1993,22 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecutePOPn (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Execute the EBC POPn instruction\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Returns:\r
-  Standard EFI_STATUS\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return POPn {@}R1 {Index16|Immed16}\r
 \r
-Instruction syntax:\r
-   POPn {@}R1 {Index16|Immed16}\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecutePOPn (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8 Opcode;\r
   UINT8 Operands;\r
@@ -2158,26 +2052,22 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecutePOP (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Execute the EBC POP instruction\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
-\r
-Returns:\r
-  Standard EFI_STATUS\r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Instruction syntax:\r
-  POP {@}R1 {Index16|Immed16}\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return POP {@}R1 {Index16|Immed16}\r
 \r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecutePOP (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8   Opcode;\r
   UINT8   Operands;\r
@@ -2241,32 +2131,26 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteCALL (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Implements the EBC CALL instruction.\r
-\r
-  Instruction format:  \r
-\r
-    CALL64 Immed64\r
-    CALL32 {@}R1 {Immed32|Index32}\r
-    CALLEX64 Immed64\r
-    CALLEX16 {@}R1 {Immed32}\r
-\r
+  Instruction format:\r
+  CALL64 Immed64\r
+  CALL32 {@}R1 {Immed32|Index32}\r
+  CALLEX64 Immed64\r
+  CALLEX16 {@}R1 {Immed32}\r
   If Rx == R0, then it's a PC relative call to PC = PC + imm32.\r
-  \r
-Arguments:\r
-  VmPtr - pointer to a VM context.\r
 \r
-Returns:\r
-  Standard EFI_STATUS\r
+  @param  VmPtr             pointer to a VM context.\r
+\r
+  @return Standard EFI_STATUS\r
 \r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteCALL (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8 Opcode;\r
   UINT8 Operands;\r
@@ -2384,26 +2268,22 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteRET (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Execute the EBC RET instruction\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Returns:\r
-  Standard EFI_STATUS\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return RET\r
 \r
-Instruction syntax:\r
-   RET\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteRET (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   //\r
   // If we're at the top of the stack, then simply set the done\r
@@ -2435,26 +2315,22 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteCMP (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Execute the EBC CMP instruction\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
-\r
-Returns:\r
-  Standard EFI_STATUS\r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Instruction syntax:\r
-   CMP[32|64][eq|lte|gte|ulte|ugte] R1, {@}R2 {Index16|Immed16}\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return CMP[32|64][eq|lte|gte|ulte|ugte] R1, {@}R2 {Index16|Immed16}\r
 \r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteCMP (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8   Opcode;\r
   UINT8   Operands;\r
@@ -2599,26 +2475,22 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteCMPI (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Execute the EBC CMPI instruction\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Returns:\r
-  Standard EFI_STATUS\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return CMPI[32|64]{w|d}[eq|lte|gte|ulte|ugte] {@}Rx {Index16}, Immed16|Immed32\r
 \r
-Instruction syntax:\r
-   CMPI[32|64]{w|d}[eq|lte|gte|ulte|ugte] {@}Rx {Index16}, Immed16|Immed32\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteCMPI (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8   Opcode;\r
   UINT8   Operands;\r
@@ -2781,6 +2653,19 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC NOT instruction\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return ~Op2\r
+  @return Instruction syntax:\r
+  @return NOT[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteNOT (\r
@@ -2788,27 +2673,23 @@ ExecuteNOT (
   IN UINT64         Op1,\r
   IN UINT64         Op2\r
   )\r
-/*++\r
+{\r
+  return ~Op2;\r
+}\r
 \r
-Routine Description:\r
-  Execute the EBC NOT instruction\r
 \r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
+/**\r
+  Execute the EBC NEG instruction\r
 \r
-Returns:\r
-  ~Op2\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
 \r
-Instruction syntax:\r
-  NOT[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-  \r
---*/\r
-{\r
-  return ~Op2;\r
-}\r
+  @return Op2 * -1\r
+  @return Instruction syntax:\r
+  @return NEG[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
 \r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteNEG (\r
@@ -2816,27 +2697,23 @@ ExecuteNEG (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
+{\r
+  return ~Op2 + 1;\r
+}\r
 \r
-Routine Description:\r
-  Execute the EBC NEG instruction\r
 \r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
+/**\r
+  Execute the EBC ADD instruction\r
 \r
-Returns:\r
-  Op2 * -1\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
 \r
-Instruction syntax:\r
-  NEG[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
-{\r
-  return ~Op2 + 1;\r
-}\r
+  @return Op1 + Op2\r
+  @return Instruction syntax:\r
+  @return ADD[32|64] {@}R1, {@}R2 {Index16}\r
 \r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteADD (\r
@@ -2844,28 +2721,23 @@ ExecuteADD (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
+{\r
+  return Op1 + Op2;\r
+}\r
 \r
-Routine Description:\r
-  \r
-  Execute the EBC ADD instruction\r
 \r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
+/**\r
+  Execute the EBC SUB instruction\r
 \r
-Returns:\r
-  Op1 + Op2\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
 \r
-Instruction syntax:\r
-   ADD[32|64] {@}R1, {@}R2 {Index16}\r
-\r
---*/\r
-{\r
-  return Op1 + Op2;\r
-}\r
+  @retval Op1               Op2 Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return SUB[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
 \r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteSUB (\r
@@ -2873,24 +2745,6 @@ ExecuteSUB (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC SUB instruction\r
-\r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  Op1 - Op2\r
-  Standard EFI_STATUS\r
-\r
-Instruction syntax:\r
-  SUB[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
 {\r
   if (*VmPtr->Ip & DATAMANIP_M_64) {\r
     return (UINT64) ((INT64) ((INT64) Op1 - (INT64) Op2));\r
@@ -2899,6 +2753,19 @@ Instruction syntax:
   }\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC MUL instruction\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return Op1 * Op2\r
+  @return Instruction syntax:\r
+  @return MUL[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteMUL (\r
@@ -2906,24 +2773,6 @@ ExecuteMUL (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  \r
-  Execute the EBC MUL instruction\r
-\r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  Op1 * Op2\r
-\r
-Instruction syntax:\r
-  MUL[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
 {\r
   if (*VmPtr->Ip & DATAMANIP_M_64) {\r
     return MultS64x64 ((INT64)Op1, (INT64)Op2);\r
@@ -2932,6 +2781,19 @@ Instruction syntax:
   }\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC MULU instruction\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return (unsigned)Op1 * (unsigned)Op2\r
+  @return Instruction syntax:\r
+  @return MULU[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteMULU (\r
@@ -2939,23 +2801,6 @@ ExecuteMULU (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC MULU instruction\r
-\r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  (unsigned)Op1 * (unsigned)Op2 \r
-\r
-Instruction syntax:\r
-  MULU[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
 {\r
   if (*VmPtr->Ip & DATAMANIP_M_64) {\r
     return MultU64x64 (Op1, Op2);\r
@@ -2964,6 +2809,19 @@ Instruction syntax:
   }\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC DIV instruction\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return Op1/Op2\r
+  @return Instruction syntax:\r
+  @return DIV[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteDIV (\r
@@ -2971,24 +2829,6 @@ ExecuteDIV (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  \r
-  Execute the EBC DIV instruction\r
-\r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  Op1/Op2\r
-\r
-Instruction syntax:\r
-  DIV[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
 {\r
   INT64   Remainder;\r
 \r
@@ -3012,6 +2852,19 @@ Instruction syntax:
   }\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC DIVU instruction\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return (unsigned)Op1 / (unsigned)Op2\r
+  @return Instruction syntax:\r
+  @return DIVU[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteDIVU (\r
@@ -3019,23 +2872,6 @@ ExecuteDIVU (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC DIVU instruction\r
-\r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  (unsigned)Op1 / (unsigned)Op2\r
-\r
-Instruction syntax:\r
-  DIVU[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
 {\r
   UINT64  Remainder;\r
 \r
@@ -3061,6 +2897,19 @@ Instruction syntax:
   }\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC MOD instruction\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return Op1 MODULUS Op2\r
+  @return Instruction syntax:\r
+  @return MOD[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteMOD (\r
@@ -3068,23 +2917,6 @@ ExecuteMOD (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC MOD instruction\r
-\r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  Op1 MODULUS Op2\r
-\r
-Instruction syntax:\r
-  MOD[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
 {\r
   INT64   Remainder;\r
 \r
@@ -3104,6 +2936,19 @@ Instruction syntax:
   }\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC MODU instruction\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return Op1 UNSIGNED_MODULUS Op2\r
+  @return Instruction syntax:\r
+  @return MODU[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteMODU (\r
@@ -3111,23 +2956,6 @@ ExecuteMODU (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC MODU instruction\r
-\r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  Op1 UNSIGNED_MODULUS Op2\r
-\r
-Instruction syntax:\r
-  MODU[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-  \r
---*/\r
 {\r
   UINT64  Remainder;\r
 \r
@@ -3147,6 +2975,19 @@ Instruction syntax:
   }\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC AND instruction\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return Op1 AND Op2\r
+  @return Instruction syntax:\r
+  @return AND[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteAND (\r
@@ -3154,27 +2995,23 @@ ExecuteAND (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
+{\r
+  return Op1 & Op2;\r
+}\r
 \r
-Routine Description:\r
-  Execute the EBC AND instruction\r
 \r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
+/**\r
+  Execute the EBC OR instruction\r
 \r
-Returns:\r
-  Op1 AND Op2\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
 \r
-Instruction syntax:\r
-  AND[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
-{\r
-  return Op1 & Op2;\r
-}\r
+  @return Op1 OR Op2\r
+  @return Instruction syntax:\r
+  @return OR[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
 \r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteOR (\r
@@ -3182,27 +3019,23 @@ ExecuteOR (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC OR instruction\r
+{\r
+  return Op1 | Op2;\r
+}\r
 \r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
 \r
-Returns:\r
-  Op1 OR Op2\r
+/**\r
+  Execute the EBC XOR instruction\r
 \r
-Instruction syntax:\r
-  OR[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
 \r
---*/\r
-{\r
-  return Op1 | Op2;\r
-}\r
+  @return Op1 XOR Op2\r
+  @return Instruction syntax:\r
+  @return XOR[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
 \r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteXOR (\r
@@ -3210,27 +3043,23 @@ ExecuteXOR (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC XOR instruction\r
+{\r
+  return Op1 ^ Op2;\r
+}\r
 \r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
 \r
-Returns:\r
-  Op1 XOR Op2\r
+/**\r
+  Execute the EBC SHL shift left instruction\r
 \r
-Instruction syntax:\r
-  XOR[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
 \r
---*/\r
-{\r
-  return Op1 ^ Op2;\r
-}\r
+  @return Op1 << Op2\r
+  @return Instruction syntax:\r
+  @return SHL[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
 \r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteSHL (\r
@@ -3238,24 +3067,6 @@ ExecuteSHL (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  \r
-  Execute the EBC SHL shift left instruction\r
-\r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  Op1 << Op2\r
-\r
-Instruction syntax:\r
-  SHL[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
 {\r
   if (*VmPtr->Ip & DATAMANIP_M_64) {\r
     return LShiftU64 (Op1, (UINTN)Op2);\r
@@ -3264,6 +3075,19 @@ Instruction syntax:
   }\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC SHR instruction\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return Op1 >> Op2  (unsigned operands)\r
+  @return Instruction syntax:\r
+  @return SHR[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteSHR (\r
@@ -3271,23 +3095,6 @@ ExecuteSHR (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC SHR instruction\r
-\r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  Op1 >> Op2  (unsigned operands)\r
-\r
-Instruction syntax:\r
-  SHR[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
 {\r
   if (*VmPtr->Ip & DATAMANIP_M_64) {\r
     return RShiftU64 (Op1, (UINTN)Op2);\r
@@ -3296,6 +3103,19 @@ Instruction syntax:
   }\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC ASHR instruction\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return Op1 >> Op2 (signed)\r
+  @return Instruction syntax:\r
+  @return ASHR[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteASHR (\r
@@ -3303,23 +3123,6 @@ ExecuteASHR (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC ASHR instruction\r
-\r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  Op1 >> Op2 (signed)\r
-\r
-Instruction syntax:\r
-  ASHR[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
---*/\r
 {\r
   if (*VmPtr->Ip & DATAMANIP_M_64) {\r
     return ARShiftU64 (Op1, (UINTN)Op2);\r
@@ -3328,6 +3131,19 @@ Instruction syntax:
   }\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC EXTNDB instruction to sign-extend a byte value.\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return (INT64)(INT8)Op2\r
+  @return Instruction syntax:\r
+  @return EXTNDB[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteEXTNDB (\r
@@ -3335,24 +3151,6 @@ ExecuteEXTNDB (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC EXTNDB instruction to sign-extend a byte value.\r
-  \r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  (INT64)(INT8)Op2\r
-\r
-Instruction syntax:\r
-  EXTNDB[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
-  \r
---*/\r
 {\r
   INT8  Data8;\r
   INT64 Data64;\r
@@ -3366,6 +3164,19 @@ Instruction syntax:
   return (UINT64) Data64;\r
 }\r
 \r
+\r
+/**\r
+  Execute the EBC EXTNDW instruction to sign-extend a 16-bit value.\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return (INT64)(INT16)Op2\r
+  @return Instruction syntax:\r
+  @return EXTNDW[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteEXTNDW (\r
@@ -3373,24 +3184,6 @@ ExecuteEXTNDW (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC EXTNDW instruction to sign-extend a 16-bit value.\r
-  \r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  (INT64)(INT16)Op2\r
-\r
-Instruction syntax:\r
-  EXTNDW[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
-  \r
---*/\r
 {\r
   INT16 Data16;\r
   INT64 Data64;\r
@@ -3411,6 +3204,19 @@ Instruction syntax:
 //\r
 // Operation:  Dest <- SignExtended((DWORD)Source))\r
 //\r
+\r
+/**\r
+  Execute the EBC EXTNDD instruction to sign-extend a 32-bit value.\r
+\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Op1               Operand 1 from the instruction\r
+  @param  Op2               Operand 2 from the instruction\r
+\r
+  @return (INT64)(INT32)Op2\r
+  @return Instruction syntax:\r
+  @return EXTNDD[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 ExecuteEXTNDD (\r
@@ -3418,24 +3224,6 @@ ExecuteEXTNDD (
   IN UINT64       Op1,\r
   IN UINT64       Op2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Execute the EBC EXTNDD instruction to sign-extend a 32-bit value.\r
-  \r
-Arguments:\r
-  VmPtr     - pointer to a VM context  \r
-  Op1       - Operand 1 from the instruction \r
-  Op2       - Operand 2 from the instruction\r
-\r
-Returns:\r
-  (INT64)(INT32)Op2\r
-\r
-Instruction syntax:\r
-  EXTNDD[32|64] {@}R1, {@}R2 {Index16|Immed16}\r
-\r
-  \r
---*/\r
 {\r
   INT32 Data32;\r
   INT64 Data64;\r
@@ -3475,32 +3263,28 @@ ExecuteUnsignedDataManip (
   return ExecuteDataManip (VmPtr, FALSE);\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteDataManip (\r
-  IN VM_CONTEXT   *VmPtr,\r
-  IN BOOLEAN      IsSignedOp\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
-  Execute all the EBC data manipulation instructions. \r
-  Since the EBC data manipulation instructions all have the same basic form, \r
+/**\r
+  Execute all the EBC data manipulation instructions.\r
+  Since the EBC data manipulation instructions all have the same basic form,\r
   they can share the code that does the fetch of operands and the write-back\r
   of the result. This function performs the fetch of the operands (even if\r
   both are not needed to be fetched, like NOT instruction), dispatches to the\r
   appropriate subfunction, then writes back the returned result.\r
 \r
-Arguments:\r
-  VmPtr - pointer to VM context\r
+  @param  VmPtr             pointer to VM context\r
 \r
-Returns:\r
-  Standard EBC status\r
+  @return Standard EBC status\r
+  @return Format:\r
+  @return INSTRUCITON[32|64] {@}R1, {@}R2 {Immed16|Index16}\r
 \r
-Format:  \r
-  INSTRUCITON[32|64] {@}R1, {@}R2 {Immed16|Index16}\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteDataManip (\r
+  IN VM_CONTEXT   *VmPtr,\r
+  IN BOOLEAN      IsSignedOp\r
+  )\r
 {\r
   UINT8   Opcode;\r
   INT16   Index16;\r
@@ -3632,26 +3416,22 @@ Format:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteLOADSP (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Execute the EBC LOADSP instruction\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Returns:\r
-  Standard EFI_STATUS\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return LOADSP  SP1, R2\r
 \r
-Instruction syntax:\r
-  LOADSP  SP1, R2\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteLOADSP (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8 Operands;\r
 \r
@@ -3689,26 +3469,22 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-ExecuteSTORESP (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   Execute the EBC STORESP instruction\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
-\r
-Returns:\r
-  Standard EFI_STATUS\r
+  @param  VmPtr             pointer to a VM context\r
 \r
-Instruction syntax:\r
-   STORESP  Rx, FLAGS|IP\r
+  @return Standard EFI_STATUS\r
+  @return Instruction syntax:\r
+  @return STORESP  Rx, FLAGS|IP\r
 \r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+ExecuteSTORESP (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   UINT8 Operands;\r
 \r
@@ -3753,37 +3529,32 @@ Instruction syntax:
   return EFI_SUCCESS;\r
 }\r
 \r
+\r
+/**\r
+  Decode a 16-bit index to determine the offset. Given an index value:\r
+  b15     - sign bit\r
+  b14:12  - number of bits in this index assigned to natural units (=a)\r
+  ba:11   - constant units = C\r
+  b0:a    - natural units = N\r
+  Given this info, the offset can be computed by:\r
+  offset = sign_bit * (C + N * sizeof(UINTN))\r
+  Max offset is achieved with index = 0x7FFF giving an offset of\r
+  0x27B (32-bit machine) or 0x477 (64-bit machine).\r
+  Min offset is achieved with index =\r
+\r
+  @param  VmPtr             pointer to VM context\r
+  @param  CodeOffset        offset from IP of the location of the 16-bit index to\r
+                            decode\r
+\r
+  @return The decoded offset.\r
+\r
+**/\r
 STATIC\r
 INT16\r
 VmReadIndex16 (\r
   IN VM_CONTEXT     *VmPtr,\r
   IN UINT32         CodeOffset\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Decode a 16-bit index to determine the offset. Given an index value:\r
-\r
-    b15     - sign bit\r
-    b14:12  - number of bits in this index assigned to natural units (=a)\r
-    ba:11   - constant units = C\r
-    b0:a    - natural units = N\r
-  \r
-  Given this info, the offset can be computed by:\r
-    offset = sign_bit * (C + N * sizeof(UINTN))\r
-\r
-  Max offset is achieved with index = 0x7FFF giving an offset of\r
-  0x27B (32-bit machine) or 0x477 (64-bit machine).\r
-  Min offset is achieved with index = \r
-  \r
-Arguments:\r
-  VmPtr       - pointer to VM context\r
-  CodeOffset  - offset from IP of the location of the 16-bit index to decode\r
-\r
-Returns:\r
-  The decoded offset.\r
-  \r
---*/\r
 {\r
   UINT16  Index;\r
   INT16   Offset;\r
@@ -3839,25 +3610,23 @@ Returns:
   return Offset;\r
 }\r
 \r
+\r
+/**\r
+  Decode a 32-bit index to determine the offset.\r
+\r
+  @param  VmPtr             pointer to VM context\r
+  @param  CodeOffset        offset from IP of the location of the 32-bit index to\r
+                            decode\r
+\r
+  @return Converted index per EBC VM specification\r
+\r
+**/\r
 STATIC\r
 INT32\r
 VmReadIndex32 (\r
   IN VM_CONTEXT     *VmPtr,\r
   IN UINT32         CodeOffset\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Decode a 32-bit index to determine the offset.\r
-\r
-Arguments:\r
-  VmPtr       - pointer to VM context\r
-  CodeOffset  - offset from IP of the location of the 32-bit index to decode\r
-\r
-Returns:\r
-  Converted index per EBC VM specification\r
-\r
---*/\r
 {\r
   UINT32  Index;\r
   INT32   Offset;\r
@@ -3905,25 +3674,23 @@ Returns:
   return Offset;\r
 }\r
 \r
+\r
+/**\r
+  Decode a 64-bit index to determine the offset.\r
+\r
+  @param  VmPtr             pointer to VM context\r
+  @param  CodeOffset        offset from IP of the location of the 64-bit index to\r
+                            decode\r
+\r
+  @return Converted index per EBC VM specification\r
+\r
+**/\r
 STATIC\r
 INT64\r
 VmReadIndex64 (\r
   IN VM_CONTEXT     *VmPtr,\r
   IN UINT32         CodeOffset\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Decode a 64-bit index to determine the offset.\r
-\r
-Arguments:\r
-  VmPtr       - pointer to VM context\r
-  CodeOffset  - offset from IP of the location of the 64-bit index to decode\r
-\r
-Returns:\r
-  Converted index per EBC VM specification\r
-\r
---*/\r
 {\r
   UINT64  Index;\r
   INT64   Offset;\r
@@ -3971,37 +3738,32 @@ Returns:
   return Offset;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-VmWriteMem8 (\r
-  IN VM_CONTEXT    *VmPtr,\r
-  IN UINTN         Addr,\r
-  IN UINT8         Data\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
+/**\r
   The following VmWriteMem? routines are called by the EBC data\r
   movement instructions that write to memory. Since these writes\r
   may be to the stack, which looks like (high address on top) this,\r
-\r
   [EBC entry point arguments]\r
   [VM stack]\r
   [EBC stack]\r
-\r
   we need to detect all attempts to write to the EBC entry point argument\r
-  stack area and adjust the address (which will initially point into the \r
+  stack area and adjust the address (which will initially point into the\r
   VM stack) to point into the EBC entry point arguments.\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
-  Addr    - adddress to write to\r
-  Data    - value to write to Addr\r
-  \r
-Returns:\r
-  Standard EFI_STATUS\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Addr              adddress to write to\r
+  @param  Data              value to write to Addr\r
+\r
+  @return Standard EFI_STATUS\r
 \r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+VmWriteMem8 (\r
+  IN VM_CONTEXT    *VmPtr,\r
+  IN UINTN         Addr,\r
+  IN UINT8         Data\r
+  )\r
 {\r
   //\r
   // Convert the address if it's in the stack gap\r
@@ -4166,29 +3928,25 @@ VmWriteMemN (
   return Status;\r
 }\r
 \r
-STATIC\r
-INT8\r
-VmReadImmed8 (\r
-  IN VM_CONTEXT *VmPtr,\r
-  IN UINT32     Offset\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
-  \r
+/**\r
   The following VmReadImmed routines are called by the EBC execute\r
   functions to read EBC immediate values from the code stream.\r
-  Since we can't assume alignment, each tries to read in the biggest \r
+  Since we can't assume alignment, each tries to read in the biggest\r
   chunks size available, but will revert to smaller reads if necessary.\r
 \r
-Arguments:\r
-  VmPtr   - pointer to a VM context  \r
-  Offset  - offset from IP of the code bytes to read.\r
+  @param  VmPtr             pointer to a VM context\r
+  @param  Offset            offset from IP of the code bytes to read.\r
 \r
-Returns:\r
-  Signed data of the requested size from the specified address.\r
+  @return Signed data of the requested size from the specified address.\r
 \r
---*/\r
+**/\r
+STATIC\r
+INT8\r
+VmReadImmed8 (\r
+  IN VM_CONTEXT *VmPtr,\r
+  IN UINT32     Offset\r
+  )\r
 {\r
   //\r
   // Simply return the data in flat memory space\r
@@ -4276,26 +4034,23 @@ VmReadImmed64 (
   return Data64;\r
 }\r
 \r
+\r
+/**\r
+  The following VmReadCode() routines provide the ability to read raw\r
+  unsigned data from the code stream.\r
+\r
+  @param  VmPtr             pointer to VM context\r
+  @param  Offset            offset from current IP to the raw data to read.\r
+\r
+  @return The raw unsigned 16-bit value from the code stream.\r
+\r
+**/\r
 STATIC\r
 UINT16\r
 VmReadCode16 (\r
   IN VM_CONTEXT *VmPtr,\r
   IN UINT32     Offset\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  The following VmReadCode() routines provide the ability to read raw \r
-  unsigned data from the code stream. \r
-  \r
-Arguments:\r
-  VmPtr   - pointer to VM context\r
-  Offset  - offset from current IP to the raw data to read.\r
-\r
-Returns:\r
-  The raw unsigned 16-bit value from the code stream.\r
-  \r
---*/\r
 {\r
   //\r
   // Read direct if aligned\r
@@ -4466,64 +4221,53 @@ VmReadMem64 (
   return Data;\r
 }\r
 \r
-STATIC\r
-UINTN\r
-ConvertStackAddr (\r
-  IN VM_CONTEXT    *VmPtr,\r
-  IN UINTN         Addr\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Given an address that EBC is going to read from or write to, return\r
   an appropriate address that accounts for a gap in the stack.\r
-  \r
   The stack for this application looks like this (high addr on top)\r
   [EBC entry point arguments]\r
   [VM stack]\r
   [EBC stack]\r
-\r
   The EBC assumes that its arguments are at the top of its stack, which\r
   is where the VM stack is really. Therefore if the EBC does memory\r
   accesses into the VM stack area, then we need to convert the address\r
   to point to the EBC entry point arguments area. Do this here.\r
 \r
-Arguments:\r
+  @param  VmPtr             pointer to VM context\r
+  @param  Addr              address of interest\r
 \r
-  VmPtr    - pointer to VM context\r
-  Addr  - address of interest\r
+  @return The unchanged address if it's not in the VM stack region. Otherwise,\r
+  @return adjust for the stack gap and return the modified address.\r
 \r
-Returns:\r
-\r
-  The unchanged address if it's not in the VM stack region. Otherwise, \r
-  adjust for the stack gap and return the modified address.\r
-  \r
---*/\r
-{ \r
+**/\r
+STATIC\r
+UINTN\r
+ConvertStackAddr (\r
+  IN VM_CONTEXT    *VmPtr,\r
+  IN UINTN         Addr\r
+  )\r
+{\r
   ASSERT(((Addr < VmPtr->LowStackTop) || (Addr > VmPtr->HighStackBottom)));\r
   return Addr;\r
 }\r
 \r
+\r
+/**\r
+  Read a natural value from memory. May or may not be aligned.\r
+\r
+  @param  VmPtr             current VM context\r
+  @param  Addr              the address to read from\r
+\r
+  @return The natural value at address Addr.\r
+\r
+**/\r
 STATIC\r
 UINTN\r
 VmReadMemN (\r
   IN VM_CONTEXT    *VmPtr,\r
   IN UINTN         Addr\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Read a natural value from memory. May or may not be aligned.\r
-  \r
-Arguments:\r
-  VmPtr   - current VM context\r
-  Addr    - the address to read from\r
-\r
-Returns:\r
-  The natural value at address Addr.\r
-  \r
---*/\r
 {\r
   UINTN   Data;\r
   volatile UINT32  Size;\r
index b1926ee975c85cec099c3b49371fee552cf501cf..91aada0d5551bc67cb73746154643363ad93b6a4 100644 (file)
@@ -1,25 +1,18 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
-\r
-  EbcExecute.h\r
-\r
-Abstract:\r
-\r
+/** @file\r
   Header file for Virtual Machine support. Contains EBC defines that can\r
-  be of use to a disassembler for the most part. Also provides function \r
+  be of use to a disassembler for the most part. Also provides function\r
   prototypes for VM functions.\r
 \r
---*/\r
+Copyright (c) 2006, 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
+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
+\r
+**/\r
 \r
 #ifndef _EBC_EXECUTE_H_\r
 #define _EBC_EXECUTE_H_\r
index 2b647d9bae3792c8a0d29b590d0f95db85bdb88f..37a2b7f6b005f9008d9c6f352ae0302079bfcad9 100644 (file)
@@ -1,4 +1,7 @@
-/*++\r
+/** @file\r
+  Top level module for the EBC virtual machine implementation.\r
+  Provides auxilliary support routines for the VM. That is, routines\r
+  that are not particularly related to VM execution of EBC instructions.\r
 \r
 Copyright (c) 2006, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
@@ -9,17 +12,7 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
-Module Name:\r
-\r
-  EbcInt.c\r
-\r
-Abstract:\r
-\r
-  Top level module for the EBC virtual machine implementation.\r
-  Provides auxilliary support routines for the VM. That is, routines\r
-  that are not particularly related to VM execution of EBC instructions.\r
-\r
---*/\r
+**/\r
 \r
 #include "EbcInt.h"\r
 #include "EbcExecute.h"\r
@@ -188,28 +181,23 @@ static UINTN      mStackNum = 0;
 static EFI_EVENT              mEbcPeriodicEvent;\r
 VM_CONTEXT                    *mVmPtr = NULL;\r
 \r
-EFI_STATUS\r
-EFIAPI\r
-InitializeEbcDriver (\r
-  IN EFI_HANDLE           ImageHandle,\r
-  IN EFI_SYSTEM_TABLE     *SystemTable\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Initializes the VM EFI interface.  Allocates memory for the VM interface\r
   and registers the VM protocol.\r
 \r
-Arguments:\r
-\r
-  ImageHandle - EFI image handle.\r
-  SystemTable - Pointer to the EFI system table.\r
+  @param  ImageHandle            EFI image handle.\r
+  @param  SystemTable            Pointer to the EFI system table.\r
 \r
-Returns:\r
-  Standard EFI status code.\r
+  @return Standard EFI status code.\r
 \r
---*/\r
+**/\r
+EFI_STATUS\r
+EFIAPI\r
+InitializeEbcDriver (\r
+  IN EFI_HANDLE           ImageHandle,\r
+  IN EFI_SYSTEM_TABLE     *SystemTable\r
+  )\r
 {\r
   EFI_EBC_PROTOCOL            *EbcProtocol;\r
   EFI_EBC_PROTOCOL            *OldEbcProtocol;\r
@@ -384,6 +372,24 @@ ErrorExit:
   return Status;\r
 }\r
 \r
+\r
+/**\r
+  This is the top-level routine plugged into the EBC protocol. Since thunks\r
+  are very processor-specific, from here we dispatch directly to the very\r
+  processor-specific routine EbcCreateThunks().\r
+\r
+  @param  This                   protocol instance pointer\r
+  @param  ImageHandle            handle to the image. The EBC interpreter may use\r
+                                 this to keep track of any resource allocations\r
+                                 performed in loading and executing the image.\r
+  @param  EbcEntryPoint          the entry point for the image (as defined in the\r
+                                 file header)\r
+  @param  Thunk                  pointer to thunk pointer where the address of the\r
+                                 created thunk is returned.\r
+\r
+  @return EFI_STATUS\r
+\r
+**/\r
 STATIC\r
 EFI_STATUS\r
 EFIAPI\r
@@ -393,29 +399,6 @@ EbcCreateThunk (
   IN VOID               *EbcEntryPoint,\r
   OUT VOID              **Thunk\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  This is the top-level routine plugged into the EBC protocol. Since thunks\r
-  are very processor-specific, from here we dispatch directly to the very\r
-  processor-specific routine EbcCreateThunks().\r
-\r
-Arguments:\r
-\r
-  This          - protocol instance pointer\r
-  ImageHandle   - handle to the image. The EBC interpreter may use this to keep\r
-                  track of any resource allocations performed in loading and\r
-                  executing the image.\r
-  EbcEntryPoint - the entry point for the image (as defined in the file header)\r
-  Thunk         - pointer to thunk pointer where the address of the created\r
-                  thunk is returned.\r
-\r
-Returns:\r
-\r
-  EFI_STATUS\r
-\r
---*/\r
 {\r
   EFI_STATUS  Status;\r
 \r
@@ -428,6 +411,18 @@ Returns:
   return Status;\r
 }\r
 \r
+\r
+/**\r
+  This EBC debugger protocol service is called by the debug agent\r
+\r
+  @param  This                   pointer to the caller's debug support protocol\r
+                                 interface\r
+  @param  MaxProcessorIndex      pointer to a caller allocated UINTN in which the\r
+                                 maximum processor index is returned.\r
+\r
+  @return Standard EFI_STATUS\r
+\r
+**/\r
 STATIC\r
 EFI_STATUS\r
 EFIAPI\r
@@ -435,28 +430,23 @@ EbcDebugGetMaximumProcessorIndex (
   IN EFI_DEBUG_SUPPORT_PROTOCOL          *This,\r
   OUT UINTN                              *MaxProcessorIndex\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  This EBC debugger protocol service is called by the debug agent\r
-\r
-Arguments:\r
-\r
-  This              - pointer to the caller's debug support protocol interface\r
-  MaxProcessorIndex - pointer to a caller allocated UINTN in which the maximum\r
-                      processor index is returned.\r
-\r
-Returns:\r
-\r
-  Standard EFI_STATUS\r
-\r
---*/\r
 {\r
   *MaxProcessorIndex = 0;\r
   return EFI_SUCCESS;\r
 }\r
 \r
+\r
+/**\r
+  This protocol service is called by the debug agent to register a function\r
+  for us to call on a periodic basis.\r
+\r
+  @param  This                   pointer to the caller's debug support protocol\r
+                                 interface\r
+  @param  PeriodicCallback       pointer to the function to call periodically\r
+\r
+  @return Always EFI_SUCCESS\r
+\r
+**/\r
 STATIC\r
 EFI_STATUS\r
 EFIAPI\r
@@ -465,24 +455,6 @@ EbcDebugRegisterPeriodicCallback (
   IN UINTN                       ProcessorIndex,\r
   IN EFI_PERIODIC_CALLBACK       PeriodicCallback\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  This protocol service is called by the debug agent to register a function\r
-  for us to call on a periodic basis.\r
-\r
-\r
-Arguments:\r
-\r
-  This              - pointer to the caller's debug support protocol interface\r
-  PeriodicCallback  - pointer to the function to call periodically\r
-\r
-Returns:\r
-\r
-  Always EFI_SUCCESS\r
-\r
---*/\r
 {\r
   if ((mDebugPeriodicCallback == NULL) && (PeriodicCallback == NULL)) {\r
     return EFI_INVALID_PARAMETER;\r
@@ -495,6 +467,18 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
+\r
+/**\r
+  This protocol service is called by the debug agent to register a function\r
+  for us to call when we detect an exception.\r
+\r
+  @param  This                   pointer to the caller's debug support protocol\r
+                                 interface\r
+  @param  ExceptionCallback      pointer to the function to the exception\r
+\r
+  @return Always EFI_SUCCESS\r
+\r
+**/\r
 STATIC\r
 EFI_STATUS\r
 EFIAPI\r
@@ -504,24 +488,6 @@ EbcDebugRegisterExceptionCallback (
   IN EFI_EXCEPTION_CALLBACK      ExceptionCallback,\r
   IN EFI_EXCEPTION_TYPE          ExceptionType\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  This protocol service is called by the debug agent to register a function\r
-  for us to call when we detect an exception.\r
-\r
-\r
-Arguments:\r
-\r
-  This              - pointer to the caller's debug support protocol interface\r
-  ExceptionCallback - pointer to the function to the exception\r
-\r
-Returns:\r
-\r
-  Always EFI_SUCCESS\r
-\r
---*/\r
 {\r
   if ((ExceptionType < 0) || (ExceptionType > MAX_EBC_EXCEPTION)) {\r
     return EFI_INVALID_PARAMETER;\r
@@ -536,6 +502,15 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
+\r
+/**\r
+  This EBC debugger protocol service is called by the debug agent.  Required\r
+  for DebugSupport compliance but is only stubbed out for EBC.\r
+\r
+\r
+  @return EFI_SUCCESS\r
+\r
+**/\r
 STATIC\r
 EFI_STATUS\r
 EFIAPI\r
@@ -545,45 +520,26 @@ EbcDebugInvalidateInstructionCache (
   IN VOID                                *Start,\r
   IN UINT64                              Length\r
   )\r
-/*++\r
-\r
-Routine Description:\r
+{\r
+  return EFI_SUCCESS;\r
+}\r
 \r
-  This EBC debugger protocol service is called by the debug agent.  Required\r
-  for DebugSupport compliance but is only stubbed out for EBC.\r
 \r
-Arguments:\r
+/**\r
+  The VM interpreter calls this function when an exception is detected.\r
 \r
-Returns:\r
+  @param  VmPtr                  pointer to a VM context for passing info to the\r
+                                 EFI debugger.\r
 \r
-  EFI_SUCCESS\r
-\r
---*/\r
-{\r
-  return EFI_SUCCESS;\r
-}\r
+  @return EFI_SUCCESS if it returns at all\r
 \r
+**/\r
 EFI_STATUS\r
 EbcDebugSignalException (\r
   IN EFI_EXCEPTION_TYPE                   ExceptionType,\r
   IN EXCEPTION_FLAGS                      ExceptionFlags,\r
   IN VM_CONTEXT                           *VmPtr\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  The VM interpreter calls this function when an exception is detected.\r
-\r
-Arguments:\r
-\r
-  VmPtr - pointer to a VM context for passing info to the EFI debugger.\r
-\r
-Returns:\r
-\r
-  EFI_SUCCESS if it returns at all\r
-\r
---*/\r
 {\r
   EFI_SYSTEM_CONTEXT_EBC  EbcContext;\r
   EFI_SYSTEM_CONTEXT      SystemContext;\r
@@ -645,26 +601,20 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-InitializeEbcCallback (\r
-  IN EFI_DEBUG_SUPPORT_PROTOCOL  *This\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   To install default Callback function for the VM interpreter.\r
 \r
-Arguments:\r
+  @param  This                   pointer to the instance of DebugSupport protocol\r
 \r
-  This - pointer to the instance of DebugSupport protocol\r
+  @return None\r
 \r
-Returns:\r
-\r
-  None\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+InitializeEbcCallback (\r
+  IN EFI_DEBUG_SUPPORT_PROTOCOL  *This\r
+  )\r
 {\r
   INTN       Index;\r
   EFI_STATUS Status;\r
@@ -707,30 +657,24 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-VOID\r
-CommonEbcExceptionHandler (\r
-  IN EFI_EXCEPTION_TYPE   InterruptType,\r
-  IN EFI_SYSTEM_CONTEXT   SystemContext\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   The default Exception Callback for the VM interpreter.\r
   In this function, we report status code, and print debug information\r
   about EBC_CONTEXT, then dead loop.\r
 \r
-Arguments:\r
-\r
-  InterruptType - Interrupt type.\r
-  SystemContext - EBC system context.\r
-\r
-Returns:\r
+  @param  InterruptType          Interrupt type.\r
+  @param  SystemContext          EBC system context.\r
 \r
-  None\r
+  @return None\r
 \r
---*/\r
+**/\r
+STATIC\r
+VOID\r
+CommonEbcExceptionHandler (\r
+  IN EFI_EXCEPTION_TYPE   InterruptType,\r
+  IN EFI_SYSTEM_CONTEXT   SystemContext\r
+  )\r
 {\r
   //\r
   // We deadloop here to make it easy to debug this issue.\r
@@ -740,6 +684,17 @@ Returns:
   return ;\r
 }\r
 \r
+\r
+/**\r
+  The periodic callback function for EBC VM interpreter, which is used\r
+  to support the EFI debug support protocol.\r
+\r
+  @param  Event                  The Periodic Callback Event.\r
+  @param  Context                It should be the address of VM_CONTEXT pointer.\r
+\r
+  @return None.\r
+\r
+**/\r
 STATIC\r
 VOID\r
 EFIAPI\r
@@ -747,23 +702,6 @@ EbcPeriodicNotifyFunction (
   IN EFI_EVENT     Event,\r
   IN VOID          *Context\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  The periodic callback function for EBC VM interpreter, which is used\r
-  to support the EFI debug support protocol.\r
-\r
-Arguments:\r
-\r
-  Event   - The Periodic Callback Event.\r
-  Context - It should be the address of VM_CONTEXT pointer.\r
-\r
-Returns:\r
-\r
-  None.\r
-\r
---*/\r
 {\r
   VM_CONTEXT *VmPtr;\r
 \r
@@ -776,27 +714,22 @@ Returns:
   return ;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-EbcDebugPeriodic (\r
-  IN VM_CONTEXT *VmPtr\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   The VM interpreter calls this function on a periodic basis to support\r
   the EFI debug support protocol.\r
 \r
-Arguments:\r
-\r
-  VmPtr - pointer to a VM context for passing info to the debugger.\r
+  @param  VmPtr                  pointer to a VM context for passing info to the\r
+                                 debugger.\r
 \r
-Returns:\r
+  @return Standard EFI status.\r
 \r
-  Standard EFI status.\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+EbcDebugPeriodic (\r
+  IN VM_CONTEXT *VmPtr\r
+  )\r
 {\r
   EFI_SYSTEM_CONTEXT_EBC   EbcContext;\r
   EFI_SYSTEM_CONTEXT       SystemContext;\r
@@ -842,33 +775,27 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
-STATIC\r
-EFI_STATUS\r
-EFIAPI\r
-EbcUnloadImage (\r
-  IN EFI_EBC_PROTOCOL   *This,\r
-  IN EFI_HANDLE         ImageHandle\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   This routine is called by the core when an image is being unloaded from\r
   memory. Basically we now have the opportunity to do any necessary cleanup.\r
   Typically this will include freeing any memory allocated for thunk-creation.\r
 \r
-Arguments:\r
-\r
-  This          - protocol instance pointer\r
-  ImageHandle   - handle to the image being unloaded.\r
-\r
-Returns:\r
+  @param  This                   protocol instance pointer\r
+  @param  ImageHandle            handle to the image being unloaded.\r
 \r
-  EFI_INVALID_PARAMETER  - the ImageHandle passed in was not found in\r
-                           the internal list of EBC image handles.\r
-  EFI_STATUS             - completed successfully\r
+  @retval EFI_INVALID_PARAMETER  the ImageHandle passed in was not found in the\r
+                                 internal list of EBC image handles.\r
+  @retval EFI_STATUS             completed successfully\r
 \r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+EFIAPI\r
+EbcUnloadImage (\r
+  IN EFI_EBC_PROTOCOL   *This,\r
+  IN EFI_HANDLE         ImageHandle\r
+  )\r
 {\r
   EBC_THUNK_LIST  *ThunkList;\r
   EBC_THUNK_LIST  *NextThunkList;\r
@@ -922,32 +849,26 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
-EFI_STATUS\r
-EbcAddImageThunk (\r
-  IN EFI_HANDLE      ImageHandle,\r
-  IN VOID            *ThunkBuffer,\r
-  IN UINT32          ThunkSize\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Add a thunk to our list of thunks for a given image handle.\r
   Also flush the instruction cache since we've written thunk code\r
   to memory that will be executed eventually.\r
 \r
-Arguments:\r
-\r
-  ImageHandle - the image handle to which the thunk is tied\r
-  ThunkBuffer - the buffer we've created/allocated\r
-  ThunkSize    - the size of the thunk memory allocated\r
-\r
-Returns:\r
+  @param  ImageHandle            the image handle to which the thunk is tied\r
+  @param  ThunkBuffer            the buffer we've created/allocated\r
+  @param  ThunkSize              the size of the thunk memory allocated\r
 \r
-  EFI_OUT_OF_RESOURCES    - memory allocation failed\r
-  EFI_SUCCESS             - successful completion\r
+  @retval EFI_OUT_OF_RESOURCES   memory allocation failed\r
+  @retval EFI_SUCCESS            successful completion\r
 \r
---*/\r
+**/\r
+EFI_STATUS\r
+EbcAddImageThunk (\r
+  IN EFI_HANDLE      ImageHandle,\r
+  IN VOID            *ThunkBuffer,\r
+  IN UINT32          ThunkSize\r
+  )\r
 {\r
   EBC_THUNK_LIST  *ThunkList;\r
   EBC_IMAGE_LIST  *ImageList;\r
@@ -1113,27 +1034,21 @@ FreeEBCStack(
   }\r
   return EFI_SUCCESS;\r
 }\r
-STATIC\r
-EFI_STATUS\r
-InitEbcVmTestProtocol (\r
-  IN EFI_HANDLE     *IHandle\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Produce an EBC VM test protocol that can be used for regression tests.\r
 \r
-Arguments:\r
-\r
-  IHandle - handle on which to install the protocol.\r
+  @param  IHandle                handle on which to install the protocol.\r
 \r
-Returns:\r
+  @retval EFI_OUT_OF_RESOURCES   memory allocation failed\r
+  @retval EFI_SUCCESS            successful completion\r
 \r
-  EFI_OUT_OF_RESOURCES  - memory allocation failed\r
-  EFI_SUCCESS           - successful completion\r
-\r
---*/\r
+**/\r
+STATIC\r
+EFI_STATUS\r
+InitEbcVmTestProtocol (\r
+  IN EFI_HANDLE     *IHandle\r
+  )\r
 {\r
   EFI_HANDLE Handle;\r
   EFI_STATUS Status;\r
index a62b121531bc93adfab4fe5f5edf9255a792a026..c9f2b825f14be10b5709e85f2af58b9394329c1a 100644 (file)
@@ -1,24 +1,17 @@
-/*++ \r
-\r
-Copyright (c) 2006, 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
-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
+/** @file\r
+  Main routines for the EBC interpreter.  Includes the initialization and\r
+  main interpreter routines.\r
 \r
-Module Name:  \r
+Copyright (c) 2006, 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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-  EbcInt.h\r
-  \r
-Abstract:\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
 \r
-  Main routines for the EBC interpreter.  Includes the initialization and\r
-  main interpreter routines. \r
-  \r
---*/\r
+**/\r
 \r
 #ifndef _EBC_INT_H_\r
 #define _EBC_INT_H_\r
index a534e0078081067386af4b7f1372e03ddcf0a691..1d008ac7822bc3510c9f21b422a4545df2e371e2 100644 (file)
@@ -1,24 +1,17 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
-\r
-  EbcSupport.c\r
-\r
-Abstract:\r
-\r
+/** @file\r
   This module contains EBC support routines that are customized based on\r
   the target processor.\r
 \r
---*/\r
+Copyright (c) 2006, 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
+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
+\r
+**/\r
 \r
 #include "EbcInt.h"\r
 #include "EbcExecute.h"\r
@@ -33,38 +26,33 @@ Abstract:
 #define EBC_THUNK_SIZE  32\r
 \r
 #define STACK_REMAIN_SIZE (1024 * 4)\r
-VOID\r
-EbcLLCALLEX (\r
-  IN VM_CONTEXT   *VmPtr,\r
-  IN UINTN        FuncAddr,\r
-  IN UINTN        NewStackPointer,\r
-  IN VOID         *FramePtr,\r
-  IN UINT8        Size\r
-  )\r
-/*++\r
 \r
-Routine Description:\r
 \r
-  This function is called to execute an EBC CALLEX instruction. \r
+/**\r
+  This function is called to execute an EBC CALLEX instruction.\r
   The function check the callee's content to see whether it is common native\r
   code or a thunk to another piece of EBC code.\r
   If the callee is common native code, use EbcLLCAllEXASM to manipulate,\r
   otherwise, set the VM->IP to target EBC code directly to avoid another VM\r
   be startup which cost time and stack space.\r
-  \r
-Arguments:\r
 \r
-  VmPtr             - Pointer to a VM context.\r
-  FuncAddr          - Callee's address\r
-  NewStackPointer   - New stack pointer after the call\r
-  FramePtr          - New frame pointer after the call\r
-  Size              - The size of call instruction\r
+  @parm VmPtr              Pointer to a VM context.\r
+  @parm FuncAddr           Callee's address\r
+  @parm NewStackPointer    New stack pointer after the call\r
+  @parm FramePtr           New frame pointer after the call\r
+  @parm Size               The size of call instruction\r
 \r
-Returns:\r
+  @return None.\r
 \r
-  None.\r
-  \r
---*/\r
+**/\r
+VOID\r
+EbcLLCALLEX (\r
+  IN VM_CONTEXT   *VmPtr,\r
+  IN UINTN        FuncAddr,\r
+  IN UINTN        NewStackPointer,\r
+  IN VOID         *FramePtr,\r
+  IN UINT8        Size\r
+  )\r
 {\r
   UINTN    IsThunk;\r
   UINTN    TargetEbcAddr;\r
@@ -134,7 +122,7 @@ Action:
     // The callee is not a thunk to EBC, call native code.\r
     //\r
     EbcLLCALLEXNative (FuncAddr, NewStackPointer, FramePtr);\r
-    \r
+\r
     //\r
     // Get return value and advance the IP.\r
     //\r
@@ -143,6 +131,19 @@ Action:
   }\r
 }\r
 \r
+\r
+/**\r
+  Begin executing an EBC image. The address of the entry point is passed\r
+  in via a processor register, so we'll need to make a call to get the\r
+  value.\r
+\r
+  None. Since we're called from a fixed up thunk (which we want to keep\r
+  small), our only so-called argument is the EBC entry point passed in\r
+  to us in a processor register.\r
+\r
+  @return The value returned by the EBC application we're going to run.\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 EbcInterpret (\r
@@ -163,25 +164,6 @@ EbcInterpret (
   IN OUT UINTN      Arg15,\r
   IN OUT UINTN      Arg16\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Begin executing an EBC image. The address of the entry point is passed\r
-  in via a processor register, so we'll need to make a call to get the\r
-  value.\r
-  \r
-Arguments:\r
-\r
-  None. Since we're called from a fixed up thunk (which we want to keep\r
-  small), our only so-called argument is the EBC entry point passed in\r
-  to us in a processor register.\r
-\r
-Returns:\r
-\r
-  The value returned by the EBC application we're going to run.\r
-  \r
---*/\r
 {\r
   //\r
   // Create a new VM context on the stack\r
@@ -298,30 +280,24 @@ Returns:
   return (UINT64) VmContext.R[7];\r
 }\r
 \r
-STATIC\r
-UINT64\r
-ExecuteEbcImageEntryPoint (\r
-  IN EFI_HANDLE           ImageHandle,\r
-  IN EFI_SYSTEM_TABLE     *SystemTable\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Begin executing an EBC image. The address of the entry point is passed\r
   in via a processor register, so we'll need to make a call to get the\r
   value.\r
-  \r
-Arguments:\r
 \r
-  ImageHandle   - image handle for the EBC application we're executing\r
-  SystemTable   - standard system table passed into an driver's entry point\r
+  @param  ImageHandle    image handle for the EBC application we're executing\r
+  @param  SystemTable    standard system table passed into an driver's entry point\r
 \r
-Returns:\r
+  @return The value returned by the EBC application we're going to run.\r
 \r
-  The value returned by the EBC application we're going to run.\r
-\r
---*/\r
+**/\r
+STATIC\r
+UINT64\r
+ExecuteEbcImageEntryPoint (\r
+  IN EFI_HANDLE           ImageHandle,\r
+  IN EFI_SYSTEM_TABLE     *SystemTable\r
+  )\r
 {\r
   //\r
   // Create a new VM context on the stack\r
@@ -373,7 +349,7 @@ Returns:
   VmContext.R[0] = (UINT64)(UINTN) ((UINT8*)VmContext.StackPool + STACK_POOL_SIZE);\r
   VmContext.HighStackBottom = (UINTN)VmContext.R[0];\r
   VmContext.R[0] -= sizeof (UINTN);\r
-  \r
+\r
   //\r
   // Put a magic value in the stack gap, then adjust down again\r
   //\r
@@ -390,7 +366,7 @@ Returns:
   VmContext.R[0] -= sizeof (UINTN);\r
   *(UINTN *) (UINTN) (VmContext.R[0]) = (UINTN) ImageHandle;\r
 \r
-  VmContext.R[0] -= 16; \r
+  VmContext.R[0] -= 16;\r
   VmContext.StackRetAddr  = (UINT64) VmContext.R[0];\r
   //\r
   // VM pushes 16-bytes for return address. Simulate that here.\r
@@ -407,6 +383,17 @@ Returns:
   return (UINT64) VmContext.R[7];\r
 }\r
 \r
+\r
+/**\r
+  Create an IA32 thunk for the given EBC entry point.\r
+\r
+  @param  ImageHandle    Handle of image for which this thunk is being created\r
+  @param  EbcEntryPoint  Address of the EBC code that the thunk is to call\r
+  @param  Thunk          Returned thunk we create here\r
+\r
+  @return Standard EFI status.\r
+\r
+**/\r
 EFI_STATUS\r
 EbcCreateThunks (\r
   IN EFI_HANDLE           ImageHandle,\r
@@ -414,23 +401,6 @@ EbcCreateThunks (
   OUT VOID                **Thunk,\r
   IN  UINT32              Flags\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Create an IA32 thunk for the given EBC entry point.\r
-  \r
-Arguments:\r
-\r
-  ImageHandle     - Handle of image for which this thunk is being created\r
-  EbcEntryPoint   - Address of the EBC code that the thunk is to call\r
-  Thunk           - Returned thunk we create here\r
-\r
-Returns:\r
-\r
-  Standard EFI status.\r
-  \r
---*/\r
 {\r
   UINT8       *Ptr;\r
   UINT8       *ThunkBase;\r
index 3647a12fae6e602f0f02da82b419749a5363462a..b2cb6f6be060fec430a7c48fd4ac795ee460e49e 100644 (file)
@@ -1,24 +1,17 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
-\r
-  EbcSupport.c\r
-\r
-Abstract:\r
-\r
+/** @file\r
   This module contains EBC support routines that are customized based on\r
   the target processor.\r
 \r
---*/\r
+Copyright (c) 2006, 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
+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
+\r
+**/\r
 \r
 #include "EbcInt.h"\r
 #include "EbcExecute.h"\r
@@ -141,7 +134,7 @@ EbcInterpret (
   // Now adjust the EBC stack pointer down to leave a gap for interpreter\r
   // execution. Then stuff a magic value there.\r
   //\r
-  \r
+\r
   Status = GetEBCStack((EFI_HANDLE)(UINTN)-1, &VmContext.StackPool, &StackIndex);\r
   if (EFI_ERROR(Status)) {\r
     return Status;\r
@@ -151,7 +144,7 @@ EbcInterpret (
   VmContext.HighStackBottom = (UINTN) VmContext.R[0];\r
   VmContext.R[0] -= sizeof (UINTN);\r
 \r
-  \r
+\r
   PushU64 (&VmContext, (UINT64) VM_STACK_KEY_VALUE);\r
   VmContext.StackMagicPtr = (UINTN *) VmContext.R[0];\r
   VmContext.LowStackTop   = (UINTN) VmContext.R[0];\r
@@ -194,32 +187,27 @@ EbcInterpret (
   return (UINT64) VmContext.R[7];\r
 }\r
 \r
-STATIC\r
-UINT64\r
-ExecuteEbcImageEntryPoint (\r
-  IN EFI_HANDLE           ImageHandle,\r
-  IN EFI_SYSTEM_TABLE     *SystemTable\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   IPF implementation.\r
-\r
   Begin executing an EBC image. The address of the entry point is passed\r
   in via a processor register, so we'll need to make a call to get the\r
   value.\r
-  \r
-Arguments:\r
 \r
-  ImageHandle   - image handle for the EBC application we're executing\r
-  SystemTable   - standard system table passed into an driver's entry point\r
+  @param  ImageHandle            image handle for the EBC application we're\r
+                                 executing\r
+  @param  SystemTable            standard system table passed into an driver's\r
+                                 entry point\r
 \r
-Returns:\r
+  @return The value returned by the EBC application we're going to run.\r
 \r
-  The value returned by the EBC application we're going to run.\r
-\r
---*/\r
+**/\r
+STATIC\r
+UINT64\r
+ExecuteEbcImageEntryPoint (\r
+  IN EFI_HANDLE           ImageHandle,\r
+  IN EFI_SYSTEM_TABLE     *SystemTable\r
+  )\r
 {\r
   //\r
   // Create a new VM context on the stack\r
@@ -256,7 +244,7 @@ Returns:
   // Get the stack pointer. This is the bottom of the upper stack.\r
   //\r
   Addr                      = EbcLLGetStackPointer ();\r
-  \r
+\r
   Status = GetEBCStack(ImageHandle, &VmContext.StackPool, &StackIndex);\r
   if (EFI_ERROR(Status)) {\r
     return Status;\r
@@ -266,7 +254,7 @@ Returns:
   VmContext.HighStackBottom = (UINTN) VmContext.R[0];\r
   VmContext.R[0] -= sizeof (UINTN);\r
 \r
-  \r
+\r
   //\r
   // Allocate stack space for the interpreter. Then put a magic value\r
   // at the bottom so we can detect stack corruption.\r
@@ -320,6 +308,19 @@ Returns:
   return (UINT64) VmContext.R[7];\r
 }\r
 \r
+\r
+/**\r
+  Create thunks for an EBC image entry point, or an EBC protocol service.\r
+\r
+  @param  ImageHandle            Image handle for the EBC image. If not null, then\r
+                                 we're creating a thunk for an image entry point.\r
+  @param  EbcEntryPoint          Address of the EBC code that the thunk is to call\r
+  @param  Thunk                  Returned thunk we create here\r
+  @param  Flags                  Flags indicating options for creating the thunk\r
+\r
+  @return Standard EFI status.\r
+\r
+**/\r
 EFI_STATUS\r
 EbcCreateThunks (\r
   IN EFI_HANDLE   ImageHandle,\r
@@ -327,25 +328,6 @@ EbcCreateThunks (
   OUT VOID        **Thunk,\r
   IN  UINT32      Flags\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Create thunks for an EBC image entry point, or an EBC protocol service.\r
-  \r
-Arguments:\r
-\r
-  ImageHandle     - Image handle for the EBC image. If not null, then we're\r
-                    creating a thunk for an image entry point.\r
-  EbcEntryPoint   - Address of the EBC code that the thunk is to call\r
-  Thunk           - Returned thunk we create here\r
-  Flags           - Flags indicating options for creating the thunk\r
-  \r
-Returns:\r
-\r
-  Standard EFI status.\r
-  \r
---*/\r
 {\r
   UINT8       *Ptr;\r
   UINT8       *ThunkBase;\r
@@ -680,6 +662,21 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
+\r
+/**\r
+  Given raw bytes of Itanium based code, format them into a bundle and\r
+  write them out.\r
+\r
+  @param  MemPtr                 pointer to memory location to write the bundles to\r
+  @param  Template               5-bit template\r
+  @param  Slot0-2                instruction slot data for the bundle\r
+\r
+  @retval EFI_INVALID_PARAMETER  Pointer is not aligned\r
+  @retval      No                more than 5 bits in template\r
+  @retval      More              than 41 bits used in code\r
+  @retval EFI_SUCCESS            All data is written.\r
+\r
+**/\r
 STATIC\r
 EFI_STATUS\r
 WriteBundle (\r
@@ -689,27 +686,6 @@ WriteBundle (
   IN    UINT64  Slot1,\r
   IN    UINT64  Slot2\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Given raw bytes of Itanium based code, format them into a bundle and\r
-  write them out.\r
-  \r
-Arguments:\r
-\r
-  MemPtr    - pointer to memory location to write the bundles to\r
-  Template  - 5-bit template\r
-  Slot0-2   - instruction slot data for the bundle\r
-\r
-Returns:\r
-\r
-  EFI_INVALID_PARAMETER - Pointer is not aligned\r
-                        - No more than 5 bits in template\r
-                        - More than 41 bits used in code\r
-  EFI_SUCCESS           - All data is written.\r
-\r
---*/\r
 {\r
   UINT8   *BPtr;\r
   UINT32  Index;\r
@@ -760,38 +736,32 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
-VOID\r
-EbcLLCALLEX (\r
-  IN VM_CONTEXT   *VmPtr,\r
-  IN UINTN        FuncAddr,\r
-  IN UINTN        NewStackPointer,\r
-  IN VOID         *FramePtr,\r
-  IN UINT8        Size\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
-  This function is called to execute an EBC CALLEX instruction. \r
+/**\r
+  This function is called to execute an EBC CALLEX instruction.\r
   The function check the callee's content to see whether it is common native\r
   code or a thunk to another piece of EBC code.\r
   If the callee is common native code, use EbcLLCAllEXASM to manipulate,\r
   otherwise, set the VM->IP to target EBC code directly to avoid another VM\r
   be startup which cost time and stack space.\r
-  \r
-Arguments:\r
 \r
-  VmPtr             - Pointer to a VM context.\r
-  FuncAddr          - Callee's address\r
-  NewStackPointer   - New stack pointer after the call\r
-  FramePtr          - New frame pointer after the call\r
-  Size              - The size of call instruction\r
+  @param  VmPtr                  Pointer to a VM context.\r
+  @param  FuncAddr               Callee's address\r
+  @param  NewStackPointer        New stack pointer after the call\r
+  @param  FramePtr               New frame pointer after the call\r
+  @param  Size                   The size of call instruction\r
 \r
-Returns:\r
+  @return None.\r
 \r
-  None.\r
-  \r
---*/\r
+**/\r
+VOID\r
+EbcLLCALLEX (\r
+  IN VM_CONTEXT   *VmPtr,\r
+  IN UINTN        FuncAddr,\r
+  IN UINTN        NewStackPointer,\r
+  IN VOID         *FramePtr,\r
+  IN UINT8        Size\r
+  )\r
 {\r
   UINTN    IsThunk;\r
   UINTN    TargetEbcAddr;\r
index f6c929ba3ee579fdb0bec572e4d3fcada3d1a9c1..7b554f3e65a7b39b6579801bca8268e11333fea9 100644 (file)
@@ -1,4 +1,5 @@
-/*++\r
+/** @file\r
+  Definition of EBC Support function.\r
 \r
 Copyright (c) 2006, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
@@ -9,17 +10,7 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
-Module Name:\r
-\r
-  EbcSupport.h\r
-\r
-Abstract:\r
-\r
-  Definition of EBC Support function\r
-\r
-Revision History\r
-\r
---*/\r
+**/\r
 \r
 #ifndef _IPF_EBC_SUPPORT_H_\r
 #define _IPF_EBC_SUPPORT_H_\r
index bec82d67c519fd8cdd9fef0ec346cf029386b2a1..90db1669d9a1dc8cddd327ed891c6d6489fe5921 100644 (file)
@@ -1,24 +1,17 @@
-/*++\r
-\r
-Copyright (c) 2006, 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
-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
-\r
-Module Name:\r
-\r
-  EbcSupport.c\r
-\r
-Abstract:\r
-\r
+/** @file\r
   This module contains EBC support routines that are customized based on\r
   the target x64 processor.\r
 \r
---*/\r
+Copyright (c) 2006, 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
+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
+\r
+**/\r
 \r
 #include "EbcInt.h"\r
 #include "EbcExecute.h"\r
@@ -45,7 +38,7 @@ PushU64 (
 Routine Description:\r
 \r
   Push a 64 bit unsigned value to the VM stack.\r
-  \r
+\r
 Arguments:\r
 \r
   VmPtr   -  The pointer to current VM context.\r
@@ -54,7 +47,7 @@ Arguments:
 Returns:\r
 \r
   VOID\r
-  \r
+\r
 --*/\r
 {\r
   //\r
@@ -66,6 +59,19 @@ Returns:
   return;\r
 }\r
 \r
+\r
+/**\r
+  Begin executing an EBC image. The address of the entry point is passed\r
+  in via a processor register, so we'll need to make a call to get the\r
+  value.\r
+\r
+  This is a thunk function. Microsoft x64 compiler only provide fast_call\r
+  calling convention, so the first four arguments are passed by rcx, rdx,\r
+  r8, and r9, while other arguments are passed in stack.\r
+\r
+  @return The value returned by the EBC application we're going to run.\r
+\r
+**/\r
 STATIC\r
 UINT64\r
 EbcInterpret (\r
@@ -86,25 +92,6 @@ EbcInterpret (
   UINTN      Arg15,\r
   UINTN      Arg16\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Begin executing an EBC image. The address of the entry point is passed\r
-  in via a processor register, so we'll need to make a call to get the\r
-  value.\r
-  \r
-Arguments:\r
-\r
-  This is a thunk function. Microsoft x64 compiler only provide fast_call\r
-  calling convention, so the first four arguments are passed by rcx, rdx, \r
-  r8, and r9, while other arguments are passed in stack.\r
-\r
-Returns:\r
-\r
-  The value returned by the EBC application we're going to run.\r
-  \r
---*/\r
 {\r
   //\r
   // Create a new VM context on the stack\r
@@ -140,7 +127,7 @@ Returns:
   //\r
   // Adjust the VM's stack pointer down.\r
   //\r
-  \r
+\r
   Status = GetEBCStack((EFI_HANDLE)(UINTN)-1, &VmContext.StackPool, &StackIndex);\r
   if (EFI_ERROR(Status)) {\r
     return Status;\r
@@ -225,30 +212,25 @@ Returns:
   return (UINT64) VmContext.R[7];\r
 }\r
 \r
-STATIC\r
-UINT64\r
-ExecuteEbcImageEntryPoint (\r
-  IN EFI_HANDLE           ImageHandle,\r
-  IN EFI_SYSTEM_TABLE     *SystemTable\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Begin executing an EBC image. The address of the entry point is passed\r
   in via a processor register, so we'll need to make a call to get the\r
   value.\r
-  \r
-Arguments:\r
 \r
-  ImageHandle   - image handle for the EBC application we're executing\r
-  SystemTable   - standard system table passed into an driver's entry point\r
+  @param  ImageHandle      image handle for the EBC application we're executing\r
+  @param  SystemTable      standard system table passed into an driver's entry\r
+                           point\r
 \r
-Returns:\r
+  @return The value returned by the EBC application we're going to run.\r
 \r
-  The value returned by the EBC application we're going to run.\r
-\r
---*/\r
+**/\r
+STATIC\r
+UINT64\r
+ExecuteEbcImageEntryPoint (\r
+  IN EFI_HANDLE           ImageHandle,\r
+  IN EFI_SYSTEM_TABLE     *SystemTable\r
+  )\r
 {\r
   //\r
   // Create a new VM context on the stack\r
@@ -344,6 +326,17 @@ Returns:
   return (UINT64) VmContext.R[7];\r
 }\r
 \r
+\r
+/**\r
+  Create an IA32 thunk for the given EBC entry point.\r
+\r
+  @param  ImageHandle      Handle of image for which this thunk is being created\r
+  @param  EbcEntryPoint    Address of the EBC code that the thunk is to call\r
+  @param  Thunk            Returned thunk we create here\r
+\r
+  @return Standard EFI status.\r
+\r
+**/\r
 EFI_STATUS\r
 EbcCreateThunks (\r
   IN EFI_HANDLE           ImageHandle,\r
@@ -351,23 +344,6 @@ EbcCreateThunks (
   OUT VOID                **Thunk,\r
   IN  UINT32              Flags\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Create an IA32 thunk for the given EBC entry point.\r
-  \r
-Arguments:\r
-\r
-  ImageHandle     - Handle of image for which this thunk is being created\r
-  EbcEntryPoint   - Address of the EBC code that the thunk is to call\r
-  Thunk           - Returned thunk we create here\r
-\r
-Returns:\r
-\r
-  Standard EFI status.\r
-  \r
---*/\r
 {\r
   UINT8       *Ptr;\r
   UINT8       *ThunkBase;\r
@@ -496,38 +472,32 @@ Returns:
   return EFI_SUCCESS;\r
 }\r
 \r
-VOID\r
-EbcLLCALLEX (\r
-  IN VM_CONTEXT   *VmPtr,\r
-  IN UINTN        FuncAddr,\r
-  IN UINTN        NewStackPointer,\r
-  IN VOID         *FramePtr,\r
-  IN UINT8        Size\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
-  This function is called to execute an EBC CALLEX instruction. \r
+/**\r
+  This function is called to execute an EBC CALLEX instruction.\r
   The function check the callee's content to see whether it is common native\r
   code or a thunk to another piece of EBC code.\r
   If the callee is common native code, use EbcLLCAllEXASM to manipulate,\r
   otherwise, set the VM->IP to target EBC code directly to avoid another VM\r
   be startup which cost time and stack space.\r
-  \r
-Arguments:\r
 \r
-  VmPtr             - Pointer to a VM context.\r
-  FuncAddr          - Callee's address\r
-  NewStackPointer   - New stack pointer after the call\r
-  FramePtr          - New frame pointer after the call\r
-  Size              - The size of call instruction\r
+  @param  VmPtr            Pointer to a VM context.\r
+  @param  FuncAddr         Callee's address\r
+  @param  NewStackPointer  New stack pointer after the call\r
+  @param  FramePtr         New frame pointer after the call\r
+  @param  Size             The size of call instruction\r
 \r
-Returns:\r
+  @return None.\r
 \r
-  None.\r
-  \r
---*/\r
+**/\r
+VOID\r
+EbcLLCALLEX (\r
+  IN VM_CONTEXT   *VmPtr,\r
+  IN UINTN        FuncAddr,\r
+  IN UINTN        NewStackPointer,\r
+  IN VOID         *FramePtr,\r
+  IN UINT8        Size\r
+  )\r
 {\r
   UINTN    IsThunk;\r
   UINTN    TargetEbcAddr;\r
index 31efab323ace8afdb975bb70a71dd3abcc40135b..e97ab9690f0df413baf3b4cc5cbdc196f6a73b35 100644 (file)
@@ -1,6 +1,7 @@
-/*++\r
+/** @file\r
+  Produced the Monotonic Counter Services as defined in the DXE CIS.\r
 \r
-Copyright (c) 2006 - 2007, Intel Corporation\r
+Copyright (c) 2006, 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
@@ -9,17 +10,8 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
-Module Name:\r
-\r
-  MonotonicCounter.c\r
-\r
-Abstract:\r
-\r
-  Produced the Monotonic Counter Services as defined in the DXE CIS\r
-\r
-Revision History:\r
+**/\r
 \r
---*/\r
 \r
 #include "MonotonicCounter.h"\r
 \r
index 42af27249f01ef3d9c95a346f03c4ed9c27b1849..c177f16c76e2079353de9e29495801c2821f4613 100644 (file)
@@ -1,23 +1,16 @@
-/*++\r
+/** @file\r
+  Header file for MonotonicCounter driver.\r
 \r
-Copyright (c) 2006, 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
-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, 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
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Module Name:\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
 \r
-  MonotonicCounter.h\r
-\r
-Abstract:\r
-\r
-  Produces the Monotonic Counter services as defined in the DXE CIS\r
-\r
---*/\r
+**/\r
 \r
 #ifndef _MONOTONIC_COUNTER_DRIVER_H_\r
 #define _MONOTONIC_COUNTER_DRIVER_H_\r
index c246874917b10dabd7e7ad679e1a2d241b2aa17b..fbc2d6687d48a8d92266701dc2204941d086edeb 100644 (file)
@@ -1,4 +1,8 @@
-/*++\r
+/** @file\r
+  This file contains two sets of callback routines for undi3.0 and undi3.1.\r
+  the callback routines for Undi3.1 have an extra parameter UniqueId which\r
+  stores the interface context for the NIC that snp is trying to talk.\r
+\r
 Copyright (c) 2006, 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
@@ -8,16 +12,7 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
-Module name:\r
- callback.c\r
-\r
-Abstract:\r
- This file contains two sets of callback routines for undi3.0 and undi3.1.\r
- the callback routines for Undi3.1 have an extra parameter UniqueId which\r
- stores the interface context for the NIC that snp is trying to talk..\r
-\r
---*/\r
-\r
+**/\r
 \r
 #include "Snp.h"\r
 \r
index b3be2cab40c047527fe43293ff2bd5ea944a8735..576a9a37414ec3accb64d103bb9b430b6dd38483 100644 (file)
@@ -1,6 +1,7 @@
-/*++\r
+/** @file\r
+  Provides Set/Get time operations.\r
 \r
-Copyright (c) 2006 - 2007 Intel Corporation. <BR>\r
+Copyright (c) 2006 - 2007, 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
@@ -9,15 +10,7 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
-\r
-\r
-Module Name:\r
-\r
- Ia32PcRtc.c\r
-\r
-Abstract:\r
-\r
---*/\r
+**/\r
 \r
 #include "PcRtc.h"\r
 \r
@@ -139,9 +132,9 @@ Routine Description:
 \r
   Arguments:\r
 \r
-  \r
 \r
-Returns: \r
+\r
+Returns:\r
 --*/\r
 // GC_TODO:    ImageHandle - add argument and description to function comment\r
 // GC_TODO:    SystemTable - add argument and description to function comment\r
index 91e6b03f0b999ef7f655919c9e939a2bb88b7ca8..f97a2b7e7bf443c4efdd5ef34636b11b7acc219b 100644 (file)
@@ -1,6 +1,7 @@
-/*++\r
+/** @file\r
+  RTC Architectural Protocol GUID as defined in DxeCis 0.96.\r
 \r
-Copyright (c) 2006 - 2007 Intel Corporation. <BR>\r
+Copyright (c) 2006 - 2007, 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
@@ -9,17 +10,7 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
-\r
-\r
-Module Name:\r
-\r
-  PcRtc.c\r
-\r
-Abstract:\r
-\r
-  RTC Architectural Protocol GUID as defined in DxeCis 0.96\r
-\r
---*/\r
+**/\r
 \r
 #include "PcRtc.h"\r
 \r
index 6189daac39108d816b1b18ecd7d85b827085a6b4..b120d09819fc3ce85a21b389837cfecc00cb00a7 100644 (file)
@@ -1,6 +1,7 @@
-/*++\r
+/** @file\r
+  Header file for real time clock driver.\r
 \r
-Copyright (c) 2006 - 2007 Intel Corporation. <BR>\r
+Copyright (c) 2006 - 2007, 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
@@ -9,19 +10,8 @@ http://opensource.org/licenses/bsd-license.php
 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
 \r
+**/\r
 \r
-Module Name:\r
-  \r
-    PcRtc.h\r
-\r
-Abstract:\r
-\r
-    Include for real time clock driver\r
-\r
-Revision History\r
-\r
-\r
---*/\r
 \r
 #ifndef _RTC_H_\r
 #define _RTC_H_\r
index d0ebe8de62ec2469b6836c11d8ed2ddfbf7db8ac..47450d3a09bd95ed6cacf5c0be42c46c45ae25be 100644 (file)
@@ -1,4 +1,5 @@
-/**\r
+/** @file\r
+  Installs Single Segment Pci Configuration PPI.\r
 \r
   Copyright (c) 2006 - 2007, Intel Corporation\r
   All rights reserved. This program and the accompanying materials\r
@@ -27,9 +28,9 @@
 \r
    @param Address   PCI address with\r
                     EFI_PEI_PCI_CFG_PPI_PCI_ADDRESS format.\r
-   \r
+\r
    @return The PCI address with PCI_LIB_ADDRESS format.\r
-   \r
+\r
 **/\r
 STATIC\r
 UINTN\r
@@ -69,7 +70,7 @@ PciCfgAddressConvert (
 \r
 **/\r
 EFI_STATUS\r
-EFIAPI \r
+EFIAPI\r
 PciCfg2Read (\r
   IN CONST  EFI_PEI_SERVICES          **PeiServices,\r
   IN CONST  EFI_PEI_PCI_CFG2_PPI      *This,\r
@@ -103,7 +104,7 @@ PciCfg2Read (
 \r
 **/\r
 EFI_STATUS\r
-EFIAPI \r
+EFIAPI\r
 PciCfg2Write (\r
   IN CONST  EFI_PEI_SERVICES          **PeiServices,\r
   IN CONST  EFI_PEI_PCI_CFG2_PPI      *This,\r
@@ -143,7 +144,7 @@ PciCfg2Write (
 \r
 **/\r
 EFI_STATUS\r
-EFIAPI \r
+EFIAPI\r
 PciCfg2Modify (\r
   IN CONST  EFI_PEI_SERVICES          **PeiServices,\r
   IN CONST  EFI_PEI_PCI_CFG2_PPI      *This,\r
@@ -209,7 +210,7 @@ EFI_PEI_PPI_DESCRIPTOR gPciCfg2PpiList = {
 \r
 **/\r
 EFI_STATUS\r
-EFIAPI \r
+EFIAPI\r
 PciCfg2Read (\r
   IN CONST  EFI_PEI_SERVICES          **PeiServices,\r
   IN CONST  EFI_PEI_PCI_CFG2_PPI      *This,\r
@@ -260,7 +261,7 @@ PciCfg2Read (
 \r
 **/\r
 EFI_STATUS\r
-EFIAPI \r
+EFIAPI\r
 PciCfg2Write (\r
   IN CONST  EFI_PEI_SERVICES          **PeiServices,\r
   IN CONST  EFI_PEI_PCI_CFG2_PPI      *This,\r
@@ -317,7 +318,7 @@ PciCfg2Write (
 \r
 **/\r
 EFI_STATUS\r
-EFIAPI \r
+EFIAPI\r
 PciCfg2Modify (\r
   IN CONST  EFI_PEI_SERVICES          **PeiServices,\r
   IN CONST  EFI_PEI_PCI_CFG2_PPI      *This,\r