3 Copyright (c) 2006, 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.
18 Runtime Architectural Protocol as defined in the DXE CIS
20 This code is used to produce the EFI runtime architectural protocol.
28 // Function Prototypes
32 RuntimeDriverCalculateCrc32 (
41 Calculate CRC32 for target data
45 Data - The target data.
46 DataSize - The target data size.
47 CrcOut - The CRC32 for target data.
51 EFI_SUCCESS - The CRC32 for target data is calculated successfully.
52 EFI_INVALID_PARAMETER - Some parameter is not valid, so the CRC32 is not
60 RuntimeDriverConvertPointer (
61 IN UINTN DebugDisposition
,
62 IN OUT VOID
**ConvertAddress
68 Determines the new virtual address that is to be used on subsequent memory accesses.
72 DebugDisposition - Supplies type information for the pointer being converted.
73 ConvertAddress - A pointer to a pointer that is to be fixed to be the value needed
74 for the new virtual address mappings being applied.
78 EFI_SUCCESS - The pointer pointed to by Address was modified.
79 EFI_NOT_FOUND - The pointer pointed to by Address was not found to be part
80 of the current memory map. This is normally fatal.
81 EFI_INVALID_PARAMETER - One of the parameters has an invalid value.
88 RuntimeDriverSetVirtualAddressMap (
89 IN UINTN MemoryMapSize
,
90 IN UINTN DescriptorSize
,
91 IN UINT32 DescriptorVersion
,
92 IN EFI_MEMORY_DESCRIPTOR
*VirtualMap
98 Changes the runtime addressing mode of EFI firmware from physical to virtual.
102 MemoryMapSize - The size in bytes of VirtualMap.
103 DescriptorSize - The size in bytes of an entry in the VirtualMap.
104 DescriptorVersion - The version of the structure entries in VirtualMap.
105 VirtualMap - An array of memory descriptors which contain new virtual
106 address mapping information for all runtime ranges.
110 EFI_SUCCESS - The virtual address map has been applied.
111 EFI_UNSUPPORTED - EFI firmware is not at runtime, or the EFI firmware is already in
112 virtual address mapped mode.
113 EFI_INVALID_PARAMETER - DescriptorSize or DescriptorVersion is invalid.
114 EFI_NO_MAPPING - A virtual address was not supplied for a range in the memory
115 map that requires a mapping.
116 EFI_NOT_FOUND - A virtual address was supplied for an address that is not found
123 RuntimeDriverInitializeCrc32Table (
130 Initialize CRC32 table.
145 RuntimeDriverInitialize (
146 IN EFI_HANDLE ImageHandle
,
147 IN EFI_SYSTEM_TABLE
*SystemTable
153 Install Runtime AP. This code includes the EfiRuntimeLib, but it only
154 functions at RT in physical mode.
158 ImageHandle - Image handle of this driver.
159 SystemTable - Pointer to the EFI System Table.
163 EFI_SUCEESS - Runtime Driver Architectural Protocol installed.