#include <Guid/OcVariable.h>
#include <Protocol/AppleRtcRam.h>
#include <Library/BaseMemoryLib.h>
#include <Library/DebugLib.h>
#include <Library/MemoryAllocationLib.h>
#include <Library/OcMiscLib.h>
#include <Library/OcRtcLib.h>
#include <Library/UefiBootServicesTableLib.h>
#include <Library/UefiLib.h>
#include "OcRtcLibInternal.h"
Go to the source code of this file.
Functions | |
STATIC EFI_STATUS | SyncRtcRead (IN UINT8 Address, IN UINT8 *ValuePtr) |
STATIC EFI_STATUS | SyncRtcWrite (IN UINT8 Address, IN UINT8 Value) |
STATIC EFI_STATUS | SyncRtcWaitForReady (VOID) |
STATIC UINTN EFIAPI | AppleRtcGetAvailableMemory (IN APPLE_RTC_RAM_PROTOCOL *This) |
STATIC EFI_STATUS EFIAPI | AppleRtcRamReadData (IN APPLE_RTC_RAM_PROTOCOL *This, OUT UINT8 *Buffer, IN UINTN BufferSize, IN UINTN Address) |
STATIC EFI_STATUS EFIAPI | AppleRtcRamWriteData (IN APPLE_RTC_RAM_PROTOCOL *This, IN CONST UINT8 *Buffer, IN UINTN BufferSize, IN UINTN Address) |
STATIC EFI_STATUS EFIAPI | AppleRtcRamReset (IN APPLE_RTC_RAM_PROTOCOL *This) |
APPLE_RTC_RAM_PROTOCOL * | OcAppleRtcRamInstallProtocol (IN BOOLEAN Reinstall) |
Variables | |
STATIC EFI_LOCK | mAppleRtcRamLock |
STATIC UINT8 | mEmulatedRtcArea [APPLE_RTC_TOTAL_SIZE] |
STATIC BOOLEAN | mEmulatedRtcStatus [APPLE_RTC_TOTAL_SIZE] |
STATIC APPLE_RTC_RAM_PROTOCOL | mAppleRtcRamProtocol |
OcRtcLib - library with RTC I/O functions
Copyright (c) 2020, vit9696
All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at http://opensource.org/licenses/bsd-license.php
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
Definition in file AppleRtcRam.c.
STATIC UINTN EFIAPI AppleRtcGetAvailableMemory | ( | IN APPLE_RTC_RAM_PROTOCOL * | This | ) |
Definition at line 115 of file AppleRtcRam.c.
STATIC EFI_STATUS EFIAPI AppleRtcRamReadData | ( | IN APPLE_RTC_RAM_PROTOCOL * | This, |
OUT UINT8 * | Buffer, | ||
IN UINTN | BufferSize, | ||
IN UINTN | Address ) |
Definition at line 125 of file AppleRtcRam.c.
STATIC EFI_STATUS EFIAPI AppleRtcRamReset | ( | IN APPLE_RTC_RAM_PROTOCOL * | This | ) |
Definition at line 242 of file AppleRtcRam.c.
STATIC EFI_STATUS EFIAPI AppleRtcRamWriteData | ( | IN APPLE_RTC_RAM_PROTOCOL * | This, |
IN CONST UINT8 * | Buffer, | ||
IN UINTN | BufferSize, | ||
IN UINTN | Address ) |
< This is not checked in the original.
< Does not check the error code.
Definition at line 182 of file AppleRtcRam.c.
APPLE_RTC_RAM_PROTOCOL * OcAppleRtcRamInstallProtocol | ( | IN BOOLEAN | Reinstall | ) |
Install and initialise Apple RTC RAM protocol.
[in] | Reinstall | Overwrite installed protocol. |
installed | or located protocol or NULL. |
Definition at line 289 of file AppleRtcRam.c.
STATIC EFI_STATUS SyncRtcRead | ( | IN UINT8 | Address, |
IN UINT8 * | ValuePtr ) |
Definition at line 36 of file AppleRtcRam.c.
STATIC EFI_STATUS SyncRtcWaitForReady | ( | VOID | ) |
Definition at line 83 of file AppleRtcRam.c.
STATIC EFI_STATUS SyncRtcWrite | ( | IN UINT8 | Address, |
IN UINT8 | Value ) |
Definition at line 59 of file AppleRtcRam.c.
STATIC EFI_LOCK mAppleRtcRamLock |
Definition at line 30 of file AppleRtcRam.c.
STATIC APPLE_RTC_RAM_PROTOCOL mAppleRtcRamProtocol |
Definition at line 281 of file AppleRtcRam.c.
STATIC UINT8 mEmulatedRtcArea[APPLE_RTC_TOTAL_SIZE] |
Definition at line 31 of file AppleRtcRam.c.
STATIC BOOLEAN mEmulatedRtcStatus[APPLE_RTC_TOTAL_SIZE] |
Definition at line 32 of file AppleRtcRam.c.