TianoCore EDK2 master
Loading...
Searching...
No Matches
BlParseLib.h File Reference

Go to the source code of this file.

Macros

#define GET_BOOTLOADER_PARAMETER()   PcdGet64 (PcdBootloaderParameter)
 

Typedefs

typedef RETURN_STATUS(* BL_MEM_INFO_CALLBACK) (MEMORY_MAP_ENTRY *MemoryMapEntry, VOID *Param)
 

Functions

VOID *EFIAPI GetParameterBase (VOID)
 
RETURN_STATUS EFIAPI ParseMemoryInfo (IN BL_MEM_INFO_CALLBACK MemInfoCallback, IN VOID *Params)
 
RETURN_STATUS EFIAPI ParseSmbiosTable (OUT UNIVERSAL_PAYLOAD_SMBIOS_TABLE *SmbiosTable)
 
RETURN_STATUS EFIAPI ParseAcpiTableInfo (OUT UNIVERSAL_PAYLOAD_ACPI_TABLE *AcpiTableHob)
 
RETURN_STATUS EFIAPI ParseSerialInfo (OUT SERIAL_PORT_INFO *SerialPortInfo)
 
RETURN_STATUS EFIAPI ParseGfxInfo (OUT EFI_PEI_GRAPHICS_INFO_HOB *GfxInfo)
 
RETURN_STATUS EFIAPI ParseGfxDeviceInfo (OUT EFI_PEI_GRAPHICS_DEVICE_INFO_HOB *GfxDeviceInfo)
 
RETURN_STATUS EFIAPI ParseMiscInfo (VOID)
 

Detailed Description

This library will parse the coreboot table in memory and extract those required information.

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

Definition in file BlParseLib.h.

Macro Definition Documentation

◆ GET_BOOTLOADER_PARAMETER

#define GET_BOOTLOADER_PARAMETER ( )    PcdGet64 (PcdBootloaderParameter)

Definition at line 21 of file BlParseLib.h.

Typedef Documentation

◆ BL_MEM_INFO_CALLBACK

typedef RETURN_STATUS(* BL_MEM_INFO_CALLBACK) (MEMORY_MAP_ENTRY *MemoryMapEntry, VOID *Param)

Definition at line 23 of file BlParseLib.h.

Function Documentation

◆ GetParameterBase()

VOID *EFIAPI GetParameterBase ( VOID  )

This function retrieves the parameter base address from boot loader.

This function will get bootloader specific parameter address for UEFI payload. e.g. HobList pointer for Slim Bootloader, and coreboot table header for Coreboot.

Return values
NULLFailed to find the GUID HOB.
othersGUIDed HOB data pointer.

Definition at line 130 of file CbParseLib.c.

◆ ParseAcpiTableInfo()

RETURN_STATUS EFIAPI ParseAcpiTableInfo ( OUT UNIVERSAL_PAYLOAD_ACPI_TABLE AcpiTableHob)

Acquire ACPI table from bootloader.

Parameters
AcpiTableHobPointer to the ACPI table info.
Return values
RETURN_SUCCESSSuccessfully find out the tables.
RETURN_NOT_FOUNDFailed to find the tables.

Acquire ACPI table from coreboot.

Parameters
AcpiTableHobPointer to the ACPI table info.
Return values
RETURN_SUCCESSSuccessfully find out the tables.
RETURN_NOT_FOUNDFailed to find the tables.

Acquire ACPI table from slim bootloader.

Parameters
AcpiTableHobPointer to the ACPI table info.
Return values
RETURN_SUCCESSSuccessfully find out the tables.
RETURN_NOT_FOUNDFailed to find the tables.

Definition at line 458 of file CbParseLib.c.

◆ ParseGfxDeviceInfo()

RETURN_STATUS EFIAPI ParseGfxDeviceInfo ( OUT EFI_PEI_GRAPHICS_DEVICE_INFO_HOB GfxDeviceInfo)

Find the video frame buffer device information

