+++ /dev/null
-/*++\r
-\r
-Copyright (c) 2007, Intel Corporation. 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
-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
-Module Name:\r
-\r
- PeiServicePointer.c\r
-\r
-Abstract:\r
-\r
---*/\r
-\r
-#include "Tiano.h"\r
-#include "PeiApi.h"\r
-#include "PeiLib.h"\r
-\r
-\r
-#if (PI_SPECIFICATION_VERSION >= 0x00010000)\r
-\r
-VOID\r
-SetPeiServicesTablePointer (\r
- IN EFI_PEI_SERVICES **PeiServices\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Save PeiService pointer so that it can be retrieved anywhere.\r
-\r
-Arguments:\r
-\r
- PeiServices - The direct pointer to PeiServiceTable.\r
- PhyscialAddress - The physcial address of variable PeiServices.\r
- \r
-Returns:\r
- NONE\r
- \r
---*/ \r
- \r
-{\r
- //\r
- // For Itanium Processor Family processors, the EFI_PEI_SERVICES**\r
- // is stored in kernel register7.\r
- //\r
- AsmWriteKr7((UINT64)(UINTN)PeiServices);\r
-}\r
-\r
-\r
-EFI_PEI_SERVICES **\r
-GetPeiServicesTablePointer (\r
- VOID\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Get PeiService pointer.\r
-\r
-Arguments:\r
-\r
- NONE.\r
- \r
-Returns:\r
- The direct pointer to PeiServiceTable.\r
- \r
---*/ \r
- \r
-{\r
- //\r
- // For Itanium Processor Family processors, the EFI_PEI_SERVICES**\r
- // is stored in kernel register7.\r
- //\r
- return (EFI_PEI_SERVICES **)(UINTN)AsmReadKr7();\r
-}\r
-\r
-VOID\r
-MigrateIdtTable (\r
- IN EFI_PEI_SERVICES **PeiServices\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Migrate IDT from temporary memory to real memory where preceded with 4 bytes for\r
- storing PeiService pointer.\r
-\r
-Arguments:\r
-\r
- PeiServices - The direct pointer to PeiServiceTable.\r
- \r
-Returns:\r
-\r
- NONE.\r
- \r
---*/ \r
-{\r
- return;\r
-}\r
-\r
-#endif\r