TianoCore EDK2 master
Loading...
Searching...
No Matches
SecBist.c File Reference
#include "SecMain.h"

Go to the source code of this file.

Functions

EFI_STATUS GetBistFromHob (IN OUT UINT64 *StructureSize, IN OUT VOID *StructureBuffer)
 
EFI_STATUS EFIAPI SecPlatformInformationBist (IN CONST EFI_PEI_SERVICES **PeiServices, IN OUT UINT64 *StructureSize, OUT EFI_SEC_PLATFORM_INFORMATION_RECORD *PlatformInformationRecord)
 
EFI_STATUS EFIAPI SecPlatformInformation2Bist (IN CONST EFI_PEI_SERVICES **PeiServices, IN OUT UINT64 *StructureSize, OUT EFI_SEC_PLATFORM_INFORMATION_RECORD2 *PlatformInformationRecord2)
 
EFI_STATUS GetBistInfoFromPpi (IN CONST EFI_PEI_SERVICES **PeiServices, IN CONST EFI_GUID *Guid, OUT EFI_PEI_PPI_DESCRIPTOR **PpiDescriptor, OUT VOID **BistInformationData, OUT UINT64 *BistInformationSize OPTIONAL)
 
VOID RepublishSecPlatformInformationPpi (VOID)
 

Variables

EFI_SEC_PLATFORM_INFORMATION_PPI mSecPlatformInformation
 
EFI_PEI_PPI_DESCRIPTOR mPeiSecPlatformInformation
 
EFI_SEC_PLATFORM_INFORMATION2_PPI mSecPlatformInformation2
 
EFI_PEI_PPI_DESCRIPTOR mPeiSecPlatformInformation2
 

Detailed Description

Get SEC platform information(2) PPI and reinstall it.

Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file SecBist.c.

Function Documentation

◆ GetBistFromHob()

EFI_STATUS GetBistFromHob ( IN OUT UINT64 *  StructureSize,
IN OUT VOID *  StructureBuffer 
)

Worker function to parse CPU BIST information from Guided HOB.

Parameters
[in,out]StructureSizePointer to the variable describing size of the input buffer.
[in,out]StructureBufferPointer to the buffer save CPU BIST information.
Return values
EFI_SUCCESSThe data was successfully returned.
EFI_BUFFER_TOO_SMALLThe buffer was too small.

Definition at line 42 of file SecBist.c.

◆ GetBistInfoFromPpi()

EFI_STATUS GetBistInfoFromPpi ( IN CONST EFI_PEI_SERVICES **  PeiServices,
IN CONST EFI_GUID Guid,
OUT EFI_PEI_PPI_DESCRIPTOR **  PpiDescriptor,
OUT VOID **  BistInformationData,
OUT UINT64 *BistInformationSize  OPTIONAL 
)

Worker function to get CPUs' BIST by calling SecPlatformInformationPpi or SecPlatformInformation2Ppi.

Parameters
[in]PeiServicesPointer to PEI Services Table
[in]GuidPPI Guid
[out]PpiDescriptorReturn a pointer to instance of the EFI_PEI_PPI_DESCRIPTOR
[out]BistInformationDataPointer to BIST information data
[out]BistInformationSizeReturn the size in bytes of BIST information
Return values
EFI_SUCCESSRetrieve of the BIST data successfully
EFI_NOT_FOUNDNo sec platform information(2) ppi export
EFI_DEVICE_ERRORFailed to get CPU Information

Definition at line 135 of file SecBist.c.

◆ RepublishSecPlatformInformationPpi()

VOID RepublishSecPlatformInformationPpi ( VOID  )

Get CPUs' BIST by calling SecPlatformInformationPpi/SecPlatformInformation2Ppi.

Definition at line 203 of file SecBist.c.

◆ SecPlatformInformation2Bist()

EFI_STATUS EFIAPI SecPlatformInformation2Bist ( IN CONST EFI_PEI_SERVICES **  PeiServices,
IN OUT UINT64 *  StructureSize,
OUT EFI_SEC_PLATFORM_INFORMATION_RECORD2 PlatformInformationRecord2 
)

Implementation of the PlatformInformation2 service in EFI_SEC_PLATFORM_INFORMATION2_PPI.

Parameters
[in]PeiServicesThe pointer to the PEI Services Table.
[in,out]StructureSizeThe pointer to the variable describing size of the input buffer.
[out]PlatformInformationRecord2The pointer to the EFI_SEC_PLATFORM_INFORMATION_RECORD2.
Return values
EFI_SUCCESSThe data was successfully returned.
EFI_BUFFER_TOO_SMALLThe buffer was too small. The current buffer size needed to hold the record is returned in StructureSize.

Definition at line 109 of file SecBist.c.

◆ SecPlatformInformationBist()

EFI_STATUS EFIAPI SecPlatformInformationBist ( IN CONST EFI_PEI_SERVICES **  PeiServices,
IN OUT UINT64 *  StructureSize,
OUT EFI_SEC_PLATFORM_INFORMATION_RECORD PlatformInformationRecord 
)

Implementation of the PlatformInformation service in EFI_SEC_PLATFORM_INFORMATION_PPI.

Parameters
[in]PeiServicesPointer to the PEI Services Table.
[in,out]StructureSizePointer to the variable describing size of the input buffer.
[out]PlatformInformationRecordPointer to the EFI_SEC_PLATFORM_INFORMATION_RECORD.
Return values
EFI_SUCCESSThe data was successfully returned.
EFI_BUFFER_TOO_SMALLThe buffer was too small.

Definition at line 86 of file SecBist.c.

Variable Documentation

◆ mPeiSecPlatformInformation

EFI_PEI_PPI_DESCRIPTOR mPeiSecPlatformInformation
Initial value:
= {
(EFI_PEI_PPI_DESCRIPTOR_PPI | EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST),
&gEfiSecPlatformInformationPpiGuid,
&mSecPlatformInformation
}

Definition at line 15 of file SecBist.c.

◆ mPeiSecPlatformInformation2

EFI_PEI_PPI_DESCRIPTOR mPeiSecPlatformInformation2
Initial value:
= {
(EFI_PEI_PPI_DESCRIPTOR_PPI | EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST),
&gEfiSecPlatformInformation2PpiGuid,
&mSecPlatformInformation2
}

Definition at line 25 of file SecBist.c.

◆ mSecPlatformInformation

EFI_SEC_PLATFORM_INFORMATION_PPI mSecPlatformInformation
Initial value:
= {
}
EFI_STATUS EFIAPI SecPlatformInformationBist(IN CONST EFI_PEI_SERVICES **PeiServices, IN OUT UINT64 *StructureSize, OUT EFI_SEC_PLATFORM_INFORMATION_RECORD *PlatformInformationRecord)
Definition: SecBist.c:86

Definition at line 11 of file SecBist.c.

◆ mSecPlatformInformation2

EFI_SEC_PLATFORM_INFORMATION2_PPI mSecPlatformInformation2
Initial value:
= {
}
EFI_STATUS EFIAPI SecPlatformInformation2Bist(IN CONST EFI_PEI_SERVICES **PeiServices, IN OUT UINT64 *StructureSize, OUT EFI_SEC_PLATFORM_INFORMATION_RECORD2 *PlatformInformationRecord2)
Definition: SecBist.c:109

Definition at line 21 of file SecBist.c.