Parameters
GfxDeviceInfoPointer to the EFI_PEI_GRAPHICS_DEVICE_INFO_HOB structure
Return values
RETURN_SUCCESSSuccessfully find the video frame buffer information.
RETURN_NOT_FOUNDFailed to find the video frame buffer information .

Find the video frame buffer device information

Parameters
GfxDeviceInfoPointer to the EFI_PEI_GRAPHICS_DEVICE_INFO_HOB structure
Return values
RETURN_SUCCESSSuccessfully find the video frame buffer information.
RETURN_NOT_FOUNDFailed to find the video frame buffer information.

Definition at line 584 of file CbParseLib.c.

◆ ParseGfxInfo()

RETURN_STATUS EFIAPI ParseGfxInfo ( OUT EFI_PEI_GRAPHICS_INFO_HOB GfxInfo)

Find the video frame buffer information

Parameters
GfxInfoPointer to the EFI_PEI_GRAPHICS_INFO_HOB structure
Return values
RETURN_SUCCESSSuccessfully find the video frame buffer information.
RETURN_NOT_FOUNDFailed to find the video frame buffer information .

Definition at line 519 of file CbParseLib.c.

◆ ParseMemoryInfo()

RETURN_STATUS EFIAPI ParseMemoryInfo ( IN BL_MEM_INFO_CALLBACK  MemInfoCallback,
IN VOID *  Params 
)

Acquire the memory map information.

Parameters
MemInfoCallbackThe callback routine
ParamsPointer to the callback routine parameter
Return values
RETURN_SUCCESSSuccessfully find out the memory information.
RETURN_NOT_FOUNDFailed to find the memory information.

Acquire the memory information from the coreboot table in memory.

Parameters
MemInfoCallbackThe callback routine
ParamsPointer to the callback routine parameter
Return values
RETURN_SUCCESSSuccessfully find out the memory information.
RETURN_NOT_FOUNDFailed to find the memory information.

Definition at line 379 of file CbParseLib.c.

◆ ParseMiscInfo()

RETURN_STATUS EFIAPI ParseMiscInfo ( VOID  )

Parse and handle the misc info provided by bootloader

Return values
RETURN_SUCCESSThe misc information was parsed successfully.
RETURN_NOT_FOUNDCould not find required misc info.
RETURN_OUT_OF_RESOURCESInsufficant memory space.

Definition at line 601 of file CbParseLib.c.

◆ ParseSerialInfo()

RETURN_STATUS EFIAPI ParseSerialInfo ( OUT SERIAL_PORT_INFO SerialPortInfo)

Find the serial port information

Parameters
SerialPortInfoPointer to serial port info structure
Return values
RETURN_SUCCESSSuccessfully find the serial port information.
RETURN_NOT_FOUNDFailed to find the serial port information .

Find the serial port information

Parameters
[out]SerialPortInfoPointer to serial port info structure
Return values
RETURN_SUCCESSSuccessfully find the serial port information.
RETURN_NOT_FOUNDFailed to find the serial port information .

Definition at line 487 of file CbParseLib.c.

◆ ParseSmbiosTable()

RETURN_STATUS EFIAPI ParseSmbiosTable ( OUT UNIVERSAL_PAYLOAD_SMBIOS_TABLE SmbiosTable)

Acquire SMBIOS table from bootloader.

Parameters
SmbiosTablePointer to the system table info
Return values
RETURN_SUCCESSSuccessfully find out the tables.
RETURN_NOT_FOUNDFailed to find the tables.

Acquire SMBIOS table from coreboot.

Parameters
SmbiosTablePointer to the SMBIOS table info.
Return values
RETURN_SUCCESSSuccessfully find out the tables.
RETURN_NOT_FOUNDFailed to find the tables.

Acquire SMBIOS table from slim bootloader.

Parameters
SmbiosTablePointer to the SMBIOS table info.
Return values
RETURN_SUCCESSSuccessfully find out the tables.
RETURN_NOT_FOUNDFailed to find the tables.

Definition at line 429 of file CbParseLib.c.