23 #if defined (MDE_CPU_IA32) 35 } BASE_LIBRARY_JUMP_BUFFER;
37 #define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 4 39 #endif // defined (MDE_CPU_IA32) 41 #if defined (MDE_CPU_X64) 59 } BASE_LIBRARY_JUMP_BUFFER;
61 #define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 8 63 #endif // defined (MDE_CPU_X64) 65 #if defined (MDE_CPU_EBC) 75 } BASE_LIBRARY_JUMP_BUFFER;
77 #define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 8 79 #endif // defined (MDE_CPU_EBC) 81 #if defined (MDE_CPU_ARM) 95 } BASE_LIBRARY_JUMP_BUFFER;
97 #define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 4 99 #endif // defined (MDE_CPU_ARM) 101 #if defined (MDE_CPU_AARCH64) 127 } BASE_LIBRARY_JUMP_BUFFER;
129 #define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 8 131 #endif // defined (MDE_CPU_AARCH64) 133 #if defined (MDE_CPU_RISCV64) 152 } BASE_LIBRARY_JUMP_BUFFER;
154 #define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 8 157 RiscVSetSupervisorScratch (
162 RiscVGetSupervisorScratch (
167 RiscVSetSupervisorStvec (
172 RiscVGetSupervisorStvec (
177 RiscVGetSupervisorTrapCause (
182 RiscVSetSupervisorAddressTranslationRegister (
187 RiscVGetSupervisorAddressTranslationRegister (
197 RiscVSetSupervisorTimeCompareRegister (
202 RiscVEnableTimerInterrupt (
207 RiscVDisableTimerInterrupt (
212 RiscVClearPendingTimerInterrupt (
222 RiscVInvalidateInstCacheFenceAsm (
232 RiscVInvalidateDataCacheFenceAsm (
243 RiscVCpuCacheFlushCmoAsm (
255 RiscVCpuCacheCleanCmoAsm (
265 RiscVCpuCacheInvalCmoAsm (
269 #endif // defined (MDE_CPU_RISCV64) 271 #if defined (MDE_CPU_LOONGARCH64) 288 } BASE_LIBRARY_JUMP_BUFFER;
290 #define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 8 298 SetExceptionBaseAddress (
308 SetTlbRebaseAddress (
318 EnableLocalInterrupts (
328 DisableLocalInterrupts (
352 AsmReadStableCounter (
513 #endif // defined (MDE_CPU_LOONGARCH64) 1748 #define GUID_STRING_LENGTH 36 2819 #define INITIALIZE_LIST_HEAD_VARIABLE(ListHead) {&(ListHead), &(ListHead)} 2828 #define BASE_LIST_FOR_EACH(Entry, ListHead) \ 2829 for(Entry = (ListHead)->ForwardLink; Entry != (ListHead); Entry = Entry->ForwardLink) 2844 #define BASE_LIST_FOR_EACH_SAFE(Entry, NextEntry, ListHead) \ 2845 for(Entry = (ListHead)->ForwardLink, NextEntry = Entry->ForwardLink;\ 2846 Entry != (ListHead); Entry = NextEntry, NextEntry = Entry->ForwardLink) 4886 #define CRC16ANSI_INIT 0xffff 4960 OUT BASE_LIBRARY_JUMP_BUFFER *JumpBuffer
4982 IN BASE_LIBRARY_JUMP_BUFFER *JumpBuffer,
5160 #if defined (MDE_CPU_X64) || defined (MDE_CPU_IA32) 5226 #if defined (MDE_CPU_X64) 5231 PvalidatePageSize4K = 0,
5232 PvalidatePageSize2MB,
5233 } PVALIDATE_PAGE_SIZE;
5238 #define PVALIDATE_RET_SUCCESS 0 5239 #define PVALIDATE_RET_FAIL_INPUT 1 5240 #define PVALIDATE_RET_SIZE_MISMATCH 6 5245 #define PVALIDATE_RET_NO_RMPUPDATE 255 5270 IN PVALIDATE_PAGE_SIZE PageSize,
5278 #define RMPADJUST_VMPL_MAX 3 5279 #define RMPADJUST_VMPL_MASK 0xFF 5280 #define RMPADJUST_VMPL_SHIFT 0 5281 #define RMPADJUST_PERMISSION_MASK_MASK 0xFF 5282 #define RMPADJUST_PERMISSION_MASK_SHIFT 8 5283 #define RMPADJUST_VMSA_PAGE_BIT BIT16 5312 #if defined (MDE_CPU_IA32) || defined (MDE_CPU_X64) 5455 } IA32_SEGMENT_DESCRIPTOR;
5467 #define IA32_IDT_GATE_TYPE_TASK 0x85 5468 #define IA32_IDT_GATE_TYPE_INTERRUPT_16 0x86 5469 #define IA32_IDT_GATE_TYPE_TRAP_16 0x87 5470 #define IA32_IDT_GATE_TYPE_INTERRUPT_32 0x8E 5471 #define IA32_IDT_GATE_TYPE_TRAP_32 0x8F 5473 #define IA32_GDT_TYPE_TSS 0x9 5474 #define IA32_GDT_ALIGNMENT 8 5476 #if defined (MDE_CPU_IA32) 5489 } IA32_IDT_GATE_DESCRIPTOR;
5530 UINT16 LDTSegmentSelector;
5534 } IA32_TASK_STATE_SEGMENT;
5552 } IA32_TSS_DESCRIPTOR;
5555 #endif // defined (MDE_CPU_IA32) 5557 #if defined (MDE_CPU_X64) 5575 } IA32_IDT_GATE_DESCRIPTOR;
5591 } IA32_TASK_STATE_SEGMENT;
5614 } IA32_TSS_DESCRIPTOR;
5617 #endif // defined (MDE_CPU_X64) 5680 IA32_EFLAGS32 EFLAGS;
5690 } IA32_REGISTER_SET;
5696 IA32_REGISTER_SET *RealModeState;
5697 VOID *RealModeBuffer;
5698 UINT32 RealModeBufferSize;
5702 #define THUNK_ATTRIBUTE_BIG_REAL_MODE 0x00000001 5703 #define THUNK_ATTRIBUTE_DISABLE_A20_MASK_INT_15 0x00000002 5704 #define THUNK_ATTRIBUTE_DISABLE_A20_MASK_KBD_CTRL 0x00000004 5718 typedef VOID (X86_ASSEMBLY_PATCH_LABEL) (
5976 AsmMsrBitFieldRead32 (
6009 AsmMsrBitFieldWrite32 (
6045 AsmMsrBitFieldOr32 (
6081 AsmMsrBitFieldAnd32 (
6121 AsmMsrBitFieldAndThenOr32 (
6276 AsmMsrBitFieldRead64 (
6308 AsmMsrBitFieldWrite64 (
6344 AsmMsrBitFieldOr64 (
6380 AsmMsrBitFieldAnd64 (
6419 AsmMsrBitFieldAndThenOr64 (
6958 OUT IA32_DESCRIPTOR *Gdtr
6975 IN CONST IA32_DESCRIPTOR *Gdtr
6992 OUT IA32_DESCRIPTOR *Idtr
7009 IN CONST IA32_DESCRIPTOR *Idtr
7527 AsmDisablePaging32 (
7608 AsmDisablePaging64 (
7643 AsmGetThunk16Properties (
7665 IN OUT THUNK_CONTEXT *ThunkContext
7724 IN OUT THUNK_CONTEXT *ThunkContext
7749 AsmPrepareAndThunk16 (
7750 IN OUT THUNK_CONTEXT *ThunkContext
7917 PatchInstructionX86 (
7918 OUT X86_ASSEMBLY_PATCH_LABEL *InstructionEnd,
7923 #endif // defined (MDE_CPU_IA32) || defined (MDE_CPU_X64) 7924 #endif // !defined (__BASE_LIB__) UINTN EFIAPI AsciiStrnSizeS(IN CONST CHAR8 *String, IN UINTN MaxSize)
Returns the size of a Null-terminated Ascii string in bytes, including the Null terminator.
LIST_ENTRY *EFIAPI InsertTailList(IN OUT LIST_ENTRY *ListHead, IN OUT LIST_ENTRY *Entry)
Adds a node to the end of a doubly linked list, and returns the pointer to the head node of the doubl...
INTN EFIAPI AsciiStrCmp(IN CONST CHAR8 *FirstString, IN CONST CHAR8 *SecondString)
Compares two Null-terminated ASCII strings, and returns the difference between the first mismatched A...
#define OPTIONAL
Passing the datum to the function is optional, and a NULL is passed if the value is not supplied.
BOOLEAN EFIAPI SaveAndDisableInterrupts(VOID)
Disables CPU interrupts and returns the interrupt state prior to the disable operation.
RETURN_STATUS EFIAPI StrDecimalToUintnS(IN CONST CHAR16 *String, OUT CHAR16 **EndPointer OPTIONAL, OUT UINTN *Data)
Convert a Null-terminated Unicode decimal string to a value of type UINTN.
RETURN_STATUS EFIAPI AsciiStrDecimalToUint64S(IN CONST CHAR8 *String, OUT CHAR8 **EndPointer OPTIONAL, OUT UINT64 *Data)
Convert a Null-terminated Ascii decimal string to a value of type UINT64.
UINT16 EFIAPI BitFieldOr16(IN UINT16 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT16 OrData)
Reads a bit field from a 16-bit value, performs a bitwise OR, and returns the result.
UINTN EFIAPI StrnSizeS(IN CONST CHAR16 *String, IN UINTN MaxSize)
Returns the size of a Null-terminated Unicode string in bytes, including the Null terminator.
UINTN EFIAPI AsciiStrnLenS(IN CONST CHAR8 *String, IN UINTN MaxSize)
Returns the length of a Null-terminated Ascii string.
RETURN_STATUS EFIAPI StrDecimalToUint64S(IN CONST CHAR16 *String, OUT CHAR16 **EndPointer OPTIONAL, OUT UINT64 *Data)
Convert a Null-terminated Unicode decimal string to a value of type UINT64.
UINT64 EFIAPI ReadUnaligned64(IN CONST UINT64 *Buffer)
Reads a 64-bit value from memory that may be unaligned.
UINT8 EFIAPI BitFieldCountOnes64(IN UINT64 Operand, IN UINTN StartBit, IN UINTN EndBit)
Reads a bit field from a 64-bit value, counts and returns the number of set bits.
UINT64 EFIAPI BitFieldOr64(IN UINT64 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT64 OrData)
Reads a bit field from a 64-bit value, performs a bitwise OR, and returns the result.
INT64 EFIAPI MultS64x64(IN INT64 Multiplicand, IN INT64 Multiplier)
Multiples a 64-bit signed integer by a 64-bit signed integer and generates a 64-bit signed result.
UINTN EFIAPI StrSize(IN CONST CHAR16 *String)
Returns the size of a Null-terminated Unicode string in bytes, including the Null terminator.
UINT32 EFIAPI BitFieldAndThenOr32(IN UINT32 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT32 AndData, IN UINT32 OrData)
Reads a bit field from a 32-bit value, performs a bitwise AND followed by a bitwise OR,...
UINTN EFIAPI StrnLenS(IN CONST CHAR16 *String, IN UINTN MaxSize)
Returns the length of a Null-terminated Unicode string.
INTN EFIAPI LowBitSet32(IN UINT32 Operand)
Returns the bit position of the lowest bit set in a 32-bit value.
RETURN_STATUS EFIAPI AsciiStrnToUnicodeStrS(IN CONST CHAR8 *Source, IN UINTN Length, OUT CHAR16 *Destination, IN UINTN DestMax, OUT UINTN *DestinationLength)
Convert not more than Length successive characters from a Null-terminated Ascii string to a Null-term...
UINT32 EFIAPI GetPowerOfTwo32(IN UINT32 Operand)
Returns the value of the highest bit set in a 32-bit value.
BOOLEAN EFIAPI IsNodeInList(IN CONST LIST_ENTRY *FirstEntry, IN CONST LIST_ENTRY *SecondEntry)
Checks whether FirstEntry and SecondEntry are part of the same doubly-linked list.
UINT16 EFIAPI ReadUnaligned16(IN CONST UINT16 *Buffer)
Reads a 16-bit value from memory that may be unaligned.
128 bit buffer containing a unique identifier value.
UINT8 EFIAPI CalculateSum8(IN CONST UINT8 *Buffer, IN UINTN Length)
Returns the sum of all elements in a buffer in unit of UINT8.
RETURN_STATUS EFIAPI UnicodeStrnToAsciiStrS(IN CONST CHAR16 *Source, IN UINTN Length, OUT CHAR8 *Destination, IN UINTN DestMax, OUT UINTN *DestinationLength)
Convert not more than Length successive characters from a Null-terminated Unicode string to a Null-te...
UINT64 EFIAPI DivU64x32(IN UINT64 Dividend, IN UINT32 Divisor)
Divides a 64-bit unsigned integer by a 32-bit unsigned integer and generates a 64-bit unsigned result...
UINTN EFIAPI AsciiStrDecimalToUintn(IN CONST CHAR8 *String)
Convert a Null-terminated ASCII decimal string to a value of type UINTN.
RETURN_STATUS EFIAPI AsciiStrnCatS(IN OUT CHAR8 *Destination, IN UINTN DestMax, IN CONST CHAR8 *Source, IN UINTN Length)
Appends not more than Length successive char from the string pointed to by Source to the end of the s...
CHAR16 *EFIAPI StrStr(IN CONST CHAR16 *String, IN CONST CHAR16 *SearchString)
Returns the first occurrence of a Null-terminated Unicode sub-string in a Null-terminated Unicode str...
LIST_ENTRY *EFIAPI InitializeListHead(IN OUT LIST_ENTRY *ListHead)
Initializes the head node of a doubly linked list, and returns the pointer to the head node of the do...
VOID EFIAPI CpuDeadLoop(VOID)
Executes an infinite loop.
BOOLEAN EFIAPI IsNodeAtEnd(IN CONST LIST_ENTRY *List, IN CONST LIST_ENTRY *Node)
Determines if a node the last node in a doubly linked list.
UINT64 EFIAPI MultU64x32(IN UINT64 Multiplicand, IN UINT32 Multiplier)
Multiples a 64-bit unsigned integer by a 32-bit unsigned integer and generates a 64-bit unsigned resu...
UINT64 EFIAPI MultU64x64(IN UINT64 Multiplicand, IN UINT64 Multiplier)
Multiples a 64-bit unsigned integer by a 64-bit unsigned integer and generates a 64-bit unsigned resu...
UINT32 EFIAPI ReadUnaligned24(IN CONST UINT32 *Buffer)
Reads a 24-bit value from memory that may be unaligned.
UINT32 EFIAPI ModU64x32(IN UINT64 Dividend, IN UINT32 Divisor)
Divides a 64-bit unsigned integer by a 32-bit unsigned integer and generates a 32-bit unsigned remain...
VOID EFIAPI LongJump(IN BASE_LIBRARY_JUMP_BUFFER *JumpBuffer, IN UINTN Value)
Restores the CPU context that was saved with SetJump().
INT64 INTN
Signed value of native width.
RETURN_STATUS EFIAPI StrHexToUint64S(IN CONST CHAR16 *String, OUT CHAR16 **EndPointer OPTIONAL, OUT UINT64 *Data)
Convert a Null-terminated Unicode hexadecimal string to a value of type UINT64.
INTN EFIAPI AsciiStrnCmp(IN CONST CHAR8 *FirstString, IN CONST CHAR8 *SecondString, IN UINTN Length)
Compares two Null-terminated ASCII strings with maximum lengths, and returns the difference between t...
INTN EFIAPI HighBitSet32(IN UINT32 Operand)
Returns the bit position of the highest bit set in a 32-bit value.
RETURN_STATUS EFIAPI Base64Decode(IN CONST CHAR8 *Source OPTIONAL, IN UINTN SourceSize, OUT UINT8 *Destination OPTIONAL, IN OUT UINTN *DestinationSize)
Decode Base64 ASCII encoded data to 8-bit binary representation, based on RFC4648.
UINT16 EFIAPI CalculateCrc16Ansi(IN CONST VOID *Buffer, IN UINTN Length, IN UINT16 InitialValue)
Calculates the CRC16-ANSI checksum of the given buffer.
RETURN_STATUS EFIAPI AsciiStrToUnicodeStrS(IN CONST CHAR8 *Source, OUT CHAR16 *Destination, IN UINTN DestMax)
Convert one Null-terminated ASCII string to a Null-terminated Unicode string.
BOOLEAN EFIAPI IsListEmpty(IN CONST LIST_ENTRY *ListHead)
Checks to see if a doubly linked list is empty or not.
LIST_ENTRY *EFIAPI SwapListEntries(IN OUT LIST_ENTRY *FirstEntry, IN OUT LIST_ENTRY *SecondEntry)
Swaps the location of two nodes in a doubly linked list, and returns the first node after the swap.
UINT32 EFIAPI BitFieldRead32(IN UINT32 Operand, IN UINTN StartBit, IN UINTN EndBit)
Returns a bit field from a 32-bit value.
LIST_ENTRY *EFIAPI GetNextNode(IN CONST LIST_ENTRY *List, IN CONST LIST_ENTRY *Node)
Retrieves the next node of a doubly linked list.
UINT32 EFIAPI CalculateCrc32(IN VOID *Buffer, IN UINTN Length)
Computes and returns a 32-bit CRC for a data buffer.
VOID EFIAPI EnableDisableInterrupts(VOID)
Enables CPU interrupts for the smallest window required to capture any pending interrupts.
UINT8 EFIAPI DecimalToBcd8(IN UINT8 Value)
Converts an 8-bit value to an 8-bit BCD value.
RETURN_STATUS EFIAPI AsciiStrCpyS(OUT CHAR8 *Destination, IN UINTN DestMax, IN CONST CHAR8 *Source)
Copies the string pointed to by Source (including the terminating null char) to the array pointed to ...
UINTN EFIAPI StrDecimalToUintn(IN CONST CHAR16 *String)
Convert a Null-terminated Unicode decimal string to a value of type UINTN.
UINT64 EFIAPI BitFieldWrite64(IN UINT64 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT64 Value)
Writes a bit field to a 64-bit value, and returns the result.
INTN EFIAPI AsciiStriCmp(IN CONST CHAR8 *FirstString, IN CONST CHAR8 *SecondString)
Performs a case insensitive comparison of two Null-terminated ASCII strings, and returns the differen...
BOOLEAN EFIAPI IsNull(IN CONST LIST_ENTRY *List, IN CONST LIST_ENTRY *Node)
Determines if a node in a doubly linked list is the head node of a the same doubly linked list.
UINT16 EFIAPI BitFieldAnd16(IN UINT16 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT16 AndData)
Reads a bit field from a 16-bit value, performs a bitwise AND, and returns the result.
RETURN_STATUS EFIAPI StrCatS(IN OUT CHAR16 *Destination, IN UINTN DestMax, IN CONST CHAR16 *Source)
Appends a copy of the string pointed to by Source (including the terminating null char) to the end of...
OFF16_t DI
di register as passed to the Option ROM initialisation routine.
VOID EFIAPI EnableInterrupts(VOID)
Enables CPU interrupts.
RETURN_STATUS EFIAPI AsciiStrHexToUintnS(IN CONST CHAR8 *String, OUT CHAR8 **EndPointer OPTIONAL, OUT UINTN *Data)
Convert a Null-terminated Ascii hexadecimal string to a value of type UINTN.
INTN(EFIAPI * BASE_SORT_COMPARE)(IN CONST VOID *Buffer1, IN CONST VOID *Buffer2)
Prototype for comparison function for any two element types.
UINT32 EFIAPI WriteUnaligned32(OUT UINT32 *Buffer, IN UINT32 Value)
Writes a 32-bit value to memory that may be unaligned.
UINT64 EFIAPI BitFieldAndThenOr64(IN UINT64 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT64 AndData, IN UINT64 OrData)
Reads a bit field from a 64-bit value, performs a bitwise AND followed by a bitwise OR,...
SEGSEL_t ES
es register as passed to the Option ROM initialisation routine.
static u16 S(u16 v)
Perform S-box mapping on a 16-bit value.
UINT16 EFIAPI BitFieldAndThenOr16(IN UINT16 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT16 AndData, IN UINT16 OrData)
Reads a bit field from a 16-bit value, performs a bitwise AND followed by a bitwise OR,...
PACKED struct @477::@491 Bits
VOID(EFIAPI * SWITCH_STACK_ENTRY_POINT)(IN VOID *Context1 OPTIONAL, IN VOID *Context2 OPTIONAL)
Function entry point used when a stack switch is requested with SwitchStack()
UINT8 EFIAPI BitFieldOr8(IN UINT8 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT8 OrData)
Reads a bit field from an 8-bit value, performs a bitwise OR, and returns the result.
BOOLEAN EFIAPI PathRemoveLastItem(IN OUT CHAR16 *Path)
Removes the last directory or file entry in a path.
UINT16 EFIAPI CalculateSum16(IN CONST UINT16 *Buffer, IN UINTN Length)
Returns the sum of all elements in a buffer of 16-bit values.
LIST_ENTRY *EFIAPI GetPreviousNode(IN CONST LIST_ENTRY *List, IN CONST LIST_ENTRY *Node)
Retrieves the previous node of a doubly linked list.
UINT16 EFIAPI CalculateCheckSum16(IN CONST UINT16 *Buffer, IN UINTN Length)
Returns the two's complement checksum of all elements in a buffer of 16-bit values.
INTN EFIAPI StrCmp(IN CONST CHAR16 *FirstString, IN CONST CHAR16 *SecondString)
Compares two Null-terminated Unicode strings, and returns the difference between the first mismatched...
UINT16_t DX
dx register as passed to the Option ROM initialisation routine.
UINT32 EFIAPI BitFieldOr32(IN UINT32 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT32 OrData)
Reads a bit field from a 32-bit value, performs a bitwise OR, and returns the result.
UINT64 EFIAPI StrDecimalToUint64(IN CONST CHAR16 *String)
Convert a Null-terminated Unicode decimal string to a value of type UINT64.
VOID EFIAPI SwitchStack(IN SWITCH_STACK_ENTRY_POINT EntryPoint, IN VOID *Context1 OPTIONAL, IN VOID *Context2 OPTIONAL, IN VOID *NewStack,...)
Transfers control to a function starting with a new stack.
UINT8 EFIAPI BcdToDecimal8(IN UINT8 Value)
Converts an 8-bit BCD value to an 8-bit value.
FILE_LICENCE(BSD2_PATENT)
UINT64 EFIAPI AsciiStrHexToUint64(IN CONST CHAR8 *String)
Convert a Null-terminated ASCII hexadecimal string to a value of type UINT64.
BOOLEAN EFIAPI GetInterruptState(VOID)
Retrieves the current CPU interrupt state.
UINT32 EFIAPI BitFieldAnd32(IN UINT32 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT32 AndData)
Reads a bit field from a 32-bit value, performs a bitwise AND, and returns the result.
UINT32 EFIAPI CalculateSum32(IN CONST UINT32 *Buffer, IN UINTN Length)
Returns the sum of all elements in a buffer of 32-bit values.
RETURN_STATUS EFIAPI AsciiStrDecimalToUintnS(IN CONST CHAR8 *String, OUT CHAR8 **EndPointer OPTIONAL, OUT UINTN *Data)
Convert a Null-terminated Ascii decimal string to a value of type UINTN.
UINT32 EFIAPI WriteUnaligned24(OUT UINT32 *Buffer, IN UINT32 Value)
Writes a 24-bit value to memory that may be unaligned.
UINT64 EFIAPI GetPowerOfTwo64(IN UINT64 Operand)
Returns the value of the highest bit set in a 64-bit value.
SEGOFF16_t Buffer
Buffer address.
RETURN_STATUS EFIAPI AsciiStrToIpv6Address(IN CONST CHAR8 *String, OUT CHAR8 **EndPointer OPTIONAL, OUT IPv6_ADDRESS *Address, OUT UINT8 *PrefixLength OPTIONAL)
Convert a Null-terminated ASCII string to IPv6 address and prefix length.
UINT64 EFIAPI BitFieldRead64(IN UINT64 Operand, IN UINTN StartBit, IN UINTN EndBit)
Returns a bit field from a 64-bit value.
RETURN_STATUS EFIAPI UnicodeStrToAsciiStrS(IN CONST CHAR16 *Source, OUT CHAR8 *Destination, IN UINTN DestMax)
Convert a Null-terminated Unicode string to a Null-terminated ASCII string.
INT64 EFIAPI DivS64x64Remainder(IN INT64 Dividend, IN INT64 Divisor, OUT INT64 *Remainder OPTIONAL)
Divides a 64-bit signed integer by a 64-bit signed integer and generates a 64-bit signed result and a...
UINT64 EFIAPI RShiftU64(IN UINT64 Operand, IN UINTN Count)
Shifts a 64-bit integer right between 0 and 63 bits.
UINT8 EFIAPI BitFieldAnd8(IN UINT8 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT8 AndData)
Reads a bit field from an 8-bit value, performs a bitwise AND, and returns the result.
UINT64 UINTN
Unsigned value of native width.
UINT16_t AX
ax register as passed to the Option ROM initialisation routine.
UINT64 EFIAPI LRotU64(IN UINT64 Operand, IN UINTN Count)
Rotates a 64-bit integer left between 0 and 63 bits, filling the low bits with the high bits that wer...
UINT16 EFIAPI WriteUnaligned16(OUT UINT16 *Buffer, IN UINT16 Value)
Writes a 16-bit value to memory that may be unaligned.
LIST_ENTRY *EFIAPI InsertHeadList(IN OUT LIST_ENTRY *ListHead, IN OUT LIST_ENTRY *Entry)
Adds a node to the beginning of a doubly linked list, and returns the pointer to the head node of the...
RETURN_STATUS EFIAPI StrToIpv4Address(IN CONST CHAR16 *String, OUT CHAR16 **EndPointer OPTIONAL, OUT IPv4_ADDRESS *Address, OUT UINT8 *PrefixLength OPTIONAL)
Convert a Null-terminated Unicode string to IPv4 address and prefix length.
RETURN_STATUS EFIAPI StrCpyS(OUT CHAR16 *Destination, IN UINTN DestMax, IN CONST CHAR16 *Source)
Copies the string pointed to by Source (including the terminating null char) to the array pointed to ...
RETURN_STATUS EFIAPI AsciiStrHexToBytes(IN CONST CHAR8 *String, IN UINTN Length, OUT UINT8 *Buffer, IN UINTN MaxBufferSize)
Convert a Null-terminated ASCII hexadecimal string to a byte array.
RETURNS_TWICE UINTN EFIAPI SetJump(OUT BASE_LIBRARY_JUMP_BUFFER *JumpBuffer)
Saves the current CPU context that can be restored with a call to LongJump() and returns 0.
#define VOID
Undeclared type.
UINT8 EFIAPI BitFieldRead8(IN UINT8 Operand, IN UINTN StartBit, IN UINTN EndBit)
Returns a bit field from an 8-bit value.
unsigned long long UINT64
RETURN_STATUS EFIAPI StrToGuid(IN CONST CHAR16 *String, OUT GUID *Guid)
Convert a Null-terminated Unicode GUID string to a value of type EFI_GUID.
UINT32 EFIAPI CalculateCrc32c(IN CONST VOID *Buffer, IN UINTN Length, IN UINT32 InitialValue)
Calculates the CRC32c checksum of the given buffer.
UINT16 EFIAPI BitFieldWrite16(IN UINT16 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT16 Value)
Writes a bit field to a 16-bit value, and returns the result.
_LIST_ENTRY structure definition.
UINT64 EFIAPI WriteUnaligned64(OUT UINT64 *Buffer, IN UINT64 Value)
Writes a 64-bit value to memory that may be unaligned.
UINTN EFIAPI AsciiStrSize(IN CONST CHAR8 *String)
Returns the size of a Null-terminated ASCII string in bytes, including the Null terminator.
RETURN_STATUS EFIAPI StrnCpyS(OUT CHAR16 *Destination, IN UINTN DestMax, IN CONST CHAR16 *Source, IN UINTN Length)
Copies not more than Length successive char from the string pointed to by Source to the array pointed...
UINT64 EFIAPI ARShiftU64(IN UINT64 Operand, IN UINTN Count)
Shifts a 64-bit integer right between 0 and 63 bits.
RETURN_STATUS EFIAPI AsciiStrCatS(IN OUT CHAR8 *Destination, IN UINTN DestMax, IN CONST CHAR8 *Source)
Appends a copy of the string pointed to by Source (including the terminating null char) to the end of...
VOID EFIAPI DisableInterrupts(VOID)
Disables CPU interrupts.
UINTN EFIAPI AsciiStrLen(IN CONST CHAR8 *String)
Returns the length of a Null-terminated ASCII string.
UINT64 EFIAPI LShiftU64(IN UINT64 Operand, IN UINTN Count)
Shifts a 64-bit integer left between 0 and 63 bits.
#define CONST
Datum is read-only.
CHAR8 *EFIAPI AsciiStrStr(IN CONST CHAR8 *String, IN CONST CHAR8 *SearchString)
Returns the first occurrence of a Null-terminated ASCII sub-string in a Null-terminated ASCII string.
UINT16 EFIAPI SwapBytes16(IN UINT16 Value)
Switches the endianness of a 16-bit integer.
RETURN_STATUS EFIAPI AsciiStrnCpyS(OUT CHAR8 *Destination, IN UINTN DestMax, IN CONST CHAR8 *Source, IN UINTN Length)
Copies not more than Length successive char from the string pointed to by Source to the array pointed...
RETURN_STATUS EFIAPI StrHexToUintnS(IN CONST CHAR16 *String, OUT CHAR16 **EndPointer OPTIONAL, OUT UINTN *Data)
Convert a Null-terminated Unicode hexadecimal string to a value of type UINTN.
RETURN_STATUS EFIAPI AsciiStrToIpv4Address(IN CONST CHAR8 *String, OUT CHAR8 **EndPointer OPTIONAL, OUT IPv4_ADDRESS *Address, OUT UINT8 *PrefixLength OPTIONAL)
Convert a Null-terminated ASCII string to IPv4 address and prefix length.
UINT32 EFIAPI RRotU32(IN UINT32 Operand, IN UINTN Count)
Rotates a 32-bit integer right between 0 and 31 bits, filling the high bits with the low bits that we...
VOID EFIAPI QuickSort(IN OUT VOID *BufferToSort, IN CONST UINTN Count, IN CONST UINTN ElementSize, IN BASE_SORT_COMPARE CompareFunction, OUT VOID *BufferOneElement)
This function is identical to perform QuickSort, except that is uses the pre-allocated buffer so the ...
RETURN_STATUS EFIAPI StrToIpv6Address(IN CONST CHAR16 *String, OUT CHAR16 **EndPointer OPTIONAL, OUT IPv6_ADDRESS *Address, OUT UINT8 *PrefixLength OPTIONAL)
Convert a Null-terminated Unicode string to IPv6 address and prefix length.
INTN EFIAPI StrnCmp(IN CONST CHAR16 *FirstString, IN CONST CHAR16 *SecondString, IN UINTN Length)
Compares up to a specified length the contents of two Null-terminated Unicode strings,...
CHAR16 *EFIAPI PathCleanUpDirectories(IN CHAR16 *Path)
Function to clean up paths.
UINT64 EFIAPI StrHexToUint64(IN CONST CHAR16 *String)
Convert a Null-terminated Unicode hexadecimal string to a value of type UINT64.
UINT32 EFIAPI CalculateCheckSum32(IN CONST UINT32 *Buffer, IN UINTN Length)
Returns the two's complement checksum of all elements in a buffer of 32-bit values.
UINT64 EFIAPI RRotU64(IN UINT64 Operand, IN UINTN Count)
Rotates a 64-bit integer right between 0 and 63 bits, filling the high bits with the high low bits th...
LIST_ENTRY *EFIAPI RemoveEntryList(IN CONST LIST_ENTRY *Entry)
Removes a node from a doubly linked list, and returns the node that follows the removed node.
UINT64 EFIAPI BitFieldAnd64(IN UINT64 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT64 AndData)
Reads a bit field from a 64-bit value, performs a bitwise AND, and returns the result.
CHAR16 EFIAPI CharToUpper(IN CHAR16 Char)
Convert a Unicode character to upper case only if it maps to a valid small-case ASCII character.
UINT64 EFIAPI DivU64x64Remainder(IN UINT64 Dividend, IN UINT64 Divisor, OUT UINT64 *Remainder OPTIONAL)
Divides a 64-bit unsigned integer by a 64-bit unsigned integer and generates a 64-bit unsigned result...
UINT32 EFIAPI LRotU32(IN UINT32 Operand, IN UINTN Count)
Rotates a 32-bit integer left between 0 and 31 bits, filling the low bits with the high bits that wer...
UINT32 EFIAPI ReadUnaligned32(IN CONST UINT32 *Buffer)
Reads a 32-bit value from memory that may be unaligned.
LIST_ENTRY *EFIAPI GetFirstNode(IN CONST LIST_ENTRY *List)
Retrieves the first node of a doubly linked list.
UINT8 EFIAPI BitFieldCountOnes32(IN UINT32 Operand, IN UINTN StartBit, IN UINTN EndBit)
Reads a bit field from a 32-bit value, counts and returns the number of set bits.
INTN EFIAPI LowBitSet64(IN UINT64 Operand)
Returns the bit position of the lowest bit set in a 64-bit value.
UINT64 EFIAPI SwapBytes64(IN UINT64 Value)
Switches the endianness of a 64-bit integer.
UINT64 EFIAPI CalculateCheckSum64(IN CONST UINT64 *Buffer, IN UINTN Length)
Returns the two's complement checksum of all elements in a buffer of 64-bit values.
INTN EFIAPI HighBitSet64(IN UINT64 Operand)
Returns the bit position of the highest bit set in a 64-bit value.
UINTN EFIAPI AsciiStrHexToUintn(IN CONST CHAR8 *String)
Convert a Null-terminated ASCII hexadecimal string to a value of type UINTN.
UINT8 EFIAPI BitFieldAndThenOr8(IN UINT8 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT8 AndData, IN UINT8 OrData)
Reads a bit field from an 8-bit value, performs a bitwise AND followed by a bitwise OR,...
UINT8 EFIAPI CalculateCheckSum8(IN CONST UINT8 *Buffer, IN UINTN Length)
Returns the two's complement checksum of all elements in a buffer of 8-bit values.
RETURN_STATUS EFIAPI AsciiStrHexToUint64S(IN CONST CHAR8 *String, OUT CHAR8 **EndPointer OPTIONAL, OUT UINT64 *Data)
Convert a Null-terminated Ascii hexadecimal string to a value of type UINT64.
UINT64 EFIAPI DivU64x32Remainder(IN UINT64 Dividend, IN UINT32 Divisor, OUT UINT32 *Remainder OPTIONAL)
Divides a 64-bit unsigned integer by a 32-bit unsigned integer and generates a 64-bit unsigned result...
UINT16 EFIAPI BitFieldRead16(IN UINT16 Operand, IN UINTN StartBit, IN UINTN EndBit)
Returns a bit field from a 16-bit value.
RETURN_STATUS EFIAPI StrnCatS(IN OUT CHAR16 *Destination, IN UINTN DestMax, IN CONST CHAR16 *Source, IN UINTN Length)
Appends not more than Length successive char from the string pointed to by Source to the end of the s...
VOID EFIAPI CpuBreakpoint(VOID)
Generates a breakpoint on the CPU.
RETURN_STATUS EFIAPI Base64Encode(IN CONST UINT8 *Source, IN UINTN SourceLength, OUT CHAR8 *Destination OPTIONAL, IN OUT UINTN *DestinationSize)
Convert binary data to a Base64 encoded ascii string based on RFC4648.
UINT64 EFIAPI CalculateSum64(IN CONST UINT64 *Buffer, IN UINTN Length)
Returns the sum of all elements in a buffer of 64-bit values.
UINT8 EFIAPI BitFieldWrite8(IN UINT8 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT8 Value)
Writes a bit field to an 8-bit value, and returns the result.
UINTN EFIAPI StrHexToUintn(IN CONST CHAR16 *String)
Convert a Null-terminated Unicode hexadecimal string to a value of type UINTN.
#define SMAP
Magic value for INT 15,e820 calls.
VOID EFIAPI CpuPause(VOID)
Requests CPU to pause for a short period of time.
BOOLEAN EFIAPI SetInterruptState(IN BOOLEAN InterruptState)
Set the current CPU interrupt state.
UINT32 EFIAPI BitFieldWrite32(IN UINT32 Operand, IN UINTN StartBit, IN UINTN EndBit, IN UINT32 Value)
Writes a bit field to a 32-bit value, and returns the result.
RETURN_STATUS EFIAPI AsciiStrToGuid(IN CONST CHAR8 *String, OUT GUID *Guid)
Convert a Null-terminated ASCII GUID string to a value of type EFI_GUID.
#define RETURNS_TWICE
Tell the code optimizer that the function will return twice.
VOID EFIAPI MemoryFence(VOID)
Used to serialize load and store operations.
CHAR8 EFIAPI AsciiCharToUpper(IN CHAR8 Chr)
Converts a lowercase Ascii character to upper one.
RETURN_STATUS EFIAPI StrHexToBytes(IN CONST CHAR16 *String, IN UINTN Length, OUT UINT8 *Buffer, IN UINTN MaxBufferSize)
Convert a Null-terminated Unicode hexadecimal string to a byte array.
UINT32 EFIAPI SwapBytes32(IN UINT32 Value)
Switches the endianness of a 32-bit integer.
UINTN EFIAPI StrLen(IN CONST CHAR16 *String)
Returns the length of a Null-terminated Unicode string.
UINT16_t BX
bx register as passed to the Option ROM initialisation routine.
UINT64 EFIAPI AsciiStrDecimalToUint64(IN CONST CHAR8 *String)
Convert a Null-terminated ASCII decimal string to a value of type UINT64.
VOID EFIAPI SpeculationBarrier(VOID)
Uses as a barrier to stop speculative execution.