Provides string functions, linked list functions, math functions, synchronization\r
functions, and CPU architecture-specific functions.\r
\r
-Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.<BR>\r
Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>\r
This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
\r
#endif // defined (MDE_CPU_ARM)\r
\r
+#if defined (MDE_CPU_AARCH64)\r
+typedef struct {\r
+ // GP regs\r
+ UINT64 X19;\r
+ UINT64 X20;\r
+ UINT64 X21;\r
+ UINT64 X22;\r
+ UINT64 X23;\r
+ UINT64 X24;\r
+ UINT64 X25;\r
+ UINT64 X26;\r
+ UINT64 X27;\r
+ UINT64 X28;\r
+ UINT64 FP;\r
+ UINT64 LR;\r
+ UINT64 IP0;\r
+\r
+ // FP regs\r
+ UINT64 D8;\r
+ UINT64 D9;\r
+ UINT64 D10;\r
+ UINT64 D11;\r
+ UINT64 D12;\r
+ UINT64 D13;\r
+ UINT64 D14;\r
+ UINT64 D15;\r
+} BASE_LIBRARY_JUMP_BUFFER;\r
+\r
+#define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 8\r
+\r
+#endif // defined (MDE_CPU_AARCH64)\r
+\r
+\r
//\r
// String Services\r
//\r
If Entry is NULL, then ASSERT().\r
If ListHead was not initialized with INTIALIZE_LIST_HEAD_VARIABLE() or\r
InitializeListHead(), then ASSERT().\r
- If PcdMaximumLinkedListLenth is not zero, and prior to insertion the number\r
+ If PcdMaximumLinkedListLength is not zero, and prior to insertion the number\r
of nodes in ListHead, including the ListHead node, is greater than or\r
equal to PcdMaximumLinkedListLength, then ASSERT().\r
\r
If Entry is NULL, then ASSERT().\r
If ListHead was not initialized with INTIALIZE_LIST_HEAD_VARIABLE() or \r
InitializeListHead(), then ASSERT().\r
- If PcdMaximumLinkedListLenth is not zero, and prior to insertion the number\r
+ If PcdMaximumLinkedListLength is not zero, and prior to insertion the number\r
of nodes in ListHead, including the ListHead node, is greater than or\r
equal to PcdMaximumLinkedListLength, then ASSERT().\r
\r
If List is NULL, then ASSERT().\r
If List was not initialized with INTIALIZE_LIST_HEAD_VARIABLE() or \r
InitializeListHead(), then ASSERT().\r
- If PcdMaximumLinkedListLenth is not zero, and the number of nodes\r
+ If PcdMaximumLinkedListLength is not zero, and the number of nodes\r
in List, including the List node, is greater than or equal to\r
PcdMaximumLinkedListLength, then ASSERT().\r
\r
@param List A pointer to the head node of a doubly linked list.\r
\r
@return The first node of a doubly linked list.\r
- @retval NULL The list is empty.\r
+ @retval List The list is empty.\r
\r
**/\r
LIST_ENTRY *\r
If Node is NULL, then ASSERT().\r
If List was not initialized with INTIALIZE_LIST_HEAD_VARIABLE() or \r
InitializeListHead(), then ASSERT().\r
- If PcdMaximumLinkedListLenth is not zero, and List contains more than\r
- PcdMaximumLinkedListLenth nodes, then ASSERT().\r
+ If PcdMaximumLinkedListLength is not zero, and List contains more than\r
+ PcdMaximumLinkedListLength nodes, then ASSERT().\r
If PcdVerifyNodeInList is TRUE and Node is not a node in List, then ASSERT().\r
\r
@param List A pointer to the head node of a doubly linked list.\r
If Node is NULL, then ASSERT().\r
If List was not initialized with INTIALIZE_LIST_HEAD_VARIABLE() or \r
InitializeListHead(), then ASSERT().\r
- If PcdMaximumLinkedListLenth is not zero, and List contains more than\r
- PcdMaximumLinkedListLenth nodes, then ASSERT().\r
+ If PcdMaximumLinkedListLength is not zero, and List contains more than\r
+ PcdMaximumLinkedListLength nodes, then ASSERT().\r
If PcdVerifyNodeInList is TRUE and Node is not a node in List, then ASSERT().\r
\r
@param List A pointer to the head node of a doubly linked list.\r
If ListHead is NULL, then ASSERT().\r
If ListHead was not initialized with INTIALIZE_LIST_HEAD_VARIABLE() or \r
InitializeListHead(), then ASSERT().\r
- If PcdMaximumLinkedListLenth is not zero, and the number of nodes\r
+ If PcdMaximumLinkedListLength is not zero, and the number of nodes\r
in List, including the List node, is greater than or equal to\r
PcdMaximumLinkedListLength, then ASSERT().\r
\r
If Node is NULL, then ASSERT().\r
If List was not initialized with INTIALIZE_LIST_HEAD_VARIABLE() or InitializeListHead(), \r
then ASSERT().\r
- If PcdMaximumLinkedListLenth is not zero, and the number of nodes\r
+ If PcdMaximumLinkedListLength is not zero, and the number of nodes\r
in List, including the List node, is greater than or equal to\r
PcdMaximumLinkedListLength, then ASSERT().\r
If PcdVerifyNodeInList is TRUE and Node is not a node in List the and Node is not equal \r
If Node is NULL, then ASSERT().\r
If List was not initialized with INTIALIZE_LIST_HEAD_VARIABLE() or\r
InitializeListHead(), then ASSERT().\r
- If PcdMaximumLinkedListLenth is not zero, and the number of nodes\r
+ If PcdMaximumLinkedListLength is not zero, and the number of nodes\r
in List, including the List node, is greater than or equal to\r
PcdMaximumLinkedListLength, then ASSERT().\r
If PcdVerifyNodeInList is TRUE and Node is not a node in List, then ASSERT().\r
If StartBit is greater than 7, then ASSERT().\r
If EndBit is greater than 7, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If Value is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 7, then ASSERT().\r
If EndBit is greater than 7, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 7, then ASSERT().\r
If EndBit is greater than 7, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 7, then ASSERT().\r
If EndBit is greater than 7, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 15, then ASSERT().\r
If EndBit is greater than 15, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If Value is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 15, then ASSERT().\r
If EndBit is greater than 15, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 15, then ASSERT().\r
If EndBit is greater than 15, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 15, then ASSERT().\r
If EndBit is greater than 15, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 31, then ASSERT().\r
If EndBit is greater than 31, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If Value is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 31, then ASSERT().\r
If EndBit is greater than 31, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 31, then ASSERT().\r
If EndBit is greater than 31, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 31, then ASSERT().\r
If EndBit is greater than 31, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 63, then ASSERT().\r
If EndBit is greater than 63, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If Value is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 63, then ASSERT().\r
If EndBit is greater than 63, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 63, then ASSERT().\r
If EndBit is greater than 63, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 63, then ASSERT().\r
If EndBit is greater than 63, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Operand Operand on which to perform the bitfield operation.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 31, then ASSERT().\r
If EndBit is greater than 31, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If Value is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Index The 32-bit MSR index to write.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 31, then ASSERT().\r
If EndBit is greater than 31, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Index The 32-bit MSR index to write.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 31, then ASSERT().\r
If EndBit is greater than 31, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Index The 32-bit MSR index to write.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 31, then ASSERT().\r
If EndBit is greater than 31, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Index The 32-bit MSR index to write.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 63, then ASSERT().\r
If EndBit is greater than 63, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If Value is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Index The 32-bit MSR index to write.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 63, then ASSERT().\r
If EndBit is greater than 63, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Index The 32-bit MSR index to write.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 63, then ASSERT().\r
If EndBit is greater than 63, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Index The 32-bit MSR index to write.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
If StartBit is greater than 63, then ASSERT().\r
If EndBit is greater than 63, then ASSERT().\r
If EndBit is less than StartBit, then ASSERT().\r
+ If AndData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
+ If OrData is larger than the bitmask value range specified by StartBit and EndBit, then ASSERT().\r
\r
@param Index The 32-bit MSR index to write.\r
@param StartBit The ordinal of the least significant bit in the bit field.\r
VOID\r
EFIAPI\r
AsmPrepareThunk16 (\r
- OUT THUNK_CONTEXT *ThunkContext\r
+ IN OUT THUNK_CONTEXT *ThunkContext\r
);\r
\r
\r