2 In EndOfPei notify, it will call FspNotifyPhase API.
4 Copyright (c) 2014 - 2015, Intel Corporation. All rights reserved.<BR>
5 This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php.
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
16 #include "FspInitPei.h"
19 This function handles S3 resume task at the end of PEI
21 @param[in] PeiServices Pointer to PEI Services Table.
22 @param[in] NotifyDesc Pointer to the descriptor for the Notification event that
23 caused this function to execute.
24 @param[in] Ppi Pointer to the PPI data associated with this function.
26 @retval EFI_STATUS Always return EFI_SUCCESS
31 IN EFI_PEI_SERVICES
**PeiServices
,
32 IN EFI_PEI_NOTIFY_DESCRIPTOR
*NotifyDesc
,
36 EFI_PEI_NOTIFY_DESCRIPTOR mS3EndOfPeiNotifyDesc
= {
37 (EFI_PEI_PPI_DESCRIPTOR_NOTIFY_CALLBACK
| EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST
),
38 &gEfiEndOfPeiSignalPpiGuid
,
43 This function handles S3 resume task at the end of PEI
45 @param[in] PeiServices Pointer to PEI Services Table.
46 @param[in] NotifyDesc Pointer to the descriptor for the Notification event that
47 caused this function to execute.
48 @param[in] Ppi Pointer to the PPI data associated with this function.
50 @retval EFI_STATUS Always return EFI_SUCCESS
55 IN EFI_PEI_SERVICES
**PeiServices
,
56 IN EFI_PEI_NOTIFY_DESCRIPTOR
*NotifyDesc
,
60 NOTIFY_PHASE_PARAMS NotifyPhaseParams
;
62 FSP_INFO_HEADER
*FspHeader
;
64 FspHeader
= FspFindFspHeader (PcdGet32 (PcdFlashFvFspBase
));
65 if (FspHeader
== NULL
) {
66 return EFI_DEVICE_ERROR
;
69 DEBUG ((DEBUG_INFO
, "S3EndOfPeiNotify enter\n"));
71 NotifyPhaseParams
.Phase
= EnumInitPhaseAfterPciEnumeration
;
72 Status
= CallFspNotifyPhase (FspHeader
, &NotifyPhaseParams
);
73 DEBUG((DEBUG_INFO
, "FSP S3NotifyPhase AfterPciEnumeration status: 0x%x\n", Status
));
75 NotifyPhaseParams
.Phase
= EnumInitPhaseReadyToBoot
;
76 Status
= CallFspNotifyPhase (FspHeader
, &NotifyPhaseParams
);
77 DEBUG((DEBUG_INFO
, "FSP S3NotifyPhase ReadyToBoot status: 0x%x\n", Status
));