]> git.proxmox.com Git - mirror_edk2.git/blobdiff - IntelFspPkg/FspSecCore/SecMain.c
IntelFspPkg: correct comments and rename a label
[mirror_edk2.git] / IntelFspPkg / FspSecCore / SecMain.c
index 22706c8a8bc5493b13237be2499fe7f8eb5126f0..99acefaefa20cb8dc2a258e77da9a41748d047a4 100644 (file)
@@ -1,6 +1,6 @@
 /** @file\r
 \r
-  Copyright (c) 2014, Intel Corporation. All rights reserved.<BR>\r
+  Copyright (c) 2014 - 2015, 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
@@ -41,6 +41,9 @@ UINT64  mIdtEntryTemplate = 0xffff8e000008ffe4ULL;
   @param[in] SizeOfRam          Size of the temporary memory available for use.\r
   @param[in] TempRamBase        Base address of tempory ram\r
   @param[in] BootFirmwareVolume Base address of the Boot Firmware Volume.\r
+  @param[in] PeiCore            PeiCore entry point.\r
+  @param[in] BootLoaderStack    BootLoader stack.\r
+  @param[in] ApiIdx             the index of API.\r
 \r
   @return This function never returns.\r
 \r
@@ -50,7 +53,10 @@ EFIAPI
 SecStartup (\r
   IN UINT32                   SizeOfRam,\r
   IN UINT32                   TempRamBase,\r
-  IN VOID                    *BootFirmwareVolume\r
+  IN VOID                    *BootFirmwareVolume,\r
+  IN PEI_CORE_ENTRY           PeiCore,\r
+  IN UINT32                   BootLoaderStack,\r
+  IN UINT32                   ApiIdx\r
   )\r
 {\r
   EFI_SEC_PEI_HAND_OFF        SecCoreData;\r
@@ -58,7 +64,6 @@ SecStartup (
   SEC_IDT_TABLE               IdtTableInStack;\r
   UINT32                      Index;\r
   FSP_GLOBAL_DATA             PeiFspData;\r
-  PEI_CORE_ENTRY              PeiCore;\r
   UINT64                      ExceptionHandler;\r
 \r
   //\r
@@ -99,9 +104,9 @@ SecStartup (
   AsmWriteIdtr (&IdtDescriptor);\r
 \r
   //\r
-  // Iniitalize the global FSP data region\r
+  // Initialize the global FSP data region\r
   //\r
-  FspGlobalDataInit (&PeiFspData, &BootFirmwareVolume);\r
+  FspGlobalDataInit (&PeiFspData, BootLoaderStack, (UINT8)ApiIdx);\r
 \r
   //\r
   // Update the base address and length of Pei temporary memory\r
@@ -118,8 +123,7 @@ SecStartup (
 \r
   //\r
   // Call PeiCore Entry\r
-  //\r
-  PeiCore = (PEI_CORE_ENTRY)(*(UINTN *)((&BootFirmwareVolume) + 1));\r
+  //  \r
   PeiCore (&SecCoreData, mPeiSecPlatformInformationPpi);\r
 \r
   //\r