3 Copyright (c) 2005, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
19 #include "RealTimeClock.h"
21 static PC_RTC_MODULE_GLOBALS mModuleGlobal
;
27 OUT EFI_TIME_CAPABILITIES
*Capabilities
33 TODO: Add function description
37 Time - TODO: add argument description
38 Capabilities - TODO: add argument description
42 TODO: add return values
46 return PcRtcGetTime (Time
, Capabilities
, &mModuleGlobal
);
58 TODO: Add function description
62 Time - TODO: add argument description
66 TODO: add return values
70 return PcRtcSetTime (Time
, &mModuleGlobal
);
75 PcRtcEfiGetWakeupTime (
84 TODO: Add function description
88 Enabled - TODO: add argument description
89 Pending - TODO: add argument description
90 Time - TODO: add argument description
94 TODO: add return values
98 return PcRtcGetWakeupTime (Enabled
, Pending
, Time
, &mModuleGlobal
);
103 PcRtcEfiSetWakeupTime (
111 TODO: Add function description
115 Enabled - TODO: add argument description
116 Time - TODO: add argument description
120 TODO: add return values
124 return PcRtcSetWakeupTime (Enabled
, Time
, &mModuleGlobal
);
129 InitializeRealTimeClock (
130 IN EFI_HANDLE ImageHandle
,
131 IN EFI_SYSTEM_TABLE
*SystemTable
143 // TODO: ImageHandle - add argument and description to function comment
144 // TODO: SystemTable - add argument and description to function comment
147 EFI_HANDLE NewHandle
;
149 EfiInitializeLock (&mModuleGlobal
.RtcLock
, TPL_HIGH_LEVEL
);
151 Status
= PcRtcInit (&mModuleGlobal
);
152 if (EFI_ERROR (Status
)) {
156 SystemTable
->RuntimeServices
->GetTime
= PcRtcEfiGetTime
;
157 SystemTable
->RuntimeServices
->SetTime
= PcRtcEfiSetTime
;
158 SystemTable
->RuntimeServices
->GetWakeupTime
= PcRtcEfiGetWakeupTime
;
159 SystemTable
->RuntimeServices
->SetWakeupTime
= PcRtcEfiSetWakeupTime
;
162 Status
= gBS
->InstallMultipleProtocolInterfaces (
164 &gEfiRealTimeClockArchProtocolGuid
,