/** @file\r
Library that provides processor specific library services\r
\r
- Copyright (c) 2006, Intel Corporation \r
+ Copyright (c) 2006 - 2008, Intel Corporation \r
All rights reserved. This program and the accompanying materials \r
are licensed and made available under the terms and conditions of the BSD License \r
which accompanies this distribution. The full text of the license may be found at \r
VOID
);
-
-/**
- Requests CPU to pause for a short period of time.
-
- Requests CPU to pause for a short period of time. Typically used in MP
- systems to prevent memory starvation while waiting for a spin lock.
-
-**/
-VOID
-EFIAPI
-CpuPause (
- VOID
- );
-
-
/**
Flushes all the Translation Lookaside Buffers(TLB) entries in a CPU.
+++ /dev/null
-#------------------------------------------------------------------------------ ;\r
-# Copyright (c) 2006, Intel Corporation\r
-# All rights reserved. This program and the accompanying materials\r
-# are licensed and made available under the terms and conditions of the BSD License\r
-# which accompanies this distribution. The full text of the license may be found at\r
-# http://opensource.org/licenses/bsd-license.php\r
-#\r
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-#\r
-# Module Name:\r
-#\r
-# CpuSleep.Asm\r
-#\r
-# Abstract:\r
-#\r
-# CpuSleep function\r
-#\r
-# Notes:\r
-#\r
-#------------------------------------------------------------------------------\r
-\r
-.globl ASM_PFX(CpuSleep)\r
-\r
-#------------------------------------------------------------------------------\r
-# VOID\r
-# EFIAPI\r
-# CpuSleep (\r
-# VOID\r
-# );\r
-#------------------------------------------------------------------------------\r
-ASM_PFX(CpuSleep):\r
- hlt\r
- ret\r
+++ /dev/null
-;------------------------------------------------------------------------------ ;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this distribution. The full text of the license may be found at\r
-; http://opensource.org/licenses/bsd-license.php\r
-;\r
-; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-;\r
-; Module Name:\r
-;\r
-; CpuSleep.Asm\r
-;\r
-; Abstract:\r
-;\r
-; CpuSleep function\r
-;\r
-; Notes:\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
- .386\r
- .model flat,C\r
- .code\r
-\r
-;------------------------------------------------------------------------------\r
-; VOID\r
-; EFIAPI\r
-; CpuSleep (\r
-; VOID\r
-; );\r
-;------------------------------------------------------------------------------\r
-CpuSleep PROC\r
- hlt\r
- ret\r
-CpuSleep ENDP\r
-\r
- END\r
+++ /dev/null
-/** @file\r
- CpuSleep function.\r
-\r
- Copyright (c) 2006 - 2007, Intel Corporation<BR>\r
- All rights reserved. This program and the accompanying materials\r
- are licensed and made available under the terms and conditions of the BSD License\r
- which accompanies this distribution. The full text of the license may be found at\r
- http://opensource.org/licenses/bsd-license.php\r
-\r
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-\r
-**/\r
-\r
-//\r
-// Include common header file for this module.\r
-//\r
-\r
-\r
-/**\r
- Places the CPU in a sleep state until an interrupt is received.\r
-\r
- Places the CPU in a sleep state until an interrupt is received. If interrupts\r
- are disabled prior to calling this function, then the CPU will be placed in a\r
- sleep state indefinitely.\r
-\r
-**/\r
-VOID\r
-EFIAPI\r
-CpuSleep (\r
- VOID\r
- )\r
-{\r
- _asm {\r
- hlt\r
- }\r
-}\r
-\r
+++ /dev/null
-#------------------------------------------------------------------------------ ;\r
-# Copyright (c) 2006, Intel Corporation\r
-# All rights reserved. This program and the accompanying materials\r
-# are licensed and made available under the terms and conditions of the BSD License\r
-# which accompanies this distribution. The full text of the license may be found at\r
-# http://opensource.org/licenses/bsd-license.php\r
-#\r
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-#\r
-# Module Name:\r
-#\r
-# CpuSleep.S\r
-#\r
-# Abstract:\r
-#\r
-# CpuSleep function\r
-#\r
-# Notes:\r
-#\r
-#------------------------------------------------------------------------------\r
-\r
-\r
-#------------------------------------------------------------------------------\r
-# VOID\r
-# EFIAPI\r
-# CpuSleep (\r
-# VOID\r
-# );\r
-#------------------------------------------------------------------------------\r
-.global ASM_PFX(CpuSleep)\r
-ASM_PFX(CpuSleep):\r
- hlt\r
- ret\r
+++ /dev/null
-;------------------------------------------------------------------------------ ;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this distribution. The full text of the license may be found at\r
-; http://opensource.org/licenses/bsd-license.php\r
-;\r
-; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-;\r
-; Module Name:\r
-;\r
-; CpuSleep.Asm\r
-;\r
-; Abstract:\r
-;\r
-; CpuSleep function\r
-;\r
-; Notes:\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
- .code\r
-\r
-;------------------------------------------------------------------------------\r
-; VOID\r
-; EFIAPI\r
-; CpuSleep (\r
-; VOID\r
-; );\r
-;------------------------------------------------------------------------------\r
-CpuSleep PROC\r
- hlt\r
- ret\r
-CpuSleep ENDP\r
-\r
- END\r
Ia32/CpuFlushTlb.S | GCC \r
\r
[Sources.X64]\r
- X64/CpuFlushTlb.asm\r
+ X64/CpuFlushTlb.asm \r
X64/CpuSleep.asm\r
\r
X64/CpuSleep.S | GCC \r
\r
[LibraryClasses.Ipf]\r
PalCallLib\r
-\r
-\r
-[Pcd.common]\r
-\r
+++ /dev/null
-#------------------------------------------------------------------------------ ;\r
-# Copyright (c) 2006, Intel Corporation\r
-# All rights reserved. This program and the accompanying materials\r
-# are licensed and made available under the terms and conditions of the BSD License\r
-# which accompanies this distribution. The full text of the license may be found at\r
-# http://opensource.org/licenses/bsd-license.php\r
-#\r
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-#\r
-# Module Name:\r
-#\r
-# CpuPause.Asm\r
-#\r
-# Abstract:\r
-#\r
-# CpuPause function\r
-#\r
-# Notes:\r
-#\r
-#------------------------------------------------------------------------------\r
-\r
-.globl ASM_PFX(CpuPause)\r
-\r
-#------------------------------------------------------------------------------\r
-# VOID\r
-# EFIAPI\r
-# CpuPause (\r
-# VOID\r
-# );\r
-#------------------------------------------------------------------------------\r
-ASM_PFX(CpuPause):\r
- pause\r
- ret\r
+++ /dev/null
-;------------------------------------------------------------------------------ ;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this distribution. The full text of the license may be found at\r
-; http://opensource.org/licenses/bsd-license.php\r
-;\r
-; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-;\r
-; Module Name:\r
-;\r
-; CpuPause.Asm\r
-;\r
-; Abstract:\r
-;\r
-; CpuPause function\r
-;\r
-; Notes:\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
- .686\r
- .model flat,C\r
- .xmm\r
- .code\r
-\r
-;------------------------------------------------------------------------------\r
-; VOID\r
-; EFIAPI\r
-; CpuPause (\r
-; VOID\r
-; );\r
-;------------------------------------------------------------------------------\r
-CpuPause PROC\r
- pause\r
- ret\r
-CpuPause ENDP\r
-\r
- END\r
+++ /dev/null
-/** @file\r
- CpuPause function.\r
-\r
- Copyright (c) 2006 - 2007, Intel Corporation<BR>\r
- All rights reserved. This program and the accompanying materials\r
- are licensed and made available under the terms and conditions of the BSD License\r
- which accompanies this distribution. The full text of the license may be found at\r
- http://opensource.org/licenses/bsd-license.php\r
-\r
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-\r
-**/\r
-\r
-\r
-/**\r
- Places the CPU in a pause state until an interrupt is\r
- received.\r
-\r
- Places the CPU in a pause state until an interrupt is\r
- received. If interrupts are disabled prior to calling this\r
- function, then the CPU will be placed in a pause state\r
- indefinitely.\r
-\r
-**/\r
-VOID\r
-EFIAPI\r
-CpuPause (\r
- VOID\r
- )\r
-{\r
- _asm {\r
- pause\r
- }\r
-}\r
-\r
+++ /dev/null
-/// @file\r
-/// CpuPause() function for Itanium-based architecture.\r
-///\r
-/// Copyright (c) 2006, Intel Corporation\r
-/// All rights reserved. This program and the accompanying materials\r
-/// are licensed and made available under the terms and conditions of the BSD License\r
-/// which accompanies this distribution. The full text of the license may be found at\r
-/// http://opensource.org/licenses/bsd-license.php\r
-///\r
-/// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-/// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-///\r
-/// Module Name: CpuPause.s\r
-///\r
-///\r
-\r
-.auto\r
-.text\r
-\r
-.proc CpuPause\r
-.type CpuPause, @function\r
-CpuPause::\r
- hint @pause\r
- br.ret.sptk.many b0\r
-.endp\r
+++ /dev/null
-#------------------------------------------------------------------------------ ;\r
-# Copyright (c) 2006, Intel Corporation\r
-# All rights reserved. This program and the accompanying materials\r
-# are licensed and made available under the terms and conditions of the BSD License\r
-# which accompanies this distribution. The full text of the license may be found at\r
-# http://opensource.org/licenses/bsd-license.php\r
-#\r
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-#\r
-# Module Name:\r
-#\r
-# CpuPause.S\r
-#\r
-# Abstract:\r
-#\r
-# CpuPause function\r
-#\r
-# Notes:\r
-#\r
-#------------------------------------------------------------------------------\r
-\r
-\r
-#------------------------------------------------------------------------------\r
-# VOID\r
-# EFIAPI\r
-# CpuPause (\r
-# VOID\r
-# );\r
-#------------------------------------------------------------------------------\r
-.global ASM_PFX(CpuPause)\r
-ASM_PFX(CpuPause):\r
- pause\r
- ret\r
+++ /dev/null
-;------------------------------------------------------------------------------ ;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this distribution. The full text of the license may be found at\r
-; http://opensource.org/licenses/bsd-license.php\r
-;\r
-; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-;\r
-; Module Name:\r
-;\r
-; CpuPause.Asm\r
-;\r
-; Abstract:\r
-;\r
-; CpuPause function\r
-;\r
-; Notes:\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
- .code\r
-\r
-;------------------------------------------------------------------------------\r
-; VOID\r
-; EFIAPI\r
-; CpuPause (\r
-; VOID\r
-; );\r
-;------------------------------------------------------------------------------\r
-CpuPause PROC\r
- pause\r
- ret\r
-CpuPause ENDP\r
-\r
- END\r
//\r
for (Index = 0; Index < NumberOfPackages; Index++) {\r
PackageArray = (UINT8 *) VA_ARG (Marker, VOID *);\r
+ //\r
+ // CopyMem is used for UINT32 to cover the unaligned address access.\r
+ //\r
CopyMem (&PackageLength, PackageArray, sizeof (UINT32));\r
PackageLength -= sizeof (UINT32);\r
PackageArray += sizeof (UINT32);\r
End.Header.Scope = 0;
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_END to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &End, sizeof (EFI_IFR_END));
Data->Offset += sizeof (EFI_IFR_END);
CopyMem (&Default.Value, Value, sizeof(EFI_IFR_TYPE_VALUE));
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_DEFAULT to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &Default, sizeof (EFI_IFR_DEFAULT));
Data->Offset += sizeof (EFI_IFR_DEFAULT);
Action.QuestionConfig = QuestionConfig;
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_ACTION to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &Action, sizeof (EFI_IFR_ACTION));
Data->Offset += sizeof (EFI_IFR_ACTION);
Subtitle.Flags = Flags;
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_SUBTITLE to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &Subtitle, sizeof (EFI_IFR_SUBTITLE));
Data->Offset += sizeof (EFI_IFR_SUBTITLE);
Text.TextTwo = TextTwo;
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_TEXT to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &Text, sizeof (EFI_IFR_TEXT));
Data->Offset += sizeof (EFI_IFR_TEXT);
Goto.FormId = FormId;
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_REF to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &Goto, sizeof (EFI_IFR_REF));
Data->Offset += sizeof (EFI_IFR_REF);
OneOfOption.Type = Type;
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_ONF_OF_OPTION to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &OneOfOption, sizeof (EFI_IFR_ONE_OF_OPTION));
Data->Offset += sizeof (EFI_IFR_ONE_OF_OPTION);
}
ZeroMem ((VOID *) &OneOf.data, sizeof (MINMAXSTEP_DATA));
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_ONF_OF to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &OneOf, sizeof (EFI_IFR_ONE_OF));
Data->Offset += sizeof (EFI_IFR_ONE_OF);
OrderedList.Flags = OrderedListFlags;
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_ORDERED_LIST to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &OrderedList, sizeof (EFI_IFR_ORDERED_LIST));
Data->Offset += sizeof (EFI_IFR_ORDERED_LIST);
CheckBox.Flags = CheckBoxFlags;
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_CHECKBOX to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &CheckBox, sizeof (EFI_IFR_CHECKBOX));
Data->Offset += sizeof (EFI_IFR_CHECKBOX);
CopyMem (&Numeric.data, &MinMaxStep, sizeof (MINMAXSTEP_DATA));
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_NUMERIC to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &Numeric, sizeof (EFI_IFR_NUMERIC));
Data->Offset += sizeof (EFI_IFR_NUMERIC);
String.Flags = StringFlags;
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
+ //
+ // CopyMem is used for EFI_IFR_STRING to cover the unaligned address access.
+ //
CopyMem (LocalBuffer, &String, sizeof (EFI_IFR_STRING));
Data->Offset += sizeof (EFI_IFR_STRING);