42 J = (EpochSeconds / 86400) + 2440588;
46 c = (((dg / 36524) + 1) * 3) / 4;
47 dc = dg - (c * 36524);
50 a = (((db / 365) + 1) * 3) / 4;
52 y = (g * 400) + (c * 100) + (b * 4) + a;
53 m = (((da * 5) + 308) / 153) - 2;
54 d = da - (((m + 4) * 153) / 5) + 122;
56 Time->Year = (UINT16)(y - 4800 + ((m + 2) / 12));
57 Time->Month = ((m + 2) % 12) + 1;
58 Time->Day = (UINT8)(d + 1);
60 ss = EpochSeconds % 60;
61 a = (EpochSeconds - ss) / 60;
66 Time->Hour = (UINT8)hh;
67 Time->Minute = (UINT8)mm;
68 Time->Second = (UINT8)ss;
95 ASSERT (Time !=
NULL);
126 return EFI_DEVICE_ERROR;
149 OUT BOOLEAN *Enabled,
150 OUT BOOLEAN *Pending,
154 return EFI_UNSUPPORTED;
181 return EFI_UNSUPPORTED;
EFI_STATUS EFIAPI LibSetWakeupTime(IN BOOLEAN Enabled, OUT EFI_TIME *Time)
EFI_STATUS EFIAPI LibRtcInitialize(IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable)
STATIC VOID EpochToEfiTime(IN UINTN EpochSeconds, OUT EFI_TIME *Time)
EFI_STATUS EFIAPI LibGetWakeupTime(OUT BOOLEAN *Enabled, OUT BOOLEAN *Pending, OUT EFI_TIME *Time)
EFI_STATUS EFIAPI LibSetTime(IN EFI_TIME *Time)
EFI_STATUS EFIAPI LibGetTime(OUT EFI_TIME *Time, OUT EFI_TIME_CAPABILITIES *Capabilities)