]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Core/Dxe/Event/event.c
Add doxygen style comments for functions in DxeMain.
[mirror_edk2.git] / MdeModulePkg / Core / Dxe / Event / event.c
index 13949169a0079e3cc8a4b5756d505059ca1a4b34..f5ffbb7d4df3d4eadad764c1bf5efd1caff0baeb 100644 (file)
@@ -62,74 +62,47 @@ UINT32 mEventTable[] = {
   EVT_TIMER | EVT_NOTIFY_WAIT,\r
 };\r
 \r
+\r
+/**\r
+  Enter critical section by acquiring the lock on gEventQueueLock.\r
+\r
+**/\r
 STATIC\r
 VOID\r
 CoreAcquireEventLock (\r
   VOID\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Enter critical section by acquiring the lock on gEventQueueLock.\r
-\r
-Arguments:\r
-\r
-  None\r
-\r
-Returns:\r
-\r
-  None\r
-\r
---*/\r
 {\r
   CoreAcquireLock (&gEventQueueLock);\r
 }\r
 \r
+\r
+/**\r
+  Exit critical section by releasing the lock on gEventQueueLock.\r
+\r
+**/\r
 STATIC\r
 VOID\r
 CoreReleaseEventLock (\r
   VOID\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Exit critical section by releasing the lock on gEventQueueLock.\r
-\r
-Arguments:\r
-\r
-  None\r
-\r
-Returns:\r
-\r
-  None\r
-\r
---*/\r
 {\r
   CoreReleaseLock (&gEventQueueLock);\r
 }\r
 \r
 \r
-EFI_STATUS\r
-CoreInitializeEventServices (\r
-  VOID\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Initializes "event" support and populates parts of the System and Runtime Table.\r
 \r
-Arguments:\r
-\r
-  None\r
-\r
-Returns:\r
 \r
-  EFI_SUCCESS - Always return success\r
+  @retval EFI_SUCCESS            Always return success\r
 \r
---*/\r
+**/\r
+EFI_STATUS\r
+CoreInitializeEventServices (\r
+  VOID\r
+  )\r
 {\r
   UINTN        Index;\r
 \r
@@ -143,25 +116,18 @@ Returns:
 }\r
 \r
 \r
-VOID\r
-CoreDispatchEventNotifies (\r
-  IN EFI_TPL      Priority\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Dispatches all pending events.\r
 \r
-Arguments:\r
-\r
-  Priority - The task priority level of event notifications to dispatch\r
+  @param  Priority               The task priority level of event notifications \r
+                                 to dispatch\r
 \r
-Returns:\r
-\r
-  None\r
-\r
---*/\r
+**/\r
+VOID\r
+CoreDispatchEventNotifies (\r
+  IN EFI_TPL      Priority\r
+  )\r
 {\r
   IEVENT          *Event;\r
   LIST_ENTRY      *Head;\r
@@ -207,26 +173,18 @@ Returns:
 }\r
 \r
 \r
+\r
+/**\r
+  Queues the event's notification function to fire.\r
+\r
+  @param  Event                  The Event to notify\r
+\r
+**/\r
 STATIC\r
 VOID\r
 CoreNotifyEvent (\r
   IN  IEVENT      *Event\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Queues the event's notification function to fire\r
-\r
-Arguments:\r
-\r
-  Event       - The Event to notify\r
-\r
-Returns:\r
-\r
-  None\r
-\r
---*/\r
 {\r
 \r
   //\r
@@ -253,23 +211,17 @@ Returns:
 \r
 \r
 \r
+\r
+/**\r
+  Signals all events in the EventGroup.\r
+\r
+  @param  EventGroup             The list to signal\r
+\r
+**/\r
 VOID\r
 CoreNotifySignalList (\r
   IN EFI_GUID     *EventGroup\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Signals all events in the EventGroup\r
-\r
-Arguments:\r
-  EventGroup - The list to signal\r
-\r
-Returns:\r
-\r
-  None\r
-\r
---*/\r
 {\r
   LIST_ENTRY              *Link;\r
   LIST_ENTRY              *Head;\r
@@ -288,6 +240,25 @@ Returns:
   CoreReleaseEventLock ();\r
 }\r
 \r
+\r
+/**\r
+  Creates a general-purpose event structure.\r
+\r
+  @param  Type                   The type of event to create and its mode and \r
+                                 attributes \r
+  @param  NotifyTpl              The task priority level of event notifications \r
+  @param  NotifyFunction         Pointer to the events notification function \r
+  @param  NotifyContext          Pointer to the notification functions context; \r
+                                 corresponds to parameter "Context" in the \r
+                                 notification function \r
+  @param  Event                  Pointer to the newly created event if the call \r
+                                 succeeds; undefined otherwise \r
+\r
+  @retval EFI_SUCCESS            The event structure was created \r
+  @retval EFI_INVALID_PARAMETER  One of the parameters has an invalid value \r
+  @retval EFI_OUT_OF_RESOURCES   The event could not be allocated\r
+\r
+**/\r
 EFI_STATUS\r
 EFIAPI\r
 CoreCreateEvent (\r
@@ -297,30 +268,32 @@ CoreCreateEvent (
   IN VOID                     *NotifyContext, OPTIONAL\r
   OUT EFI_EVENT               *Event\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Creates a general-purpose event structure\r
-\r
-Arguments:\r
-  Type                - The type of event to create and its mode and attributes\r
-  NotifyTpl           - The task priority level of event notifications\r
-  NotifyFunction      - Pointer to the events notification function\r
-  NotifyContext       - Pointer to the notification functions context; corresponds to\r
-                        parameter "Context" in the notification function\r
-  Event               - Pointer to the newly created event if the call succeeds; undefined otherwise\r
-\r
-Returns:\r
-  EFI_SUCCESS           - The event structure was created\r
-  EFI_INVALID_PARAMETER - One of the parameters has an invalid value\r
-  EFI_OUT_OF_RESOURCES  - The event could not be allocated\r
-\r
---*/\r
 {\r
   return CoreCreateEventEx (Type, NotifyTpl, NotifyFunction, NotifyContext, NULL, Event);\r
 }\r
 \r
 \r
+\r
+/**\r
+  Creates a general-purpose event structure\r
+\r
+  @param  Type                   The type of event to create and its mode and \r
+                                 attributes \r
+  @param  NotifyTpl              The task priority level of event notifications \r
+  @param  NotifyFunction         Pointer to the events notification function \r
+  @param  NotifyContext          Pointer to the notification functions context; \r
+                                 corresponds to parameter "Context" in the \r
+                                 notification function \r
+  @param  EventGroup             GUID for EventGroup if NULL act the same as \r
+                                 gBS->CreateEvent(). \r
+  @param  Event                  Pointer to the newly created event if the call \r
+                                 succeeds; undefined otherwise \r
+\r
+  @retval EFI_SUCCESS            The event structure was created \r
+  @retval EFI_INVALID_PARAMETER  One of the parameters has an invalid value \r
+  @retval EFI_OUT_OF_RESOURCES   The event could not be allocated\r
+\r
+**/\r
 EFI_STATUS\r
 EFIAPI\r
 CoreCreateEventEx (\r
@@ -331,26 +304,6 @@ CoreCreateEventEx (
   IN CONST EFI_GUID           *EventGroup,    OPTIONAL\r
   OUT EFI_EVENT               *Event\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-  Creates a general-purpose event structure\r
-\r
-Arguments:\r
-  Type                - The type of event to create and its mode and attributes\r
-  NotifyTpl           - The task priority level of event notifications\r
-  NotifyFunction      - Pointer to the events notification function\r
-  NotifyContext       - Pointer to the notification functions context; corresponds to\r
-                        parameter "Context" in the notification function\r
-  EventGroup          - GUID for EventGroup if NULL act the same as gBS->CreateEvent().\r
-  Event               - Pointer to the newly created event if the call succeeds; undefined otherwise\r
-\r
-Returns:\r
-  EFI_SUCCESS           - The event structure was created\r
-  EFI_INVALID_PARAMETER - One of the parameters has an invalid value\r
-  EFI_OUT_OF_RESOURCES  - The event could not be allocated\r
-\r
---*/\r
 {\r
   EFI_STATUS      Status;\r
   IEVENT          *IEvent;\r
@@ -482,28 +435,21 @@ Returns:
 \r
 \r
 \r
-EFI_STATUS\r
-EFIAPI\r
-CoreSignalEvent (\r
-  IN EFI_EVENT    UserEvent\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Signals the event.  Queues the event to be notified if needed\r
 \r
-Arguments:\r
-\r
-  UserEvent - The event to signal\r
-\r
-Returns:\r
+  @param  UserEvent              The event to signal \r
 \r
-  EFI_INVALID_PARAMETER - Parameters are not valid.\r
+  @retval EFI_INVALID_PARAMETER  Parameters are not valid. \r
+  @retval EFI_SUCCESS            The event was signaled.\r
 \r
-  EFI_SUCCESS - The event was signaled.\r
-\r
---*/\r
+**/\r
+EFI_STATUS\r
+EFIAPI\r
+CoreSignalEvent (\r
+  IN EFI_EVENT    UserEvent\r
+  )\r
 {\r
   IEVENT          *Event;\r
 \r
@@ -549,29 +495,22 @@ Returns:
 }\r
 \r
 \r
+\r
+/**\r
+  Check the status of an event.\r
+\r
+  @param  UserEvent              The event to check \r
+\r
+  @retval EFI_SUCCESS            The event is in the signaled state \r
+  @retval EFI_NOT_READY          The event is not in the signaled state \r
+  @retval EFI_INVALID_PARAMETER  Event is of type EVT_NOTIFY_SIGNAL\r
+\r
+**/\r
 EFI_STATUS\r
 EFIAPI\r
 CoreCheckEvent (\r
   IN EFI_EVENT        UserEvent\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Check the status of an event\r
-\r
-Arguments:\r
-\r
-  UserEvent - The event to check\r
-\r
-Returns:\r
-\r
-  EFI_SUCCESS           - The event is in the signaled state\r
-  EFI_NOT_READY         - The event is not in the signaled state\r
-  EFI_INVALID_PARAMETER - Event is of type EVT_NOTIFY_SIGNAL\r
-\r
---*/\r
-\r
 {\r
   IEVENT      *Event;\r
   EFI_STATUS  Status;\r
@@ -625,6 +564,21 @@ Returns:
 \r
 \r
 \r
+\r
+/**\r
+  Stops execution until an event is signaled.\r
+\r
+  @param  NumberOfEvents         The number of events in the UserEvents array \r
+  @param  UserEvents             An array of EFI_EVENT \r
+  @param  UserIndex              Pointer to the index of the event which \r
+                                 satisfied the wait condition \r
+\r
+  @retval EFI_SUCCESS            The event indicated by Index was signaled. \r
+  @retval EFI_INVALID_PARAMETER  The event indicated by Index has a notification \r
+                                 function or Event was not a valid type \r
+  @retval EFI_UNSUPPORTED        The current TPL is not TPL_APPLICATION\r
+\r
+**/\r
 EFI_STATUS\r
 EFIAPI\r
 CoreWaitForEvent (\r
@@ -632,27 +586,6 @@ CoreWaitForEvent (
   IN EFI_EVENT    *UserEvents,\r
   OUT UINTN       *UserIndex\r
   )\r
-/*++\r
-\r
-Routine Description:\r
-\r
-  Stops execution until an event is signaled.\r
-\r
-Arguments:\r
-\r
-  NumberOfEvents  - The number of events in the UserEvents array\r
-  UserEvents      - An array of EFI_EVENT\r
-  UserIndex       - Pointer to the index of the event which satisfied the wait condition\r
-\r
-Returns:\r
-\r
-  EFI_SUCCESS           - The event indicated by Index was signaled.\r
-  EFI_INVALID_PARAMETER - The event indicated by Index has a notification function or\r
-                          Event was not a valid type\r
-  EFI_UNSUPPORTED       - The current TPL is not TPL_APPLICATION\r
-\r
---*/\r
-\r
 {\r
   EFI_STATUS      Status;\r
   UINTN           Index;\r
@@ -687,29 +620,21 @@ Returns:
 }\r
 \r
 \r
-EFI_STATUS\r
-EFIAPI\r
-CoreCloseEvent (\r
-  IN EFI_EVENT    UserEvent\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
 \r
+/**\r
   Closes an event and frees the event structure.\r
 \r
-Arguments:\r
-\r
-  UserEvent - Event to close\r
+  @param  UserEvent              Event to close \r
 \r
-Returns:\r
-\r
-  EFI_INVALID_PARAMETER - Parameters are not valid.\r
-\r
-  EFI_SUCCESS - The event has been closed\r
-\r
---*/\r
+  @retval EFI_INVALID_PARAMETER  Parameters are not valid. \r
+  @retval EFI_SUCCESS            The event has been closed\r
 \r
+**/\r
+EFI_STATUS\r
+EFIAPI\r
+CoreCloseEvent (\r
+  IN EFI_EVENT    UserEvent\r
+  )\r
 {\r
   EFI_STATUS  Status;\r
   IEVENT      *Event;\r