]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Library/SmmPeriodicSmiLib/SmmPeriodicSmiLib.c
MdePkg/Library/Smm: Fix various typos
[mirror_edk2.git] / MdePkg / Library / SmmPeriodicSmiLib / SmmPeriodicSmiLib.c
index ba01910b696bd1ddee5ee20ab9dee1ff549f5990..8b1e780b76db0cbccffc0ec34c94ee55586c814f 100644 (file)
@@ -107,8 +107,8 @@ typedef struct {
   UINT64                                   DispatchTotalTime;\r
   ///\r
   /// The performance counter value that was captured the last time that the\r
-  /// periodic SMI handler called PeriodcSmiExecutionTime().  This allows the\r
-  /// time value returned by PeriodcSmiExecutionTime() to be accurate even when\r
+  /// periodic SMI handler called PeriodicSmiExecutionTime().  This allows the\r
+  /// time value returned by PeriodicSmiExecutionTime() to be accurate even when\r
   /// the performance counter rolls over.\r
   ///\r
   UINT64                                   DispatchCheckPointTime;\r
@@ -127,7 +127,7 @@ typedef struct {
   ///\r
   /// Buffer used to save the context when a periodic SMI handler requests to\r
   /// yield using PeriodicSmiYield().  This context is used to resume the\r
-  /// execution of a periodic SMI handler the next time control is transferd\r
+  /// execution of a periodic SMI handler the next time control is transferred\r
   /// to the periodic SMI handler that yielded.\r
   ///\r
   BASE_LIBRARY_JUMP_BUFFER                 YieldJumpBuffer;\r
@@ -152,7 +152,7 @@ typedef struct {
     )\r
 \r
 ///\r
-/// Pointer to the SMM Periodic Timer Disatch Protocol that was located in the constuctor.\r
+/// Pointer to the SMM Periodic Timer Dispatch Protocol that was located in the constructor.\r
 ///\r
 EFI_SMM_PERIODIC_TIMER_DISPATCH2_PROTOCOL  *gSmmPeriodicTimerDispatch2           = NULL;\r
 \r
@@ -522,7 +522,7 @@ PeriodicSmiExit (
   This function yields control back to the SMM Foundation.  When the next\r
   periodic SMI for the currently executing handler is triggered, the periodic\r
   SMI handler will be resumed and this function will return.  Use of this\r
-  function requires a seperate stack for the periodic SMI handler.  A non zero\r
+  function requires a separate stack for the periodic SMI handler.  A non zero\r
   stack size must be specified in PeriodicSmiEnable() for this function to be\r
   used.\r
 \r
@@ -572,7 +572,7 @@ PeriodicSmiYield (
   SetJumpFlag = SetJump (&PeriodicSmiLibraryHandler->YieldJumpBuffer);\r
   if (SetJumpFlag == 0) {\r
     //\r
-    // The intial call to SetJump() always returns 0.\r
+    // The initial call to SetJump() always returns 0.\r
     // If this is the initial call, then exit the current periodic SMI handler\r
     //\r
     PeriodicSmiExit ();\r
@@ -588,7 +588,7 @@ PeriodicSmiYield (
   PeriodicSmiLibraryHandler->YieldFlag = FALSE;\r
 \r
   //\r
-  // Return the amount elapsed time that occured while yielded\r
+  // Return the amount elapsed time that occurred while yielded\r
   //\r
   return PeriodicSmiLibraryHandler->ElapsedTime;\r
 }\r
@@ -620,7 +620,7 @@ PeriodicSmiDispatchFunctionSwitchStack (
   //\r
   // Dispatch the registered handler passing in the context that was registered\r
   // and the amount of time that has elapsed since the previous time this\r
-  // periodic SMI handler was dispacthed.\r
+  // periodic SMI handler was dispatched.\r
   //\r
   PeriodicSmiLibraryHandler->DispatchFunction (\r
     PeriodicSmiLibraryHandler->Context,\r
@@ -628,16 +628,16 @@ PeriodicSmiDispatchFunctionSwitchStack (
     );\r
 \r
   //\r
-  // If this DispatchFunction() returns, then unconditially call PeriodicSmiExit()\r
+  // If this DispatchFunction() returns, then unconditionally call PeriodicSmiExit()\r
   // to perform a LongJump() back to PeriodicSmiDispatchFunctionOnCpu(). The\r
-  // LongJump() will resume exection on the original stack.\r
+  // LongJump() will resume execution on the original stack.\r
   //\r
   PeriodicSmiExit ();\r
 }\r
 \r
 /**\r
   Internal worker function that transfers control to an enabled periodic SMI\r
-  handler on the specified logial CPU.  This function determines if the periodic\r
+  handler on the specified logical CPU.  This function determines if the periodic\r
   SMI handler yielded and needs to be resumed.  It also and switches to an\r
   allocated stack if one was allocated in PeriodicSmiEnable().\r
 \r
@@ -652,9 +652,9 @@ PeriodicSmiDispatchFunctionOnCpu (
   )\r
 {\r
   //\r
-  // Save context in DispatchJumpBuffer.  The intial call to SetJump() always\r
+  // Save context in DispatchJumpBuffer.  The initial call to SetJump() always\r
   // returns 0.  If this is the initial call, then either resume from a prior\r
-  // call to PeriodicSmiYield() or call the DispatchFunction registerd in\r
+  // call to PeriodicSmiYield() or call the DispatchFunction registered in\r
   // PeriodicSmiEnable() using an allocated stack if one was specified.\r
   //\r
   if (SetJump (&PeriodicSmiLibraryHandler->DispatchJumpBuffer) != 0) {\r
@@ -679,7 +679,7 @@ PeriodicSmiDispatchFunctionOnCpu (
     //\r
     // If Stack is NULL then call DispatchFunction using current stack passing\r
     // in the context that was registered and the amount of time that has\r
-    // elapsed since the previous time this periodic SMI handler was dispacthed.\r
+    // elapsed since the previous time this periodic SMI handler was dispatched.\r
     //\r
     PeriodicSmiLibraryHandler->DispatchFunction (\r
       PeriodicSmiLibraryHandler->Context,\r
@@ -687,7 +687,7 @@ PeriodicSmiDispatchFunctionOnCpu (
       );\r
 \r
     //\r
-    // If this DispatchFunction() returns, then unconditially call PeriodicSmiExit()\r
+    // If this DispatchFunction() returns, then unconditionally call PeriodicSmiExit()\r
     // to perform a LongJump() back to this function.\r
     //\r
     PeriodicSmiExit ();\r
@@ -712,7 +712,7 @@ PeriodicSmiDispatchFunctionOnCpu (
 \r
 /**\r
   Internal worker function that transfers control to an enabled periodic SMI\r
-  handler on the specified logial CPU.  This worker function is only called\r
+  handler on the specified logical CPU.  This worker function is only called\r
   using the SMM Services Table function SmmStartupThisAp() to execute the\r
   periodic SMI handler on a logical CPU that is different than the one that is\r
   running the SMM Foundation.  When the periodic SMI handler returns, a lock is\r
@@ -736,7 +736,7 @@ PeriodicSmiDispatchFunctionWithLock (
   PeriodicSmiLibraryHandler = (PERIODIC_SMI_LIBRARY_HANDLER_CONTEXT  *)Buffer;\r
 \r
   //\r
-  // Execute dispatch function on the currently excuting logical CPU\r
+  // Execute dispatch function on the currently executing logical CPU\r
   //\r
   PeriodicSmiDispatchFunctionOnCpu (PeriodicSmiLibraryHandler);\r
 \r
@@ -805,7 +805,7 @@ PeriodicSmiDispatchFunction (
       (PeriodicSmiLibraryHandler->Cpu == gSmst->CurrentlyExecutingCpu)    ) {\r
     //\r
     // Dispatch on the currently execution CPU if the CPU specified in PeriodicSmiEnable()\r
-    // was PERIODIC_SMI_LIBARRY_ANY_CPU or the currently executing CPU matches the CPU\r
+    // was PERIODIC_SMI_LIBRARY_ANY_CPU or the currently executing CPU matches the CPU\r
     // that was specified in PeriodicSmiEnable().\r
     //\r
     PeriodicSmiDispatchFunctionOnCpu (PeriodicSmiLibraryHandler);\r
@@ -867,7 +867,7 @@ PeriodicSmiDispatchFunction (
   @param[in]     DispatchFunction  A pointer to a periodic SMI handler function.\r
   @param[in]     Context           Optional content to pass into DispatchFunction.\r
   @param[in]     TickPeriod        The requested tick period in 100ns units that\r
-                                   control should be givien to the periodic SMI\r
+                                   control should be given to the periodic SMI\r
                                    handler.  Must be one of the supported values\r
                                    returned by PeriodicSmiSupportedPickPeriod().\r
   @param[in]     Cpu               Specifies the CPU that is required to execute\r
@@ -891,7 +891,7 @@ PeriodicSmiDispatchFunction (
   @retval EFI_OUT_OF_RESOURCES   There are not enough resources to enable the\r
                                  periodic SMI handler.\r
   @retval EFI_OUT_OF_RESOURCES   There are not enough resources to allocate the\r
-                                 stack speficied by StackSize.\r
+                                 stack specified by StackSize.\r
   @retval EFI_SUCCESS            The periodic SMI handler was enabled.\r
 \r
 **/\r
@@ -1077,7 +1077,7 @@ SmmPeriodicSmiLibConstructor (
 \r
   //\r
   // Count the number of periodic SMI tick intervals that the SMM Periodic Timer\r
-  // Dipatch 2 Protocol supports.\r
+  // Dispatch 2 Protocol supports.\r
   //\r
   SmiTickInterval = NULL;\r
   Count = 0;\r