]>
Commit | Line | Data |
---|---|---|
2ef2b01e A |
1 | /** @file\r |
2 | Implement EFI RealTimeClock runtime services via Lib.\r | |
3402aac7 | 3 | \r |
2ef2b01e A |
4 | Currently this driver does not support runtime virtual calling.\r |
5 | \r | |
60274cca | 6 | Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>\r |
2ef2b01e | 7 | \r |
60274cca | 8 | This program and the accompanying materials\r |
2ef2b01e A |
9 | are licensed and made available under the terms and conditions of the BSD License\r |
10 | which accompanies this distribution. The full text of the license may be found at\r | |
11 | http://opensource.org/licenses/bsd-license.php\r | |
12 | \r | |
13 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r | |
14 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r | |
15 | \r | |
16 | **/\r | |
17 | \r | |
18 | #ifndef __REAL_TIME_CLOCK_LIB__\r | |
19 | #define __REAL_TIME_CLOCK_LIB__\r | |
20 | \r | |
21 | \r | |
22 | /**\r | |
23 | Returns the current time and date information, and the time-keeping capabilities\r | |
24 | of the hardware platform.\r | |
25 | \r | |
26 | @param Time A pointer to storage to receive a snapshot of the current time.\r | |
27 | @param Capabilities An optional pointer to a buffer to receive the real time clock\r | |
28 | device's capabilities.\r | |
29 | \r | |
30 | @retval EFI_SUCCESS The operation completed successfully.\r | |
31 | @retval EFI_INVALID_PARAMETER Time is NULL.\r | |
32 | @retval EFI_DEVICE_ERROR The time could not be retrieved due to hardware error.\r | |
33 | \r | |
34 | **/\r | |
35 | EFI_STATUS\r | |
36 | EFIAPI\r | |
37 | LibGetTime (\r | |
38 | OUT EFI_TIME *Time,\r | |
39 | OUT EFI_TIME_CAPABILITIES *Capabilities\r | |
40 | );\r | |
41 | \r | |
42 | \r | |
43 | /**\r | |
44 | Sets the current local time and date information.\r | |
45 | \r | |
46 | @param Time A pointer to the current time.\r | |
47 | \r | |
48 | @retval EFI_SUCCESS The operation completed successfully.\r | |
49 | @retval EFI_INVALID_PARAMETER A time field is out of range.\r | |
50 | @retval EFI_DEVICE_ERROR The time could not be set due due to hardware error.\r | |
51 | \r | |
52 | **/\r | |
53 | EFI_STATUS\r | |
54 | EFIAPI\r | |
55 | LibSetTime (\r | |
56 | IN EFI_TIME *Time\r | |
57 | );\r | |
58 | \r | |
59 | \r | |
60 | /**\r | |
61 | Returns the current wakeup alarm clock setting.\r | |
62 | \r | |
63 | @param Enabled Indicates if the alarm is currently enabled or disabled.\r | |
64 | @param Pending Indicates if the alarm signal is pending and requires acknowledgement.\r | |
65 | @param Time The current alarm setting.\r | |
66 | \r | |
67 | @retval EFI_SUCCESS The alarm settings were returned.\r | |
68 | @retval EFI_INVALID_PARAMETER Any parameter is NULL.\r | |
69 | @retval EFI_DEVICE_ERROR The wakeup time could not be retrieved due to a hardware error.\r | |
70 | \r | |
71 | **/\r | |
72 | EFI_STATUS\r | |
73 | EFIAPI\r | |
74 | LibGetWakeupTime (\r | |
75 | OUT BOOLEAN *Enabled,\r | |
76 | OUT BOOLEAN *Pending,\r | |
77 | OUT EFI_TIME *Time\r | |
78 | );\r | |
79 | \r | |
80 | \r | |
81 | /**\r | |
82 | Sets the system wakeup alarm clock time.\r | |
83 | \r | |
84 | @param Enabled Enable or disable the wakeup alarm.\r | |
85 | @param Time If Enable is TRUE, the time to set the wakeup alarm for.\r | |
86 | \r | |
87 | @retval EFI_SUCCESS If Enable is TRUE, then the wakeup alarm was enabled. If\r | |
88 | Enable is FALSE, then the wakeup alarm was disabled.\r | |
89 | @retval EFI_INVALID_PARAMETER A time field is out of range.\r | |
90 | @retval EFI_DEVICE_ERROR The wakeup time could not be set due to a hardware error.\r | |
91 | @retval EFI_UNSUPPORTED A wakeup timer is not supported on this platform.\r | |
92 | \r | |
93 | **/\r | |
94 | EFI_STATUS\r | |
95 | EFIAPI\r | |
96 | LibSetWakeupTime (\r | |
97 | IN BOOLEAN Enabled,\r | |
98 | OUT EFI_TIME *Time\r | |
99 | );\r | |
100 | \r | |
101 | \r | |
102 | \r | |
103 | /**\r | |
104 | This is the declaration of an EFI image entry point. This can be the entry point to an application\r | |
105 | written to this specification, an EFI boot service driver, or an EFI runtime driver.\r | |
106 | \r | |
107 | @param ImageHandle Handle that identifies the loaded image.\r | |
108 | @param SystemTable System Table for this image.\r | |
109 | \r | |
110 | @retval EFI_SUCCESS The operation completed successfully.\r | |
111 | \r | |
112 | **/\r | |
113 | EFI_STATUS\r | |
114 | EFIAPI\r | |
115 | LibRtcInitialize (\r | |
116 | IN EFI_HANDLE ImageHandle,\r | |
117 | IN EFI_SYSTEM_TABLE *SystemTable\r | |
118 | );\r | |
119 | \r | |
120 | \r | |
121 | /**\r | |
122 | Fixup internal data so that EFI can be call in virtual mode.\r | |
123 | Call the passed in Child Notify event and convert any pointers in\r | |
124 | lib to virtual mode.\r | |
125 | \r | |
126 | @param[in] Event The Event that is being processed\r | |
127 | @param[in] Context Event Context\r | |
128 | **/\r | |
129 | VOID\r | |
130 | EFIAPI\r | |
131 | LibRtcVirtualNotifyEvent (\r | |
132 | IN EFI_EVENT Event,\r | |
133 | IN VOID *Context\r | |
134 | );\r | |
135 | \r | |
136 | \r | |
137 | #endif\r | |
138 | \r |