]> git.proxmox.com Git - mirror_edk2.git/blob - MdeModulePkg/Core/Dxe/Event.h
Don't align image address for TeImage, because TeImage section alignment is undefined.
[mirror_edk2.git] / MdeModulePkg / Core / Dxe / Event.h
1 /** @file
2 UEFI Event support functions and structure.
3
4 Copyright (c) 2006 - 2008, Intel Corporation. <BR>
5 All rights reserved. This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php
9
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12
13 **/
14
15 #ifndef __EVENT_H__
16 #define __EVENT_H__
17
18 #define VALID_TPL(a) ((a) <= TPL_HIGH_LEVEL)
19
20 //
21 // EFI_EVENT
22 //
23 #define EVENT_SIGNATURE EFI_SIGNATURE_32('e','v','n','t')
24 typedef struct {
25 UINTN Signature;
26 UINT32 Type;
27 UINT32 SignalCount;
28
29 //
30 // Entry if the event is registered to be signalled
31 //
32
33 LIST_ENTRY SignalLink;
34
35 //
36 // Notification information for this event
37 //
38
39 EFI_TPL NotifyTpl;
40 EFI_EVENT_NOTIFY NotifyFunction;
41 VOID *NotifyContext;
42 EFI_GUID EventGroup;
43 LIST_ENTRY NotifyLink;
44 BOOLEAN ExFlag;
45
46 //
47 // A list of all runtime events
48 //
49 EFI_RUNTIME_EVENT_ENTRY RuntimeData;
50
51 //
52 // Information by event type
53 //
54
55 union {
56 //
57 // For timer events
58 //
59 struct {
60 LIST_ENTRY Link;
61 UINT64 TriggerTime;
62 UINT64 Period;
63 } Timer;
64 } u;
65
66 } IEVENT;
67
68 //
69 // Internal prototypes
70 //
71
72
73 /**
74 Dispatches all pending events.
75
76 @param Priority The task priority level of event notifications
77 to dispatch
78
79 **/
80 VOID
81 CoreDispatchEventNotifies (
82 IN EFI_TPL Priority
83 );
84
85
86
87 //
88 // Exported functions
89 //
90 /**
91 Initializes timer support.
92
93 **/
94 VOID
95 CoreInitializeTimer (
96 VOID
97 );
98
99 //
100 // extern data declarations
101 //
102
103 extern EFI_LOCK gEventQueueLock;
104 extern UINTN gEventPending;
105 extern LIST_ENTRY gEventQueue[];
106 extern LIST_ENTRY gEventSignalQueue;
107
108 #endif