]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Include/Library/BaseLib.h
Grammatical and disclaimer changes (does not follow internal C coding stds.)
[mirror_edk2.git] / MdePkg / Include / Library / BaseLib.h
index e63831e059c223a084c38b3c4344c83ac6f8f2fa..b7ec333945d26566ef21dda706ecb23637ba4f4c 100644 (file)
@@ -2,12 +2,12 @@
   Provides string functions, linked list functions, math functions, synchronization\r
   functions, and CPU architecture-specific functions.\r
 \r
-Copyright (c) 2006 - 2008, Intel Corporation<BR>\r
+Copyright (c) 2006 - 2010, Intel Corporation.  All rights reserved<BR>\r
 Portions copyright (c) 2008-2009 Apple Inc. All rights reserved.<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
+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
@@ -22,7 +22,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 //\r
 #if   defined (MDE_CPU_IA32)\r
 ///\r
-/// IA-32 architecture context buffer used by SetJump() and LongJump()\r
+/// The IA-32 architecture context buffer used by SetJump() and LongJump().\r
 ///\r
 typedef struct {\r
   UINT32                            Ebx;\r
@@ -40,7 +40,7 @@ typedef struct {
 #if defined (MDE_CPU_IPF)\r
 \r
 ///\r
-/// Itanium architecture context buffer used by SetJump() and LongJump()\r
+/// The Itanium architecture context buffer used by SetJump() and LongJump().\r
 ///\r
 typedef struct {\r
   UINT64                            F2[2];\r
@@ -89,7 +89,7 @@ typedef struct {
 \r
 #if defined (MDE_CPU_X64)\r
 ///\r
-/// x64 architecture context buffer used by SetJump() and LongJump()\r
+/// The x64 architecture context buffer used by SetJump() and LongJump().\r
 ///\r
 typedef struct {\r
   UINT64                            Rbx;\r
@@ -103,7 +103,7 @@ typedef struct {
   UINT64                            R15;\r
   UINT64                            Rip;\r
   UINT64                            MxCsr;\r
-  UINT8                             XmmBuffer[160]; ///< XMM6-XMM15\r
+  UINT8                             XmmBuffer[160]; ///< XMM6-XMM15.\r
 } BASE_LIBRARY_JUMP_BUFFER;\r
 \r
 #define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 8\r
@@ -112,7 +112,7 @@ typedef struct {
 \r
 #if defined (MDE_CPU_EBC)\r
 ///\r
-/// EBC context buffer used by SetJump() and LongJump()\r
+/// The EBC context buffer used by SetJump() and LongJump().\r
 ///\r
 typedef struct {\r
   UINT64                            R0;\r
@@ -129,7 +129,7 @@ typedef struct {
 #if defined (MDE_CPU_ARM)\r
 \r
 typedef struct {\r
-  UINT32    R3;  ///< Copy of R13\r
+  UINT32    R3;  ///< A copy of R13.\r
   UINT32    R4;\r
   UINT32    R5;\r
   UINT32    R6;\r
@@ -167,8 +167,8 @@ typedef struct {
   PcdMaximumUnicodeStringLength Unicode characters not including the\r
   Null-terminator, then ASSERT().\r
 \r
-  @param  Destination Pointer to a Null-terminated Unicode string.\r
-  @param  Source      Pointer to a Null-terminated Unicode string.\r
+  @param  Destination The pointer to a Null-terminated Unicode string.\r
+  @param  Source      The pointer to a Null-terminated Unicode string.\r
 \r
   @return Destination.\r
 \r
@@ -182,7 +182,7 @@ StrCpy (
 \r
 \r
 /**\r
-  Copies up to a specified length from one Null-terminated Unicode string  to \r
+  Copies up to a specified length from one Null-terminated Unicode string to \r
   another Null-terminated Unicode string and returns the new Unicode string.\r
 \r
   This function copies the contents of the Unicode string Source to the Unicode\r
@@ -204,9 +204,9 @@ StrCpy (
   PcdMaximumUnicodeStringLength Unicode characters, not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  Destination Pointer to a Null-terminated Unicode string.\r
-  @param  Source      Pointer to a Null-terminated Unicode string.\r
-  @param  Length      Maximum number of Unicode characters to copy.\r
+  @param  Destination The pointer to a Null-terminated Unicode string.\r
+  @param  Source      The pointer to a Null-terminated Unicode string.\r
+  @param  Length      The maximum number of Unicode characters to copy.\r
 \r
   @return Destination.\r
 \r
@@ -257,7 +257,7 @@ StrLen (
   PcdMaximumUnicodeStringLength Unicode characters not including the\r
   Null-terminator, then ASSERT().\r
 \r
-  @param  String  Pointer to a Null-terminated Unicode string.\r
+  @param  String  The pointer to a Null-terminated Unicode string.\r
 \r
   @return The size of String.\r
 \r
@@ -287,11 +287,11 @@ StrSize (
   than PcdMaximumUnicodeStringLength Unicode characters not including the\r
   Null-terminator, then ASSERT().\r
   If PcdMaximumUnicodeStringLength is not zero, and SecondString contains more\r
-  than PcdMaximumUnicodeStringLength Unicode characters not including the\r
+  than PcdMaximumUnicodeStringLength Unicode characters, not including the\r
   Null-terminator, then ASSERT().\r
 \r
-  @param  FirstString   Pointer to a Null-terminated Unicode string.\r
-  @param  SecondString  Pointer to a Null-terminated Unicode string.\r
+  @param  FirstString   The pointer to a Null-terminated Unicode string.\r
+  @param  SecondString  The pointer to a Null-terminated Unicode string.\r
 \r
   @retval 0      FirstString is identical to SecondString.\r
   @return others FirstString is not identical to SecondString.\r
@@ -329,9 +329,9 @@ StrCmp (
   PcdMaximumUnicodeStringLength Unicode characters, not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  FirstString   Pointer to a Null-terminated Unicode string.\r
-  @param  SecondString  Pointer to a Null-terminated Unicode string.\r
-  @param  Length        Maximum number of Unicode characters to compare.\r
+  @param  FirstString   The pointer to a Null-terminated Unicode string.\r
+  @param  SecondString  The pointer to a Null-terminated Unicode string.\r
+  @param  Length        The maximum number of Unicode characters to compare.\r
 \r
   @retval 0      FirstString is identical to SecondString.\r
   @return others FirstString is not identical to SecondString.\r
@@ -362,18 +362,18 @@ StrnCmp (
   If Source is not aligned on a 16-bit boundary, then ASSERT().\r
   If Source and Destination overlap, then ASSERT().\r
   If PcdMaximumUnicodeStringLength is not zero, and Destination contains more\r
-  than PcdMaximumUnicodeStringLength Unicode characters not including the\r
+  than PcdMaximumUnicodeStringLength Unicode characters, not including the\r
   Null-terminator, then ASSERT().\r
   If PcdMaximumUnicodeStringLength is not zero, and Source contains more than\r
-  PcdMaximumUnicodeStringLength Unicode characters not including the\r
+  PcdMaximumUnicodeStringLength Unicode characters, not including the\r
   Null-terminator, then ASSERT().\r
   If PcdMaximumUnicodeStringLength is not zero, and concatenating Destination\r
   and Source results in a Unicode string with more than\r
-  PcdMaximumUnicodeStringLength Unicode characters not including the\r
+  PcdMaximumUnicodeStringLength Unicode characters, not including the\r
   Null-terminator, then ASSERT().\r
 \r
-  @param  Destination Pointer to a Null-terminated Unicode string.\r
-  @param  Source      Pointer to a Null-terminated Unicode string.\r
+  @param  Destination The pointer to a Null-terminated Unicode string.\r
+  @param  Source      The pointer to a Null-terminated Unicode string.\r
 \r
   @return Destination.\r
 \r
@@ -416,9 +416,9 @@ StrCat (
   and Source results in a Unicode string with more than PcdMaximumUnicodeStringLength\r
   Unicode characters, not including the Null-terminator, then ASSERT().\r
 \r
-  @param  Destination Pointer to a Null-terminated Unicode string.\r
-  @param  Source      Pointer to a Null-terminated Unicode string.\r
-  @param  Length      Maximum number of Unicode characters to concatenate from\r
+  @param  Destination The pointer to a Null-terminated Unicode string.\r
+  @param  Source      The pointer to a Null-terminated Unicode string.\r
+  @param  Length      The maximum number of Unicode characters to concatenate from\r
                       Source.\r
 \r
   @return Destination.\r
@@ -439,8 +439,7 @@ StrnCat (
   This function scans the contents of the Null-terminated Unicode string\r
   specified by String and returns the first occurrence of SearchString.\r
   If SearchString is not found in String, then NULL is returned.  If\r
-  the length of SearchString is zero, then String is\r
-  returned.\r
+  the length of SearchString is zero, then String is returned.\r
 \r
   If String is NULL, then ASSERT().\r
   If String is not aligned on a 16-bit boundary, then ASSERT().\r
@@ -449,10 +448,10 @@ StrnCat (
 \r
   If PcdMaximumUnicodeStringLength is not zero, and SearchString\r
   or String contains more than PcdMaximumUnicodeStringLength Unicode\r
-  characters not including the Null-terminator, then ASSERT().\r
+  characters, not including the Null-terminator, then ASSERT().\r
 \r
-  @param  String          Pointer to a Null-terminated Unicode string.\r
-  @param  SearchString    Pointer to a Null-terminated Unicode string to search for.\r
+  @param  String          The pointer to a Null-terminated Unicode string.\r
+  @param  SearchString    The pointer to a Null-terminated Unicode string to search for.\r
 \r
   @retval NULL            If the SearchString does not appear in String.\r
   @return others          If there is a match.\r
@@ -494,7 +493,7 @@ StrStr (
   more than PcdMaximumUnicodeStringLength Unicode characters not including\r
   the Null-terminator, then ASSERT().\r
 \r
-  @param  String      Pointer to a Null-terminated Unicode string.\r
+  @param  String      The pointer to a Null-terminated Unicode string.\r
 \r
   @retval Value translated from String.\r
 \r
@@ -534,7 +533,7 @@ StrDecimalToUintn (
   more than PcdMaximumUnicodeStringLength Unicode characters not including\r
   the Null-terminator, then ASSERT().\r
 \r
-  @param  String          Pointer to a Null-terminated Unicode string.\r
+  @param  String          The pointer to a Null-terminated Unicode string.\r
 \r
   @retval Value translated from String.\r
 \r
@@ -561,8 +560,8 @@ StrDecimalToUint64 (
   The function will ignore the pad space, which includes spaces or tab characters,\r
   before [zeros], [x] or [hexadecimal digit]. The running zero before [x] or\r
   [hexadecimal digit] will be ignored. Then, the decoding starts after [x] or the\r
-  first valid hexadecimal digit. Then, the function stops at the first character that is\r
-  a not a valid hexadecimal character or NULL, whichever one comes first.\r
+  first valid hexadecimal digit. Then, the function stops at the first character \r
+  that is a not a valid hexadecimal character or NULL, whichever one comes first.\r
 \r
   If String is NULL, then ASSERT().\r
   If String is not aligned in a 16-bit boundary, then ASSERT().\r
@@ -576,7 +575,7 @@ StrDecimalToUint64 (
   PcdMaximumUnicodeStringLength Unicode characters not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  String          Pointer to a Null-terminated Unicode string.\r
+  @param  String          The pointer to a Null-terminated Unicode string.\r
 \r
   @retval Value translated from String.\r
 \r
@@ -618,7 +617,7 @@ StrHexToUintn (
   PcdMaximumUnicodeStringLength Unicode characters not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  String          Pointer to a Null-terminated Unicode string.\r
+  @param  String          The pointer to a Null-terminated Unicode string.\r
 \r
   @retval Value translated from String.\r
 \r
@@ -653,8 +652,8 @@ StrHexToUint64 (
   than PcdMaximumAsciiStringLength Unicode characters not including the\r
   Null-terminator, then ASSERT().\r
 \r
-  @param  Source        Pointer to a Null-terminated Unicode string.\r
-  @param  Destination   Pointer to a Null-terminated ASCII string.\r
+  @param  Source        The pointer to a Null-terminated Unicode string.\r
+  @param  Destination   The pointer to a Null-terminated ASCII string.\r
 \r
   @return Destination.\r
 \r
@@ -682,8 +681,8 @@ UnicodeStrToAsciiStr (
   PcdMaximumAsciiStringLength ASCII characters not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  Destination Pointer to a Null-terminated ASCII string.\r
-  @param  Source      Pointer to a Null-terminated ASCII string.\r
+  @param  Destination The pointer to a Null-terminated ASCII string.\r
+  @param  Source      The pointer to a Null-terminated ASCII string.\r
 \r
   @return Destination\r
 \r
@@ -716,9 +715,9 @@ AsciiStrCpy (
   PcdMaximumAsciiStringLength ASCII characters, not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  Destination Pointer to a Null-terminated ASCII string.\r
-  @param  Source      Pointer to a Null-terminated ASCII string.\r
-  @param  Length      Maximum number of ASCII characters to copy.\r
+  @param  Destination The pointer to a Null-terminated ASCII string.\r
+  @param  Source      The pointer to a Null-terminated ASCII string.\r
+  @param  Length      The maximum number of ASCII characters to copy.\r
 \r
   @return Destination\r
 \r
@@ -744,7 +743,7 @@ AsciiStrnCpy (
   PcdMaximumAsciiStringLength ASCII characters not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  String  Pointer to a Null-terminated ASCII string.\r
+  @param  String  The pointer to a Null-terminated ASCII string.\r
 \r
   @return The length of String.\r
 \r
@@ -768,7 +767,7 @@ AsciiStrLen (
   PcdMaximumAsciiStringLength ASCII characters not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  String  Pointer to a Null-terminated ASCII string.\r
+  @param  String  The pointer to a Null-terminated ASCII string.\r
 \r
   @return The size of String.\r
 \r
@@ -799,8 +798,8 @@ AsciiStrSize (
   than PcdMaximumAsciiStringLength ASCII characters not including the\r
   Null-terminator, then ASSERT().\r
 \r
-  @param  FirstString   Pointer to a Null-terminated ASCII string.\r
-  @param  SecondString  Pointer to a Null-terminated ASCII string.\r
+  @param  FirstString   The pointer to a Null-terminated ASCII string.\r
+  @param  SecondString  The pointer to a Null-terminated ASCII string.\r
 \r
   @retval ==0      FirstString is identical to SecondString.\r
   @retval !=0      FirstString is not identical to SecondString.\r
@@ -834,8 +833,8 @@ AsciiStrCmp (
   than PcdMaximumAsciiStringLength ASCII characters not including the\r
   Null-terminator, then ASSERT().\r
 \r
-  @param  FirstString   Pointer to a Null-terminated ASCII string.\r
-  @param  SecondString  Pointer to a Null-terminated ASCII string.\r
+  @param  FirstString   The pointer to a Null-terminated ASCII string.\r
+  @param  SecondString  The pointer to a Null-terminated ASCII string.\r
 \r
   @retval ==0    FirstString is identical to SecondString using case insensitive\r
                  comparisons.\r
@@ -873,9 +872,9 @@ AsciiStriCmp (
   PcdMaximumAsciiStringLength ASCII characters, not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  FirstString   Pointer to a Null-terminated ASCII string.\r
-  @param  SecondString  Pointer to a Null-terminated ASCII string.\r
-  @param  Length        Maximum number of ASCII characters for compare.\r
+  @param  FirstString   The pointer to a Null-terminated ASCII string.\r
+  @param  SecondString  The pointer to a Null-terminated ASCII string.\r
+  @param  Length        The maximum number of ASCII characters for compare.\r
   \r
   @retval ==0       FirstString is identical to SecondString.\r
   @retval !=0       FirstString is not identical to SecondString.\r
@@ -911,8 +910,8 @@ AsciiStrnCmp (
   Source results in a ASCII string with more than PcdMaximumAsciiStringLength\r
   ASCII characters, then ASSERT().\r
 \r
-  @param  Destination Pointer to a Null-terminated ASCII string.\r
-  @param  Source      Pointer to a Null-terminated ASCII string.\r
+  @param  Destination The pointer to a Null-terminated ASCII string.\r
+  @param  Source      The pointer to a Null-terminated ASCII string.\r
 \r
   @return Destination\r
 \r
@@ -953,9 +952,9 @@ AsciiStrCat (
   Source results in a ASCII string with more than PcdMaximumAsciiStringLength\r
   ASCII characters, not including the Null-terminator, then ASSERT().\r
 \r
-  @param  Destination Pointer to a Null-terminated ASCII string.\r
-  @param  Source      Pointer to a Null-terminated ASCII string.\r
-  @param  Length      Maximum number of ASCII characters to concatenate from\r
+  @param  Destination The pointer to a Null-terminated ASCII string.\r
+  @param  Source      The pointer to a Null-terminated ASCII string.\r
+  @param  Length      The maximum number of ASCII characters to concatenate from\r
                       Source.\r
 \r
   @return Destination\r
@@ -986,8 +985,8 @@ AsciiStrnCat (
   String contains more than PcdMaximumAsciiStringLength Unicode characters\r
   not including the Null-terminator, then ASSERT().\r
 \r
-  @param  String          Pointer to a Null-terminated ASCII string.\r
-  @param  SearchString    Pointer to a Null-terminated ASCII string to search for.\r
+  @param  String          The pointer to a Null-terminated ASCII string.\r
+  @param  SearchString    The pointer to a Null-terminated ASCII string to search for.\r
 \r
   @retval NULL            If the SearchString does not appear in String.\r
   @retval others          If there is a match return the first occurrence of SearchingString.\r
@@ -1027,9 +1026,9 @@ AsciiStrStr (
   PcdMaximumAsciiStringLength ASCII characters not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  String          Pointer to a Null-terminated ASCII string.\r
+  @param  String          The pointer to a Null-terminated ASCII string.\r
 \r
-  @retval Value translated from String.\r
+  @retval The value translated from String.\r
 \r
 **/\r
 UINTN\r
@@ -1064,7 +1063,7 @@ AsciiStrDecimalToUintn (
   PcdMaximumAsciiStringLength ASCII characters not including the Null-terminator,\r
   then ASSERT().\r
 \r
-  @param  String          Pointer to a Null-terminated ASCII string.\r
+  @param  String          The pointer to a Null-terminated ASCII string.\r
 \r
   @retval Value translated from String.\r
 \r
@@ -1105,7 +1104,7 @@ AsciiStrDecimalToUint64 (
   and String contains more than PcdMaximumAsciiStringLength ASCII characters not including\r
   the Null-terminator, then ASSERT().\r
 \r
-  @param  String          Pointer to a Null-terminated ASCII string.\r
+  @param  String          The pointer to a Null-terminated ASCII string.\r
 \r
   @retval Value translated from String.\r
 \r
@@ -1146,7 +1145,7 @@ AsciiStrHexToUintn (
   and String contains more than PcdMaximumAsciiStringLength ASCII characters not including\r
   the Null-terminator, then ASSERT().\r
 \r
-  @param  String          Pointer to a Null-terminated ASCII string.\r
+  @param  String          The pointer to a Null-terminated ASCII string.\r
 \r
   @retval Value translated from String.\r
 \r
@@ -1179,8 +1178,8 @@ AsciiStrHexToUint64 (
   PcdMaximumUnicodeStringLength ASCII characters not including the\r
   Null-terminator, then ASSERT().\r
 \r
-  @param  Source        Pointer to a Null-terminated ASCII string.\r
-  @param  Destination   Pointer to a Null-terminated Unicode string.\r
+  @param  Source        The pointer to a Null-terminated ASCII string.\r
+  @param  Destination   The pointer to a Null-terminated Unicode string.\r
 \r
   @return Destination.\r
 \r
@@ -1383,7 +1382,7 @@ GetFirstNode (
   @param  List  A pointer to the head node of a doubly linked list.\r
   @param  Node  A pointer to a node in the doubly linked list.\r
 \r
-  @return Pointer to the next node if one exists. Otherwise List is returned.\r
+  @return The pointer to the next node if one exists. Otherwise List is returned.\r
 \r
 **/\r
 LIST_ENTRY *\r
@@ -1412,7 +1411,7 @@ GetNextNode (
   @param  List  A pointer to the head node of a doubly linked list.\r
   @param  Node  A pointer to a node in the doubly linked list.\r
  \r
-  @return Pointer to the previous node if one exists. Otherwise List is returned.\r
+  @return The pointer to the previous node if one exists. Otherwise List is returned.\r
  \r
 **/\r
 LIST_ENTRY *\r
@@ -1868,7 +1867,7 @@ GetPowerOfTwo64 (
 \r
 \r
 /**\r
-  Switches the endianess of a 16-bit integer.\r
+  Switches the endianness of a 16-bit integer.\r
 \r
   This function swaps the bytes in a 16-bit unsigned value to switch the value\r
   from little endian to big endian or vice versa. The byte swapped value is\r
@@ -1887,7 +1886,7 @@ SwapBytes16 (
 \r
 \r
 /**\r
-  Switches the endianess of a 32-bit integer.\r
+  Switches the endianness of a 32-bit integer.\r
 \r
   This function swaps the bytes in a 32-bit unsigned value to switch the value\r
   from little endian to big endian or vice versa. The byte swapped value is\r
@@ -1906,7 +1905,7 @@ SwapBytes32 (
 \r
 \r
 /**\r
-  Switches the endianess of a 64-bit integer.\r
+  Switches the endianness of a 64-bit integer.\r
 \r
   This function swaps the bytes in a 64-bit unsigned value to switch the value\r
   from little endian to big endian or vice versa. The byte swapped value is\r
@@ -1957,7 +1956,7 @@ MultU64x32 (
   @param  Multiplicand  A 64-bit unsigned value.\r
   @param  Multiplier    A 64-bit unsigned value.\r
 \r
-  @return Multiplicand * Multiplier\r
+  @return Multiplicand * Multiplier.\r
 \r
 **/\r
 UINT64\r
@@ -2003,7 +2002,7 @@ MultS64x64 (
   @param  Dividend  A 64-bit unsigned value.\r
   @param  Divisor   A 32-bit unsigned value.\r
 \r
-  @return Dividend / Divisor\r
+  @return Dividend / Divisor.\r
 \r
 **/\r
 UINT64\r
@@ -2027,7 +2026,7 @@ DivU64x32 (
   @param  Dividend  A 64-bit unsigned value.\r
   @param  Divisor   A 32-bit unsigned value.\r
 \r
-  @return Dividend % Divisor\r
+  @return Dividend % Divisor.\r
 \r
 **/\r
 UINT32\r
@@ -2054,7 +2053,7 @@ ModU64x32 (
   @param  Remainder A pointer to a 32-bit unsigned value. This parameter is\r
                     optional and may be NULL.\r
 \r
-  @return Dividend / Divisor\r
+  @return Dividend / Divisor.\r
 \r
 **/\r
 UINT64\r
@@ -2082,7 +2081,7 @@ DivU64x32Remainder (
   @param  Remainder A pointer to a 64-bit unsigned value. This parameter is\r
                     optional and may be NULL.\r
 \r
-  @return Dividend / Divisor\r
+  @return Dividend / Divisor.\r
 \r
 **/\r
 UINT64\r
@@ -2114,7 +2113,7 @@ DivU64x64Remainder (
   @param  Remainder A pointer to a 64-bit signed value. This parameter is\r
                     optional and may be NULL.\r
 \r
-  @return Dividend / Divisor\r
+  @return Dividend / Divisor.\r
 \r
 **/\r
 INT64\r
@@ -2134,7 +2133,7 @@ DivS64x64Remainder (
 \r
   If the Buffer is NULL, then ASSERT().\r
 \r
-  @param  Buffer  Pointer to a 16-bit value that may be unaligned.\r
+  @param  Buffer  The pointer to a 16-bit value that may be unaligned.\r
 \r
   @return The 16-bit value read from Buffer.\r
 \r
@@ -2155,7 +2154,7 @@ ReadUnaligned16 (
 \r
   If the Buffer is NULL, then ASSERT().\r
 \r
-  @param  Buffer  Pointer to a 16-bit value that may be unaligned.\r
+  @param  Buffer  The pointer to a 16-bit value that may be unaligned.\r
   @param  Value   16-bit value to write to Buffer.\r
 \r
   @return The 16-bit value to write to Buffer.\r
@@ -2177,7 +2176,7 @@ WriteUnaligned16 (
 \r
   If the Buffer is NULL, then ASSERT().\r
 \r
-  @param  Buffer  Pointer to a 24-bit value that may be unaligned.\r
+  @param  Buffer  The pointer to a 24-bit value that may be unaligned.\r
 \r
   @return The 24-bit value read from Buffer.\r
 \r
@@ -2198,7 +2197,7 @@ ReadUnaligned24 (
 \r
   If the Buffer is NULL, then ASSERT().\r
 \r
-  @param  Buffer  Pointer to a 24-bit value that may be unaligned.\r
+  @param  Buffer  The pointer to a 24-bit value that may be unaligned.\r
   @param  Value   24-bit value to write to Buffer.\r
 \r
   @return The 24-bit value to write to Buffer.\r
@@ -2220,7 +2219,7 @@ WriteUnaligned24 (
 \r
   If the Buffer is NULL, then ASSERT().\r
 \r
-  @param  Buffer  Pointer to a 32-bit value that may be unaligned.\r
+  @param  Buffer  The pointer to a 32-bit value that may be unaligned.\r
 \r
   @return The 32-bit value read from Buffer.\r
 \r
@@ -2241,7 +2240,7 @@ ReadUnaligned32 (
 \r
   If the Buffer is NULL, then ASSERT().\r
 \r
-  @param  Buffer  Pointer to a 32-bit value that may be unaligned.\r
+  @param  Buffer  The pointer to a 32-bit value that may be unaligned.\r
   @param  Value   32-bit value to write to Buffer.\r
 \r
   @return The 32-bit value to write to Buffer.\r
@@ -2263,7 +2262,7 @@ WriteUnaligned32 (
 \r
   If the Buffer is NULL, then ASSERT().\r
 \r
-  @param  Buffer  Pointer to a 64-bit value that may be unaligned.\r
+  @param  Buffer  The pointer to a 64-bit value that may be unaligned.\r
 \r
   @return The 64-bit value read from Buffer.\r
 \r
@@ -2284,7 +2283,7 @@ ReadUnaligned64 (
 \r
   If the Buffer is NULL, then ASSERT().\r
 \r
-  @param  Buffer  Pointer to a 64-bit value that may be unaligned.\r
+  @param  Buffer  The pointer to a 64-bit value that may be unaligned.\r
   @param  Value   64-bit value to write to Buffer.\r
 \r
   @return The 64-bit value to write to Buffer.\r
@@ -2704,7 +2703,7 @@ BitFieldWrite32 (
                     Range 0..31.\r
   @param  EndBit    The ordinal of the most significant bit in the bit field.\r
                     Range 0..31.\r
-  @param  OrData    The value to OR with the read value from the value\r
+  @param  OrData    The value to OR with the read value from the value.\r
 \r
   @return The new 32-bit value.\r
 \r
@@ -2965,7 +2964,7 @@ BitFieldAndThenOr64 (
   If Buffer is NULL, then ASSERT().\r
   If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().\r
 \r
-  @param  Buffer      Pointer to the buffer to carry out the sum operation.\r
+  @param  Buffer      The pointer to the buffer to carry out the sum operation.\r
   @param  Length      The size, in bytes, of Buffer.\r
 \r
   @return Sum         The sum of Buffer with carry bits dropped during additions.\r
@@ -2991,10 +2990,10 @@ CalculateSum8 (
   If Buffer is NULL, then ASSERT().\r
   If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().\r
 \r
-  @param  Buffer      Pointer to the buffer to carry out the checksum operation.\r
+  @param  Buffer      The pointer to the buffer to carry out the checksum operation.\r
   @param  Length      The size, in bytes, of Buffer.\r
 \r
-  @return Checksum    The 2's complement checksum of Buffer.\r
+  @return Checksum    The two's complement checksum of Buffer.\r
 \r
 **/\r
 UINT8\r
@@ -3018,7 +3017,7 @@ CalculateCheckSum8 (
   If Length is not aligned on a 16-bit boundary, then ASSERT().\r
   If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().\r
 \r
-  @param  Buffer      Pointer to the buffer to carry out the sum operation.\r
+  @param  Buffer      The pointer to the buffer to carry out the sum operation.\r
   @param  Length      The size, in bytes, of Buffer.\r
 \r
   @return Sum         The sum of Buffer with carry bits dropped during additions.\r
@@ -3046,10 +3045,10 @@ CalculateSum16 (
   If Length is not aligned on a 16-bit boundary, then ASSERT().\r
   If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().\r
 \r
-  @param  Buffer      Pointer to the buffer to carry out the checksum operation.\r
+  @param  Buffer      The pointer to the buffer to carry out the checksum operation.\r
   @param  Length      The size, in bytes, of Buffer.\r
 \r
-  @return Checksum    The 2's complement checksum of Buffer.\r
+  @return Checksum    The two's complement checksum of Buffer.\r
 \r
 **/\r
 UINT16\r
@@ -3073,7 +3072,7 @@ CalculateCheckSum16 (
   If Length is not aligned on a 32-bit boundary, then ASSERT().\r
   If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().\r
 \r
-  @param  Buffer      Pointer to the buffer to carry out the sum operation.\r
+  @param  Buffer      The pointer to the buffer to carry out the sum operation.\r
   @param  Length      The size, in bytes, of Buffer.\r
 \r
   @return Sum         The sum of Buffer with carry bits dropped during additions.\r
@@ -3101,10 +3100,10 @@ CalculateSum32 (
   If Length is not aligned on a 32-bit boundary, then ASSERT().\r
   If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().\r
 \r
-  @param  Buffer      Pointer to the buffer to carry out the checksum operation.\r
+  @param  Buffer      The pointer to the buffer to carry out the checksum operation.\r
   @param  Length      The size, in bytes, of Buffer.\r
 \r
-  @return Checksum    The 2's complement checksum of Buffer.\r
+  @return Checksum    The two's complement checksum of Buffer.\r
 \r
 **/\r
 UINT32\r
@@ -3128,7 +3127,7 @@ CalculateCheckSum32 (
   If Length is not aligned on a 64-bit boundary, then ASSERT().\r
   If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().\r
 \r
-  @param  Buffer      Pointer to the buffer to carry out the sum operation.\r
+  @param  Buffer      The pointer to the buffer to carry out the sum operation.\r
   @param  Length      The size, in bytes, of Buffer.\r
 \r
   @return Sum         The sum of Buffer with carry bits dropped during additions.\r
@@ -3156,10 +3155,10 @@ CalculateSum64 (
   If Length is not aligned on a 64-bit boundary, then ASSERT().\r
   If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().\r
 \r
-  @param  Buffer      Pointer to the buffer to carry out the checksum operation.\r
+  @param  Buffer      The pointer to the buffer to carry out the checksum operation.\r
   @param  Length      The size, in bytes, of Buffer.\r
 \r
-  @return Checksum    The 2's complement checksum of Buffer.\r
+  @return Checksum    The two's complement checksum of Buffer.\r
 \r
 **/\r
 UINT64\r
@@ -3307,7 +3306,7 @@ EnableDisableInterrupts (
 /**\r
   Retrieves the current CPU interrupt state.\r
 \r
-  Returns TRUE is interrupts are currently enabled. Otherwise\r
+  Returns TRUE if interrupts are currently enabled. Otherwise\r
   returns FALSE.\r
 \r
   @retval TRUE  CPU interrupts are enabled.\r
@@ -3378,10 +3377,10 @@ CpuPause (
                       function.\r
   @param  NewStack    A pointer to the new stack to use for the EntryPoint\r
                       function.\r
-  @param  ...         This variable argument list is ignored for IA-32, x64, and EBC architectures.  \r
-                      For Itanium processors, this variable argument list is expected to contain \r
-                      a single parameter of type VOID * that specifies the new backing \r
-                      store pointer.\r
+  @param  ...         This variable argument list is ignored for IA-32, x64, and \r
+                      EBC architectures.  For Itanium processors, this variable \r
+                      argument list is expected to contain a single parameter of \r
+                      type VOID * that specifies the new backing store pointer.\r
 \r
 \r
 **/\r
@@ -3460,8 +3459,8 @@ AsmFlushCacheRange (
 \r
 \r
 /**\r
-  Executes a FC instruction\r
-  Executes a FC instruction on the cache line specified by Address.\r
+  Executes an FC instruction.\r
+  Executes an FC instruction on the cache line specified by Address.\r
   The cache line size affected is at least 32-bytes (aligned on a 32-byte boundary).\r
   An implementation may flush a larger region.  This function is only available on Itanium processors.\r
 \r
@@ -3478,14 +3477,14 @@ AsmFc (
 \r
 \r
 /**\r
-  Executes a FC.I instruction.\r
-  Executes a FC.I instruction on the cache line specified by Address.\r
+  Executes an FC.I instruction.\r
+  Executes an FC.I instruction on the cache line specified by Address.\r
   The cache line size affected is at least 32-bytes (aligned on a 32-byte boundary).\r
   An implementation may flush a larger region.  This function is only available on Itanium processors.\r
 \r
   @param Address    The Address of cache line to be flushed.\r
 \r
-  @return The address of FC.I instruction executed.\r
+  @return The address of the FC.I instruction executed.\r
 \r
 **/\r
 UINT64\r
@@ -4351,7 +4350,7 @@ AsmWriteLrr1 (
   \r
   The Instruction Breakpoint Registers are used in pairs.  The even numbered\r
   registers contain breakpoint addresses, and the odd numbered registers contain\r
-  breakpoint mask conditions.  At least 4 instruction registers pairs are implemented\r
+  breakpoint mask conditions.  At least four instruction registers pairs are implemented\r
   on all processor models.   Implemented registers are contiguous starting with\r
   register 0.  No parameter checking is performed on Index, and if the Index value\r
   is beyond the implemented IBR register range, a Reserved Register/Field fault may\r
@@ -4376,7 +4375,7 @@ AsmReadIbr (
 \r
   The Data Breakpoint Registers are used in pairs.  The even numbered registers\r
   contain breakpoint addresses, and odd numbered registers contain breakpoint\r
-  mask conditions.  At least 4 data registers pairs are implemented on all processor\r
+  mask conditions.  At least four data registers pairs are implemented on all processor\r
   models.  Implemented registers are contiguous starting with register 0.\r
   No parameter checking is performed on Index.  If the Index value is beyond\r
   the implemented DBR register range, a Reserved Register/Field fault may occur.\r
@@ -4399,8 +4398,8 @@ AsmReadDbr (
 /**\r
   Reads the current value of Performance Monitor Configuration Register (PMC).\r
 \r
-  All processor implementations provide at least 4 performance counters\r
-  (PMC/PMD [4]...PMC/PMD [7] pairs), and 4 performance monitor counter overflow\r
+  All processor implementations provide at least four performance counters\r
+  (PMC/PMD [4]...PMC/PMD [7] pairs), and four performance monitor counter overflow\r
   status registers (PMC [0]... PMC [3]).  Processor implementations may provide\r
   additional implementation-dependent PMC and PMD to increase the number of\r
   'generic' performance counters (PMC/PMD pairs).  The remainder of PMC and PMD\r
@@ -4453,7 +4452,7 @@ AsmReadPmd (
   Writes current value of Instruction Breakpoint Register specified by Index.\r
   The Instruction Breakpoint Registers are used in pairs.  The even numbered\r
   registers contain breakpoint addresses, and odd numbered registers contain\r
-  breakpoint mask conditions.  At least 4 instruction registers pairs are implemented\r
+  breakpoint mask conditions.  At least four instruction registers pairs are implemented\r
   on all processor models.  Implemented registers are contiguous starting with\r
   register 0.  No parameter checking is performed on Index.  If the Index value\r
   is beyond the implemented IBR register range, a Reserved Register/Field fault may\r
@@ -4481,7 +4480,7 @@ AsmWriteIbr (
   Writes current value of Data Breakpoint Register specified by Index.\r
   The Data Breakpoint Registers are used in pairs.  The even numbered registers\r
   contain breakpoint addresses, and odd numbered registers contain breakpoint\r
-  mask conditions.  At least 4 data registers pairs are implemented on all processor\r
+  mask conditions.  At least four data registers pairs are implemented on all processor\r
   models.  Implemented registers are contiguous starting with register 0.  No parameter\r
   checking is performed on Index.  If the Index value is beyond the implemented\r
   DBR register range, a Reserved Register/Field fault may occur.  The caller must\r
@@ -4507,8 +4506,8 @@ AsmWriteDbr (
   Writes the current value of 64-bit Performance Monitor Configuration Register (PMC).\r
 \r
   Writes current value of Performance Monitor Configuration Register specified by Index.\r
-  All processor implementations provide at least 4 performance counters\r
-  (PMC/PMD [4]...PMC/PMD [7] pairs), and 4 performance monitor counter overflow status\r
+  All processor implementations provide at least four performance counters\r
+  (PMC/PMD [4]...PMC/PMD [7] pairs), and four performance monitor counter overflow status\r
   registers (PMC [0]... PMC [3]).  Processor implementations may provide additional\r
   implementation-dependent PMC and PMD to increase the number of 'generic' performance\r
   counters (PMC/PMD pairs).  The remainder of PMC and PMD register set is implementation\r
@@ -4534,8 +4533,8 @@ AsmWritePmc (
   Writes the current value of 64-bit Performance Monitor Data Register (PMD).\r
 \r
   Writes current value of Performance Monitor Data Register specified by Index.\r
-  All processor implementations provide at least 4 performance counters\r
-  (PMC/PMD [4]...PMC/PMD [7] pairs), and 4 performance monitor counter overflow\r
+  All processor implementations provide at least four performance counters\r
+  (PMC/PMD [4]...PMC/PMD [7] pairs), and four performance monitor counter overflow\r
   status registers (PMC [0]... PMC [3]).  Processor implementations may provide\r
   additional implementation-dependent PMC and PMD to increase the number of 'generic'\r
   performance counters (PMC/PMD pairs).  The remainder of PMC and PMD register set\r
@@ -4609,7 +4608,7 @@ AsmReadSp (
 \r
 \r
 ///\r
-/// Valid Index value for AsmReadControlRegister()\r
+/// Valid Index value for AsmReadControlRegister().\r
 ///\r
 #define IPF_CONTROL_REGISTER_DCR   0\r
 #define IPF_CONTROL_REGISTER_ITM   1\r
@@ -4641,9 +4640,10 @@ AsmReadSp (
 /**\r
   Reads a 64-bit control register.\r
 \r
-  Reads and returns the control register specified by Index. The valid Index valued are defined\r
-  above in "Related Definitions".\r
-  If Index is invalid then 0xFFFFFFFFFFFFFFFF is returned.  This function is only available on Itanium processors.\r
+  Reads and returns the control register specified by Index. The valid Index valued \r
+  are defined above in "Related Definitions".\r
+  If Index is invalid then 0xFFFFFFFFFFFFFFFF is returned.  This function is only \r
+  available on Itanium processors.\r
 \r
   @param  Index                     The index of the control register to read.\r
 \r
@@ -4658,7 +4658,7 @@ AsmReadControlRegister (
 \r
 \r
 ///\r
-/// Valid Index value for AsmReadApplicationRegister()\r
+/// Valid Index value for AsmReadApplicationRegister().\r
 ///\r
 #define IPF_APPLICATION_REGISTER_K0        0\r
 #define IPF_APPLICATION_REGISTER_K1        1\r
@@ -4691,9 +4691,10 @@ AsmReadControlRegister (
 /**\r
   Reads a 64-bit application register.\r
 \r
-  Reads and returns the application register specified by Index. The valid Index valued are defined\r
-  above in "Related Definitions".\r
-  If Index is invalid then 0xFFFFFFFFFFFFFFFF is returned.  This function is only available on Itanium processors.\r
+  Reads and returns the application register specified by Index. The valid Index \r
+  valued are defined above in "Related Definitions".\r
+  If Index is invalid then 0xFFFFFFFFFFFFFFFF is returned.  This function is only \r
+  available on Itanium processors.\r
 \r
   @param  Index                     The index of the application register to read.\r
 \r
@@ -4817,119 +4818,119 @@ AsmPalCall (
 \r
 #if defined (MDE_CPU_IA32) || defined (MDE_CPU_X64)\r
 ///\r
-/// IA32 and x64 Specific Functions\r
-/// Byte packed structure for 16-bit Real Mode EFLAGS\r
+/// IA32 and x64 Specific Functions.\r
+/// Byte packed structure for 16-bit Real Mode EFLAGS.\r
 ///\r
 typedef union {\r
   struct {\r
-    UINT32  CF:1;           ///< Carry Flag\r
-    UINT32  Reserved_0:1;   ///< Reserved\r
-    UINT32  PF:1;           ///< Parity Flag\r
-    UINT32  Reserved_1:1;   ///< Reserved\r
-    UINT32  AF:1;           ///< Auxiliary Carry Flag\r
-    UINT32  Reserved_2:1;   ///< Reserved\r
-    UINT32  ZF:1;           ///< Zero Flag\r
-    UINT32  SF:1;           ///< Sign Flag\r
-    UINT32  TF:1;           ///< Trap Flag\r
-    UINT32  IF:1;           ///< Interrupt Enable Flag\r
-    UINT32  DF:1;           ///< Direction Flag\r
-    UINT32  OF:1;           ///< Overflow Flag\r
-    UINT32  IOPL:2;         ///< I/O Privilege Level\r
-    UINT32  NT:1;           ///< Nested Task\r
-    UINT32  Reserved_3:1;   ///< Reserved\r
+    UINT32  CF:1;           ///< Carry Flag.\r
+    UINT32  Reserved_0:1;   ///< Reserved.\r
+    UINT32  PF:1;           ///< Parity Flag.\r
+    UINT32  Reserved_1:1;   ///< Reserved.\r
+    UINT32  AF:1;           ///< Auxiliary Carry Flag.\r
+    UINT32  Reserved_2:1;   ///< Reserved.\r
+    UINT32  ZF:1;           ///< Zero Flag.\r
+    UINT32  SF:1;           ///< Sign Flag.\r
+    UINT32  TF:1;           ///< Trap Flag.\r
+    UINT32  IF:1;           ///< Interrupt Enable Flag.\r
+    UINT32  DF:1;           ///< Direction Flag.\r
+    UINT32  OF:1;           ///< Overflow Flag.\r
+    UINT32  IOPL:2;         ///< I/O Privilege Level.\r
+    UINT32  NT:1;           ///< Nested Task.\r
+    UINT32  Reserved_3:1;   ///< Reserved.\r
   } Bits;\r
   UINT16    Uint16;\r
 } IA32_FLAGS16;\r
 \r
 ///\r
-/// Byte packed structure for EFLAGS/RFLAGS\r
-/// 32-bits on IA-32\r
-/// 64-bits on x64.  The upper 32-bits on x64 are reserved\r
+/// Byte packed structure for EFLAGS/RFLAGS.\r
+/// 32-bits on IA-32.\r
+/// 64-bits on x64.  The upper 32-bits on x64 are reserved.\r
 ///\r
 typedef union {\r
   struct {\r
-    UINT32  CF:1;           ///< Carry Flag\r
-    UINT32  Reserved_0:1;   ///< Reserved\r
-    UINT32  PF:1;           ///< Parity Flag\r
-    UINT32  Reserved_1:1;   ///< Reserved\r
-    UINT32  AF:1;           ///< Auxiliary Carry Flag\r
-    UINT32  Reserved_2:1;   ///< Reserved\r
-    UINT32  ZF:1;           ///< Zero Flag\r
-    UINT32  SF:1;           ///< Sign Flag\r
-    UINT32  TF:1;           ///< Trap Flag\r
-    UINT32  IF:1;           ///< Interrupt Enable Flag\r
-    UINT32  DF:1;           ///< Direction Flag\r
-    UINT32  OF:1;           ///< Overflow Flag\r
-    UINT32  IOPL:2;         ///< I/O Privilege Level\r
-    UINT32  NT:1;           ///< Nested Task\r
-    UINT32  Reserved_3:1;   ///< Reserved\r
-    UINT32  RF:1;           ///< Resume Flag\r
-    UINT32  VM:1;           ///< Virtual 8086 Mode\r
-    UINT32  AC:1;           ///< Alignment Check\r
-    UINT32  VIF:1;          ///< Virtual Interrupt Flag\r
-    UINT32  VIP:1;          ///< Virtual Interrupt Pending\r
-    UINT32  ID:1;           ///< ID Flag\r
-    UINT32  Reserved_4:10;  ///< Reserved\r
+    UINT32  CF:1;           ///< Carry Flag.\r
+    UINT32  Reserved_0:1;   ///< Reserved.\r
+    UINT32  PF:1;           ///< Parity Flag.\r
+    UINT32  Reserved_1:1;   ///< Reserved.\r
+    UINT32  AF:1;           ///< Auxiliary Carry Flag.\r
+    UINT32  Reserved_2:1;   ///< Reserved.\r
+    UINT32  ZF:1;           ///< Zero Flag.\r
+    UINT32  SF:1;           ///< Sign Flag.\r
+    UINT32  TF:1;           ///< Trap Flag.\r
+    UINT32  IF:1;           ///< Interrupt Enable Flag.\r
+    UINT32  DF:1;           ///< Direction Flag.\r
+    UINT32  OF:1;           ///< Overflow Flag.\r
+    UINT32  IOPL:2;         ///< I/O Privilege Level.\r
+    UINT32  NT:1;           ///< Nested Task.\r
+    UINT32  Reserved_3:1;   ///< Reserved.\r
+    UINT32  RF:1;           ///< Resume Flag.\r
+    UINT32  VM:1;           ///< Virtual 8086 Mode.\r
+    UINT32  AC:1;           ///< Alignment Check.\r
+    UINT32  VIF:1;          ///< Virtual Interrupt Flag.\r
+    UINT32  VIP:1;          ///< Virtual Interrupt Pending.\r
+    UINT32  ID:1;           ///< ID Flag.\r
+    UINT32  Reserved_4:10;  ///< Reserved.\r
   } Bits;\r
   UINTN     UintN;\r
 } IA32_EFLAGS32;\r
 \r
 ///\r
-/// Byte packed structure for Control Register 0 (CR0)\r
-/// 32-bits on IA-32\r
-/// 64-bits on x64.  The upper 32-bits on x64 are reserved\r
+/// Byte packed structure for Control Register 0 (CR0).\r
+/// 32-bits on IA-32.\r
+/// 64-bits on x64.  The upper 32-bits on x64 are reserved.\r
 ///\r
 typedef union {\r
   struct {\r
-    UINT32  PE:1;           ///< Protection Enable\r
-    UINT32  MP:1;           ///< Monitor Coprocessor\r
-    UINT32  EM:1;           ///< Emulation\r
-    UINT32  TS:1;           ///< Task Switched\r
-    UINT32  ET:1;           ///< Extension Type\r
-    UINT32  NE:1;           ///< Numeric Error\r
-    UINT32  Reserved_0:10;  ///< Reserved\r
-    UINT32  WP:1;           ///< Write Protect\r
-    UINT32  Reserved_1:1;   ///< Reserved\r
-    UINT32  AM:1;           ///< Alignment Mask\r
-    UINT32  Reserved_2:10;  ///< Reserved\r
-    UINT32  NW:1;           ///< Mot Write-through\r
-    UINT32  CD:1;           ///< Cache Disable\r
-    UINT32  PG:1;           ///< Paging\r
+    UINT32  PE:1;           ///< Protection Enable.\r
+    UINT32  MP:1;           ///< Monitor Coprocessor.\r
+    UINT32  EM:1;           ///< Emulation.\r
+    UINT32  TS:1;           ///< Task Switched.\r
+    UINT32  ET:1;           ///< Extension Type.\r
+    UINT32  NE:1;           ///< Numeric Error.\r
+    UINT32  Reserved_0:10;  ///< Reserved.\r
+    UINT32  WP:1;           ///< Write Protect.\r
+    UINT32  Reserved_1:1;   ///< Reserved.\r
+    UINT32  AM:1;           ///< Alignment Mask.\r
+    UINT32  Reserved_2:10;  ///< Reserved.\r
+    UINT32  NW:1;           ///< Mot Write-through.\r
+    UINT32  CD:1;           ///< Cache Disable.\r
+    UINT32  PG:1;           ///< Paging.\r
   } Bits;\r
   UINTN     UintN;\r
 } IA32_CR0;\r
 \r
 ///\r
-/// Byte packed structure for Control Register 4 (CR4)\r
-/// 32-bits on IA-32\r
-/// 64-bits on x64.  The upper 32-bits on x64 are reserved\r
+/// Byte packed structure for Control Register 4 (CR4).\r
+/// 32-bits on IA-32.\r
+/// 64-bits on x64.  The upper 32-bits on x64 are reserved.\r
 ///\r
 typedef union {\r
   struct {\r
-    UINT32  VME:1;          ///< Virtual-8086 Mode Extensions\r
-    UINT32  PVI:1;          ///< Protected-Mode Virtual Interrupts\r
-    UINT32  TSD:1;          ///< Time Stamp Disable\r
-    UINT32  DE:1;           ///< Debugging Extensions\r
-    UINT32  PSE:1;          ///< Page Size Extensions\r
-    UINT32  PAE:1;          ///< Physical Address Extension\r
-    UINT32  MCE:1;          ///< Machine Check Enable\r
-    UINT32  PGE:1;          ///< Page Global Enable\r
+    UINT32  VME:1;          ///< Virtual-8086 Mode Extensions.\r
+    UINT32  PVI:1;          ///< Protected-Mode Virtual Interrupts.\r
+    UINT32  TSD:1;          ///< Time Stamp Disable.\r
+    UINT32  DE:1;           ///< Debugging Extensions.\r
+    UINT32  PSE:1;          ///< Page Size Extensions.\r
+    UINT32  PAE:1;          ///< Physical Address Extension.\r
+    UINT32  MCE:1;          ///< Machine Check Enable.\r
+    UINT32  PGE:1;          ///< Page Global Enable.\r
     UINT32  PCE:1;          ///< Performance Monitoring Counter\r
-                            ///< Enable\r
+                            ///< Enable.\r
     UINT32  OSFXSR:1;       ///< Operating System Support for\r
                             ///< FXSAVE and FXRSTOR instructions\r
     UINT32  OSXMMEXCPT:1;   ///< Operating System Support for\r
                             ///< Unmasked SIMD Floating Point\r
-                            ///< Exceptions\r
-    UINT32  Reserved_0:2;   ///< Reserved\r
+                            ///< Exceptions.\r
+    UINT32  Reserved_0:2;   ///< Reserved.\r
     UINT32  VMXE:1;         ///< VMX Enable\r
-    UINT32  Reserved_1:18;  ///< Reserved\r
+    UINT32  Reserved_1:18;  ///< Reserved.\r
   } Bits;\r
   UINTN     UintN;\r
 } IA32_CR4;\r
 \r
 ///\r
-/// Byte packed structure for an IDTR, GDTR, LDTR descriptor\r
+/// Byte packed structure for an IDTR, GDTR, LDTR descriptor.\r
 ///\r
 #pragma pack (1)\r
 typedef struct {\r
@@ -4947,15 +4948,15 @@ typedef struct {
 \r
 #if defined (MDE_CPU_IA32)\r
 ///\r
-/// Byte packed structure for an IA-32 Interrupt Gate Descriptor\r
+/// Byte packed structure for an IA-32 Interrupt Gate Descriptor.\r
 ///\r
 typedef union {\r
   struct {\r
-    UINT32  OffsetLow:16;   ///< Offset bits 15..0\r
-    UINT32  Selector:16;    ///< Selector\r
-    UINT32  Reserved_0:8;   ///< Reserved\r
-    UINT32  GateType:8;     ///< Gate Type.  See #defines above\r
-    UINT32  OffsetHigh:16;  ///< Offset bits 31..16\r
+    UINT32  OffsetLow:16;   ///< Offset bits 15..0.\r
+    UINT32  Selector:16;    ///< Selector.\r
+    UINT32  Reserved_0:8;   ///< Reserved.\r
+    UINT32  GateType:8;     ///< Gate Type.  See #defines above.\r
+    UINT32  OffsetHigh:16;  ///< Offset bits 31..16.\r
   } Bits;\r
   UINT64  Uint64;\r
 } IA32_IDT_GATE_DESCRIPTOR;\r
@@ -4964,17 +4965,17 @@ typedef union {
 \r
 #if defined (MDE_CPU_X64)\r
 ///\r
-/// Byte packed structure for an x64 Interrupt Gate Descriptor\r
+/// Byte packed structure for an x64 Interrupt Gate Descriptor.\r
 ///\r
 typedef union {\r
   struct {\r
-    UINT32  OffsetLow:16;   ///< Offset bits 15..0\r
-    UINT32  Selector:16;    ///< Selector\r
-    UINT32  Reserved_0:8;   ///< Reserved\r
-    UINT32  GateType:8;     ///< Gate Type.  See #defines above\r
-    UINT32  OffsetHigh:16;  ///< Offset bits 31..16\r
-    UINT32  OffsetUpper:32; ///< Offset bits 63..32\r
-    UINT32  Reserved_1:32;  ///< Reserved\r
+    UINT32  OffsetLow:16;   ///< Offset bits 15..0.\r
+    UINT32  Selector:16;    ///< Selector.\r
+    UINT32  Reserved_0:8;   ///< Reserved.\r
+    UINT32  GateType:8;     ///< Gate Type.  See #defines above.\r
+    UINT32  OffsetHigh:16;  ///< Offset bits 31..16.\r
+    UINT32  OffsetUpper:32; ///< Offset bits 63..32.\r
+    UINT32  Reserved_1:32;  ///< Reserved.\r
   } Bits;\r
   struct {\r
     UINT64  Uint64;\r
@@ -4985,14 +4986,14 @@ typedef union {
 #endif\r
 \r
 ///\r
-/// Byte packed structure for an FP/SSE/SSE2 context\r
+/// Byte packed structure for an FP/SSE/SSE2 context.\r
 ///\r
 typedef struct {\r
   UINT8  Buffer[512];\r
 } IA32_FX_BUFFER;\r
 \r
 ///\r
-/// Structures for the 16-bit real mode thunks\r
+/// Structures for the 16-bit real mode thunks.\r
 ///\r
 typedef struct {\r
   UINT32                            Reserved1;\r
@@ -5058,7 +5059,7 @@ typedef union {
 } IA32_REGISTER_SET;\r
 \r
 ///\r
-/// Byte packed structure for an 16-bit real mode thunks\r
+/// Byte packed structure for an 16-bit real mode thunks.\r
 ///\r
 typedef struct {\r
   IA32_REGISTER_SET                 *RealModeState;\r
@@ -5084,13 +5085,13 @@ typedef struct {
 \r
   @param  Index The 32-bit value to load into EAX prior to invoking the CPUID\r
                 instruction.\r
-  @param  Eax   Pointer to the 32-bit EAX value returned by the CPUID\r
+  @param  Eax   The pointer to the 32-bit EAX value returned by the CPUID\r
                 instruction. This is an optional parameter that may be NULL.\r
-  @param  Ebx   Pointer to the 32-bit EBX value returned by the CPUID\r
+  @param  Ebx   The pointer to the 32-bit EBX value returned by the CPUID\r
                 instruction. This is an optional parameter that may be NULL.\r
-  @param  Ecx   Pointer to the 32-bit ECX value returned by the CPUID\r
+  @param  Ecx   The pointer to the 32-bit ECX value returned by the CPUID\r
                 instruction. This is an optional parameter that may be NULL.\r
-  @param  Edx   Pointer to the 32-bit EDX value returned by the CPUID\r
+  @param  Edx   The pointer to the 32-bit EDX value returned by the CPUID\r
                 instruction. This is an optional parameter that may be NULL.\r
 \r
   @return Index.\r
@@ -5123,16 +5124,16 @@ AsmCpuid (
                     CPUID instruction.\r
   @param  SubIndex  The 32-bit value to load into ECX prior to invoking the\r
                     CPUID instruction.\r
-  @param  Eax       Pointer to the 32-bit EAX value returned by the CPUID\r
+  @param  Eax       The pointer to the 32-bit EAX value returned by the CPUID\r
                     instruction. This is an optional parameter that may be\r
                     NULL.\r
-  @param  Ebx       Pointer to the 32-bit EBX value returned by the CPUID\r
+  @param  Ebx       The pointer to the 32-bit EBX value returned by the CPUID\r
                     instruction. This is an optional parameter that may be\r
                     NULL.\r
-  @param  Ecx       Pointer to the 32-bit ECX value returned by the CPUID\r
+  @param  Ecx       The pointer to the 32-bit ECX value returned by the CPUID\r
                     instruction. This is an optional parameter that may be\r
                     NULL.\r
-  @param  Edx       Pointer to the 32-bit EDX value returned by the CPUID\r
+  @param  Edx       The pointer to the 32-bit EDX value returned by the CPUID\r
                     instruction. This is an optional parameter that may be\r
                     NULL.\r
 \r
@@ -6347,7 +6348,7 @@ AsmReadTr (
 \r
   If Gdtr is NULL, then ASSERT().\r
 \r
-  @param  Gdtr  Pointer to a GDTR descriptor.\r
+  @param  Gdtr  The pointer to a GDTR descriptor.\r
 \r
 **/\r
 VOID\r
@@ -6365,7 +6366,7 @@ AsmReadGdtr (
 \r
   If Gdtr is NULL, then ASSERT().\r
 \r
-  @param  Gdtr  Pointer to a GDTR descriptor.\r
+  @param  Gdtr  The pointer to a GDTR descriptor.\r
 \r
 **/\r
 VOID\r
@@ -6383,7 +6384,7 @@ AsmWriteGdtr (
 \r
   If Idtr is NULL, then ASSERT().\r
 \r
-  @param  Idtr  Pointer to a IDTR descriptor.\r
+  @param  Idtr  The pointer to a IDTR descriptor.\r
 \r
 **/\r
 VOID\r
@@ -6401,7 +6402,7 @@ AsmReadIdtr (
 \r
   If Idtr is NULL, then ASSERT().\r
 \r
-  @param  Idtr  Pointer to a IDTR descriptor.\r
+  @param  Idtr  The pointer to a IDTR descriptor.\r
 \r
 **/\r
 VOID\r
@@ -6453,7 +6454,7 @@ AsmWriteLdtr (
   If Buffer is NULL, then ASSERT().\r
   If Buffer is not aligned on a 16-byte boundary, then ASSERT().\r
 \r
-  @param  Buffer  Pointer to a buffer to save the floating point/SSE/SSE2 context.\r
+  @param  Buffer  The pointer to a buffer to save the floating point/SSE/SSE2 context.\r
 \r
 **/\r
 VOID\r
@@ -6474,7 +6475,7 @@ AsmFxSave (
   If Buffer is not aligned on a 16-byte boundary, then ASSERT().\r
   If Buffer was not saved with AsmFxSave(), then ASSERT().\r
 \r
-  @param  Buffer  Pointer to a buffer to save the floating point/SSE/SSE2 context.\r
+  @param  Buffer  The pointer to a buffer to save the floating point/SSE/SSE2 context.\r
 \r
 **/\r
 VOID\r
@@ -6862,7 +6863,7 @@ AsmInvd (
                         addressing mode, then LinearAddress is a virtual\r
                         address.\r
 \r
-  @return LinearAddress\r
+  @return LinearAddress.\r
 **/\r
 VOID *\r
 EFIAPI\r
@@ -7147,7 +7148,7 @@ AsmPrepareThunk16 (
   ThunkAttributes, then ASSERT().\r
 \r
   This interface is limited to be used in either physical mode or virtual modes with paging enabled where the\r
-  virtual to physical mappings for ThunkContext.RealModeBuffer is mapped 1:1.\r
+  virtual to physical mappings for ThunkContext.RealModeBuffer are mapped 1:1.\r
 \r
   @param  ThunkContext  A pointer to the context structure that describes the\r
                         16-bit real mode code to call.\r