TianoCore EDK2 master
Loading...
Searching...
No Matches
StatusCode.c
Go to the documentation of this file.
1
9#include "PeiMain.h"
10
28EFIAPI
30 IN CONST EFI_PEI_SERVICES **PeiServices,
31 IN EFI_STATUS_CODE_TYPE CodeType,
33 IN UINT32 Instance,
34 IN CONST EFI_GUID *CallerId,
35 IN CONST EFI_STATUS_CODE_DATA *Data OPTIONAL
36 )
37{
38 EFI_STATUS Status;
39 EFI_PEI_PROGRESS_CODE_PPI *StatusCodePpi;
40
41 //
42 // Locate StatusCode Ppi.
43 //
44 Status = PeiServicesLocatePpi (
45 &gEfiPeiStatusCodePpiGuid,
46 0,
47 NULL,
48 (VOID **)&StatusCodePpi
49 );
50
51 if (!EFI_ERROR (Status)) {
52 Status = StatusCodePpi->ReportStatusCode (
53 PeiServices,
54 CodeType,
55 Value,
56 Instance,
57 CallerId,
58 Data
59 );
60
61 return Status;
62 }
63
65}
EFI_STATUS EFIAPI PeiServicesLocatePpi(IN CONST EFI_GUID *Guid, IN UINTN Instance, IN OUT EFI_PEI_PPI_DESCRIPTOR **PpiDescriptor, IN OUT VOID **Ppi)
#define NULL
Definition: Base.h:319
#define CONST
Definition: Base.h:259
#define IN
Definition: Base.h:279
#define EFI_NOT_AVAILABLE_YET
Definition: PiMultiPhase.h:54
UINT32 EFI_STATUS_CODE_VALUE
Definition: PiStatusCode.h:67
UINT32 EFI_STATUS_CODE_TYPE
Definition: PiStatusCode.h:24
EFI_STATUS EFIAPI PeiReportStatusCode(IN CONST EFI_PEI_SERVICES **PeiServices, IN EFI_STATUS_CODE_TYPE CodeType, IN EFI_STATUS_CODE_VALUE Value, IN UINT32 Instance, IN CONST EFI_GUID *CallerId, IN CONST EFI_STATUS_CODE_DATA *Data OPTIONAL)
Definition: StatusCode.c:29
RETURN_STATUS EFI_STATUS
Definition: UefiBaseType.h:29
Definition: Base.h:213