![Intel Extensible Firmware Interface Specification Download Page 53](http://html1.mh-extra.com/html/intel/extensible-firmware-interface/extensible-firmware-interface_specification_2073117053.webp)
Services
Version 1.02
12/12/00
35
3.1.4 WaitForEvent()
Summary
Stops execution until an event is signaled.
Prototype
EFI_STATUS
WaitForEvent (
IN UINTN
NumberOfEvents,
IN EFI_EVENT
*Event,
OUT UINTN
*Index
);
Parameters
NumberOfEvents
The number of events in the
Event
array.
Event
An array of
EFI_EVENT
. Type
EFI_EVENT
is defined in
Section 3.1.1.
Index
Pointer to the index of the event which satisfied the wait condition.
Description
The
WaitForEvent()
function waits for any event in the
Event
array to be signaled. On
success, the signaled state of the event is cleared and execution is returned with
Index
indicating
which event caused the return. It is possible for an event to be signaled before being waited on. In
this case, the next wait operation for that event would immediately return with the signaled event.
Waiting on an event of type
EVT_NOTIFY_SIGNAL
is not permitted. If any event in
Event
is of
type
EVT_NOTIFY_SIGNAL
,
WaitForEvent()
returns
EFI_INVALID_PARAMETER
and
sets
Index
to indicate which event caused the failure. This function must be called at priority
level
TPL_APPLICATION
. If an attempt is made to call it at any other priority level,
EFI_UNSUPPORTED
is returned.
To wait for a specified time, a timer event must be included in the
Event
array.
WaitForEvent()
will always check for signaled events in order, with the first event in the array
being checked first. To check if an event is signaled without waiting, an already signaled event can
be used as the last event in the list being checked, or the
CheckEvent()
interface may be used.
Status Codes Returned
EFI_SUCCESS
The event indicated by
Index
was signaled.
EFI_INVALID_PARAMETER
The event indicated by
Index
has a notification function or
Event
was not a valid type.
EFI_UNSUPPORTED
The current TPL is not
TPL_APPLICATION
.
Summary of Contents for Extensible Firmware Interface
Page 1: ...Extensible Firmware Interface Specification Version 1 02 December 12 2000...
Page 4: ...Extensible Firmware Interface Specification iv 12 12 00 Version 1 02...
Page 42: ...Extensible Firmware Interface Specification 24 12 01 00 Version 1 02...
Page 190: ...Extensible Firmware Interface Specification 172 12 12 00 Version 1 02...
Page 200: ...Extensible Firmware Interface Specification 182 12 12 00 Version 1 02...
Page 226: ...Extensible Firmware Interface Specification 208 12 12 00 Version 1 02...
Page 230: ...Extensible Firmware Interface Specification 212 12 12 00 Version 1 02...
Page 252: ...Extensible Firmware Interface Specification 234 12 12 00 Version 1 02...
Page 294: ...Extensible Firmware Interface Specification 276 12 12 00 Version 1 02...
Page 348: ...Extensible Firmware Interface Specification 330 12 01 00 Version 1 01...
Page 350: ...Extensible Firmware Interface Specification 332 12 12 00 Version 1 02...
Page 354: ...Extensible Firmware Interface Specification 336 12 12 00 Version 1 02...
Page 362: ...Extensible Firmware Interface Specification 344 12 12 00 Version 1 02...
Page 486: ...Extensible Firmware Interface Specification 468 12 12 00 Version 1 02...
Page 494: ...Extensible Firmware Interface Specification 476 12 12 00 Version 1 02...