]>
Commit | Line | Data |
---|---|---|
23c98c94 | 1 | /** @file\r |
504214c4 LG |
2 | UEFI Event support functions and structure.\r |
3 | \r | |
1ccdbf2a | 4 | Copyright (c) 2006 - 2010, Intel Corporation. <BR>\r |
23c98c94 | 5 | All rights reserved. This program and the accompanying materials\r |
6 | are licensed and made available under the terms and conditions of the BSD License\r | |
7 | which accompanies this distribution. The full text of the license may be found at\r | |
8 | http://opensource.org/licenses/bsd-license.php\r | |
9 | \r | |
10 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r | |
11 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r | |
28a00297 | 12 | \r |
504214c4 | 13 | **/\r |
28a00297 | 14 | \r |
5f3232d7 | 15 | #ifndef __EVENT_H__\r |
16 | #define __EVENT_H__\r | |
28a00297 | 17 | \r |
ec90508b | 18 | \r |
28a00297 | 19 | #define VALID_TPL(a) ((a) <= TPL_HIGH_LEVEL)\r |
ec90508b | 20 | extern UINTN gEventPending;\r |
21 | \r | |
28a00297 | 22 | \r |
23 | //\r | |
24 | // EFI_EVENT\r | |
25 | //\r | |
1ccdbf2a | 26 | \r |
27 | ///\r | |
28 | /// Timer event information\r | |
29 | ///\r | |
30 | typedef struct {\r | |
31 | LIST_ENTRY Link;\r | |
32 | UINT64 TriggerTime;\r | |
33 | UINT64 Period;\r | |
34 | } TIMER_EVENT_INFO;\r | |
35 | \r | |
f3f2e05d | 36 | #define EVENT_SIGNATURE SIGNATURE_32('e','v','n','t')\r |
28a00297 | 37 | typedef struct {\r |
38 | UINTN Signature;\r | |
39 | UINT32 Type;\r | |
40 | UINT32 SignalCount;\r | |
ec90508b | 41 | ///\r |
42 | /// Entry if the event is registered to be signalled\r | |
43 | ///\r | |
28a00297 | 44 | LIST_ENTRY SignalLink;\r |
ec90508b | 45 | ///\r |
46 | /// Notification information for this event\r | |
47 | ///\r | |
28a00297 | 48 | EFI_TPL NotifyTpl;\r |
49 | EFI_EVENT_NOTIFY NotifyFunction;\r | |
50 | VOID *NotifyContext;\r | |
51 | EFI_GUID EventGroup;\r | |
022c6d45 | 52 | LIST_ENTRY NotifyLink;\r |
28a00297 | 53 | BOOLEAN ExFlag;\r |
ec90508b | 54 | ///\r |
55 | /// A list of all runtime events\r | |
56 | ///\r | |
1ccdbf2a | 57 | EFI_RUNTIME_EVENT_ENTRY RuntimeData;\r |
58 | TIMER_EVENT_INFO Timer;\r | |
022c6d45 | 59 | } IEVENT;\r |
28a00297 | 60 | \r |
61 | //\r | |
62 | // Internal prototypes\r | |
63 | //\r | |
64 | \r | |
162ed594 | 65 | \r |
66 | /**\r | |
67 | Dispatches all pending events.\r | |
68 | \r | |
022c6d45 | 69 | @param Priority The task priority level of event notifications\r |
162ed594 | 70 | to dispatch\r |
71 | \r | |
72 | **/\r | |
28a00297 | 73 | VOID\r |
74 | CoreDispatchEventNotifies (\r | |
75 | IN EFI_TPL Priority\r | |
23c98c94 | 76 | );\r |
28a00297 | 77 | \r |
28a00297 | 78 | \r |
162ed594 | 79 | /**\r |
80 | Initializes timer support.\r | |
28a00297 | 81 | \r |
162ed594 | 82 | **/\r |
28a00297 | 83 | VOID\r |
84 | CoreInitializeTimer (\r | |
85 | VOID\r | |
23c98c94 | 86 | );\r |
28a00297 | 87 | \r |
28a00297 | 88 | #endif\r |