X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=blobdiff_plain;f=MdeModulePkg%2FUniversal%2FPcatRealTimeClockRuntimeDxe%2FPcRtc.c;h=a82f5d133e34ba93187ddc19b91586f7e06bc342;hp=057c0407b254adfbc8f35dc5a46ca234e7af3e89;hb=c5ed97f62898afc846af1751ac10ae874f93e24c;hpb=254ba2477fd0b101228da33db03efed95c6489ae diff --git a/MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c b/MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c index 057c0407b2..a82f5d133e 100644 --- a/MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c +++ b/MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c @@ -14,21 +14,18 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #include "PcRtc.h" -STATIC INTN CompareHMS ( IN EFI_TIME *From, IN EFI_TIME *To ); -STATIC BOOLEAN IsWithinOneDay ( IN EFI_TIME *From, IN EFI_TIME *To ); -STATIC UINT8 RtcRead ( IN UINT8 Address @@ -53,7 +50,6 @@ Returns: return IoRead8 (PCAT_RTC_DATA_REGISTER); } -STATIC VOID RtcWrite ( IN UINT8 Address, @@ -146,7 +142,7 @@ Returns: // // Wait for up to 0.1 seconds for the RTC to be updated // - Status = RtcWaitToUpdate (100000); + Status = RtcWaitToUpdate (PcdGet32 (PcdRealTimeClockUpdateTimeout)); if (EFI_ERROR (Status)) { //BugBug: the EfiAtRuntime should be encapsulated in EfiAcquireLock or // provide a new instance for EfiAcquireLock, say, RtEfiAcquireLock @@ -272,7 +268,7 @@ Routine Description: // // Wait for up to 0.1 seconds for the RTC to be updated // - Status = RtcWaitToUpdate (100000); + Status = RtcWaitToUpdate (PcdGet32 (PcdRealTimeClockUpdateTimeout)); if (EFI_ERROR (Status)) { //BugBug: the EfiAtRuntime should be encapsulated in EfiReleaseLock or // provide a new instance for EfiReleaseLock, say, RtEfiReleaseLock @@ -391,7 +387,7 @@ Routine Description: // // Wait for up to 0.1 seconds for the RTC to be updated // - Status = RtcWaitToUpdate (100000); + Status = RtcWaitToUpdate (PcdGet32 (PcdRealTimeClockUpdateTimeout)); if (EFI_ERROR (Status)) { //BugBug: the EfiAtRuntime should be encapsulated in EfiReleaseLock or // provide a new instance for EfiReleaseLock, say, RtEfiReleaseLock @@ -504,7 +500,7 @@ Returns: // // Wait for up to 0.1 seconds for the RTC to be updated // - Status = RtcWaitToUpdate (100000); + Status = RtcWaitToUpdate (PcdGet32 (PcdRealTimeClockUpdateTimeout)); if (EFI_ERROR (Status)) { //BugBug: the EfiAtRuntime should be encapsulated in EfiReleaseLock or // provide a new instance for EfiReleaseLock, say, RtEfiReleaseLock @@ -636,7 +632,7 @@ Returns: // // Wait for up to 0.1 seconds for the RTC to be updated // - Status = RtcWaitToUpdate (100000); + Status = RtcWaitToUpdate (PcdGet32 (PcdRealTimeClockUpdateTimeout)); if (EFI_ERROR (Status)) { //BugBug: the EfiAtRuntime should be encapsulated in EfiReleaseLock or // provide a new instance for EfiReleaseLock, say, RtEfiReleaseLock @@ -1034,7 +1030,6 @@ Returns: } } -STATIC INTN CompareHMS ( IN EFI_TIME *From, @@ -1071,7 +1066,6 @@ Returns: } } -STATIC BOOLEAN IsWithinOneDay ( IN EFI_TIME *From,